You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2022/03/08 14:32:18 UTC

[camel] branch camel-3.14.x updated: CAMEL-17764 changed types of job detail to Strings (#7156)

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

davsclaus pushed a commit to branch camel-3.14.x
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/camel-3.14.x by this push:
     new 5b89406  CAMEL-17764 changed types of job detail to Strings (#7156)
5b89406 is described below

commit 5b89406c35ecb88f0b0adc76793c07fc8ae2f604
Author: JiriOndrusek <on...@gmail.com>
AuthorDate: Tue Mar 8 15:30:28 2022 +0100

    CAMEL-17764 changed types of job detail to Strings (#7156)
---
 .../main/java/org/apache/camel/component/quartz/QuartzEndpoint.java   | 4 ++--
 .../java/org/apache/camel/component/quartz/QuartzSimpleRouteTest.java | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzEndpoint.java b/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzEndpoint.java
index f7a6415..10cfe80 100644
--- a/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzEndpoint.java
+++ b/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/QuartzEndpoint.java
@@ -499,8 +499,8 @@ public class QuartzEndpoint extends DefaultEndpoint {
 
             // enrich job map with details
             jobDetail.getJobDataMap().put(QuartzConstants.QUARTZ_TRIGGER_TYPE, "simple");
-            jobDetail.getJobDataMap().put(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_COUNTER, repeat);
-            jobDetail.getJobDataMap().put(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_INTERVAL, interval);
+            jobDetail.getJobDataMap().put(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_COUNTER, String.valueOf(repeat));
+            jobDetail.getJobDataMap().put(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_INTERVAL, String.valueOf(interval));
         }
 
         final Trigger result = triggerBuilder.build();
diff --git a/components/camel-quartz/src/test/java/org/apache/camel/component/quartz/QuartzSimpleRouteTest.java b/components/camel-quartz/src/test/java/org/apache/camel/component/quartz/QuartzSimpleRouteTest.java
index 924ec40..aa33aae 100644
--- a/components/camel-quartz/src/test/java/org/apache/camel/component/quartz/QuartzSimpleRouteTest.java
+++ b/components/camel-quartz/src/test/java/org/apache/camel/component/quartz/QuartzSimpleRouteTest.java
@@ -44,9 +44,9 @@ public class QuartzSimpleRouteTest extends BaseQuartzTest {
         assertThat(detail.getJobClass().equals(CamelJob.class), CoreMatchers.is(true));
 
         assertThat(detail.getJobDataMap().get(QuartzConstants.QUARTZ_TRIGGER_TYPE).equals("simple"), CoreMatchers.is(true));
-        assertThat(detail.getJobDataMap().get(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_COUNTER).equals(-1),
+        assertThat(detail.getJobDataMap().get(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_COUNTER).equals("-1"),
                 CoreMatchers.is(true));
-        assertThat(detail.getJobDataMap().get(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_INTERVAL).equals(100L),
+        assertThat(detail.getJobDataMap().get(QuartzConstants.QUARTZ_TRIGGER_SIMPLE_REPEAT_INTERVAL).equals("100"),
                 CoreMatchers.is(true));
     }