You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2020/10/16 06:34:01 UTC

[camel] 01/04: CAMEL-15693 - Camel-File-watch: Event type should be a simple string on the consumer side

This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit c7e92b9d0e211c7c03e0df39168959d4a8a2a88d
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Oct 16 08:25:46 2020 +0200

    CAMEL-15693 - Camel-File-watch: Event type should be a simple string on the consumer side
---
 .../java/org/apache/camel/component/file/watch/FileWatchConsumer.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/components/camel-file-watch/src/main/java/org/apache/camel/component/file/watch/FileWatchConsumer.java b/components/camel-file-watch/src/main/java/org/apache/camel/component/file/watch/FileWatchConsumer.java
index cb9333a..257bc40 100644
--- a/components/camel-file-watch/src/main/java/org/apache/camel/component/file/watch/FileWatchConsumer.java
+++ b/components/camel-file-watch/src/main/java/org/apache/camel/component/file/watch/FileWatchConsumer.java
@@ -143,7 +143,7 @@ public class FileWatchConsumer extends DefaultConsumer {
         File file = event.getEventPath().toFile();
         Message message = exchange.getIn();
         message.setBody(file);
-        message.setHeader(FileWatchComponent.EVENT_TYPE_HEADER, event.getEventType());
+        message.setHeader(FileWatchComponent.EVENT_TYPE_HEADER, event.getEventType().name());
         message.setHeader(Exchange.FILE_NAME_ONLY, event.getEventPath().getFileName().toString());
         message.setHeader("CamelFileAbsolute", true);