Search code examples
alfrescoecm

Does Alfresco support monitoring entire folder tree for changes?


I am interested in triggering code to run when any changes are made to any documents or folders under a specific folder in alfresco. I am sure alfresco has to support this some how but I am not entirely sure what the feature/api/service is called or what to google for. What has this ability in alfresco and what is it called?

I am aware that its possible to create custom content rules in javascript and then add them to a folder to be triggered by some action. I did that a couple years back for auto filing documents that were dropped into a specific folder. Problem is that requires adding that action to each folder you want to monitor. I want to monitory an entire directory tree basically.

EDIT: Correct me if I am wrong, but it appears that Events API may do what I need to do. I found this right after posting my question.


Solution

  • @Gragravarr answer is the best for handling events over a subtree of the repository.

    In case what you need to monitor is only a subset of all the content of the subree (e.g. watch all the incoming documents, but only if they are PDF) and possibly scattered across the whole repository, then creating a specific content type and handle events using Policies is probably a better option.