This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. Check limitations for your target platform. If you disable this, you can get some events multiple times on some platforms and JDKs. Unbounded by default.Įnables or disables file hashing to detect duplicate events. ![]() Maximum size of queue between WatchService and consumer. Increase this value, if you see OVERFLOW messages in log. The number of threads polling WatchService. You can also provide custom implementation in registry. For working with large files and if you dont need detect multiple modifications per second per file, use #lastModifiedTimeFileHasher. This prevents emitting duplicate events on some platforms. Increase this value, if your route is slow to prevent buffering in queue. By default the consumer will use the .ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. NameĪllows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. Retrieve each pending event for the key (there might be multiple events) and process as needed.Reset the key, and resume waiting for events.The File Watch component supports 7 options, which are listed below. ![]() You can obtain the file name from the key. Retrieve the key from the watcher's queue. When an event occurs, the key is signaled and placed into the watcher's queue. Implement an infinite loop to wait for incoming events. You receive a WatchKey instance for each directory that you register. You do not have to register for the OVERFLOW event to receive it.
0 Comments
Leave a Reply. |