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

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

commit e71c0c3eb2a24688d66b8099d37a8a11ec6a7802
Author: Otavio R. Piske <angusyo...@gmail.com>
AuthorDate: Sat Feb 17 13:35:23 2024 +0100

    CAMEL-20410: documentation fixes for camel-cron
    
    - Fixed samples
    - Converted to use tabs
    - Fixed grammar and typos
    - Fixed punctuation
    - Added and/or fixed links
    
    Signed-off-by: Otavio R. Piske <angusyo...@gmail.com>
---
 .../camel-cron/src/main/docs/cron-component.adoc   | 34 +++++++++++++---------
 1 file changed, 20 insertions(+), 14 deletions(-)

diff --git a/components/camel-cron/src/main/docs/cron-component.adoc 
b/components/camel-cron/src/main/docs/cron-component.adoc
index c5e4e32a8e7..dfef6419c5c 100644
--- a/components/camel-cron/src/main/docs/cron-component.adoc
+++ b/components/camel-cron/src/main/docs/cron-component.adoc
@@ -61,6 +61,11 @@ include::partial$component-endpoint-options.adoc[]
 
 The component can be used to trigger events at specified times, as in the 
following example:
 
+
+[tabs]
+====
+Java::
++
 [source,java]
 ---------------------------------------------------------
 from("cron:tab?schedule=0/1+*+*+*+*+?")
@@ -68,6 +73,21 @@ from("cron:tab?schedule=0/1+*+*+*+*+?")
 .log("${body}");
 ---------------------------------------------------------
 
+XML::
++
+[source,xml]
+-------------
+<route>
+    <from uri="cron:tab?schedule=0/1+*+*+*+*+?"/>
+    <setBody>
+      <constant>event</constant>
+    </setBody>
+    <to uri="log:info"/>
+</route>
+-------------
+
+====
+
 The schedule expression `0/3{plus}10{plus}*{plus}*{plus}*{plus}?` can be also 
written as `0/3 10 * * * ?` and triggers an event every three seconds only in 
the tenth minute of each hour.
 
 Breaking down the parts in the schedule expression(in order):
@@ -87,18 +107,4 @@ Other valid examples of schedule expressions are:
 - `0/2 * * * ?` (Five parts, an event every two minutes)
 - `0 0/2 * * * MON-FRI 2030` (Seven parts, an event every two minutes only in 
the year 2030)
 
-Routes can also be written using the XML DSL.
-
-[source,xml]
--------------
-<route>
-    <from uri="cron:tab?schedule=0/1+*+*+*+*+?"/>
-    <setBody>
-      <constant>event</constant>
-    </setBody>
-    <to uri="log:info"/>
-</route>
--------------
-
-
 include::spring-boot:partial$starter.adoc[]

Reply via email to