-
Task
-
Resolution: Won't Do
-
Major
-
None
ModeShape should support a mode:transient mixin that can be added/removed from nodes. It has a property "timespan" or similiar that sets up the lifetime of the node in milliseconds. If this value is either not set or set to 0, it should mean that the node will never make it into the repository (i.e. it behaves as being added and immediately being removed while still firing events). This would allow to support kind of event systems. If a node goes out of the given timespan, it should be cleaned including all its children as well as all references. The special case of timespan=0 would certainly require special care on optimization to be really usable like an event system. It should, however, be also possible to remove or modify the mixin in one of the events fired. The idea is that we could receive a node with timespan=0 (i.e. immediate removal) though in the removal event we say that we want to keep the node and remove the mixin or reset the timespan. This would, for example, make it very easy to filter for certain events and persist them on a case-by-base base.
Important: For the special case of timespan=0 it should still be possible to be able to filter on nodes with queries. I.e. if in the removal event I'd like to check the node for certain conditions I would still, at that point of time, be able to use a query with filters to see whether it matches the (almost) dead node.