-
1. Re: Use of sequencers in combination with external file system source
rhauch Nov 22, 2013 11:19 AM (in response to lhelander)Yes, connectors can generate events that are then handled as any other events. See MODE-1710 for details. Basically, the connector would need to call "createChangeSet()" and then use the ConnectorChangeSet interface to record the various changes and publish the set.
Our file system connector does not currently do this because we're still support JDK 6, which doesn't have a way to monitor the file system for changes. If you are using JDK 7, you could extend our FileSystemConnector (or LargeFileSystemConnector if you need that behavior) class, register a FS listener that then creates and populates ConnectorChangeSet instances as required.
In 4.0 we will be switching to JDK 7 as the minimum JDK version, so we will be adding built-in support for events into the FileSystemConnector and LargeFileSystemConnector classes.
-
2. Re: Use of sequencers in combination with external file system source
lhelander Nov 22, 2013 12:45 PM (in response to rhauch)Randall, thank you very much for the feedback, this sounds great. I am using jdk 7 so that is not a problem. If I understand this correctly, publishing the change set will result in that any sequencers that are configured to act upon the changed nodes will be triggered and I do not explicitly have to call the sequencers from my code?
-
3. Re: Use of sequencers in combination with external file system source
rhauch Nov 22, 2013 12:53 PM (in response to lhelander)If I understand this correctly, publishing the change set will result in that any sequencers that are configured to act upon the changed nodes will be triggered and I do not explicitly have to call the sequencers from my code?
Yes. And the same events will be visible to JCR Observation listeners.