From: Adam R. <ad...@ex...> - 2011-11-08 23:59:13
|
>> I am trying to change the way 'restore' occurs in the system. We have >> observed that once the /db/system has been restored, the triggering process >> gets initialized. There is a chance the triggers might have dependencies on >> documents that have not been restored yet. This would only be the case if you create triggers that expect documents to be present that are not, surely in your trigger you should check whether a document exists before operating on it? >This is why we would like the >> triggering system to work as follows: >> >> 1. Disable triggering >> 2. Perform restore >> 3. Enable triggering >> >> Now in order to disable the triggers, we are trying to use the >> collection.setTriggersEnabled(false). However in order to do this >> successfully, we need to use the DBBroker which is not immediately available >> in the restore function. >> >> Also, since there are two ways of initiating the restore process (locally >> / remotely) we wanted to declare a method in the interface >> CollectionManagementServiceImpl to disableCollectionTriggers. We would >> implement the method in localCollectionManagementService and >> remoteCollectionManagementService. >> >> Thus in the restore method we would get the collection management service >> object and call the disableTriggers method. >> >> Can someone review the above steps? >> >> Thanks, >> Kaustubh > > > ------------------------------------------------------------------------------ > RSA(R) Conference 2012 > Save $700 by Nov 18 > Register now > http://p.sf.net/sfu/rsa-sfdev2dev1 > _______________________________________________ > Exist-development mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-development > > -- Adam Retter eXist Developer { United Kingdom } ad...@ex... irc://irc.freenode.net/existdb |