Task #6315 (new)
Opened 13 years ago
Indexer could skip duplicate UPDATES after INSERT
Reported by: | jamoore | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | Unscheduled |
Component: | General | Version: | n.a. |
Keywords: | n.a. | Cc: | bhcho@… |
Resources: | n.a. | Referenced By: | n.a. |
References: | n.a. | Remaining Time: | n.a. |
Sprint: | n.a. |
Description
For some types of event log consumers, it may make sense to filter UPDATES which are part of an event in which there was also an INSERT. This could be done by loading per event and handling the duplicate event logs in memory. It's unclear if all event log consumers would want the UPDATES filtered.
See: http://openmicroscopy.org/community/viewtopic.php?f=6&t=757&p=2811#p2811
Investigatory SQL:
select id from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select id, entitytype, entityid, action from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select id, entitytype, entityid from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select entitytype, entityid from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select count(entitytype, entityid) from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select count(entitytype || entityid) from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select count(distinct entitytype || entityid) from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select distinct entitytype, entityid from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1); select distinct entitytype, entityid from eventlog where id > 4002 and event = (select event from eventlog where id > 4002 and entitytype = 'ome.model.containers.Dataset' and entityid = 125 order by id limit 1);