This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git
The following commit(s) were added to refs/heads/main by this push:
new 2457d02e4 chore: describe the core Kamelets for people and AI
assistants (#3141)
2457d02e4 is described below
commit 2457d02e4cf9fa7ff92a1c7a203dc93bc78725fa
Author: Claus Ibsen <[email protected]>
AuthorDate: Tue Nov 17 11:19:36 2026 +0100
chore: describe the core Kamelets for people and AI assistants (#3141)
* chore: describe the core Kamelets for people and AI assistants
Rewrites the descriptions and options of 21 Kamelets that run without any
outside system, to the standard of docs/modules/ROOT/pages/documenting.adoc
(#3140): a one-sentence summary as the first paragraph, then Use it to,
Input:, Output: and Good to know:, and option descriptions that give the
format, the unit and an example. Every Kamelet was run to check what it
says.
delay-action, drop-header-action, drop-headers-action,
has-header-filter-action, header-matches-filter-action,
insert-header-action, simple-filter-action, throttle-action,
counter-source, cron-source, dns-dig-action, dns-ip-action, log-action,
log-sink, chuck-norris-source, earthquake-source, wttrin-source,
json-deserialize-action, json-serialize-action,
json-schema-validator-action, jsonata-action.
Corrects the partial pages of counter-source, cron-source,
earthquake-source and wttrin-source where they said something the
Kamelet does not do.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* chore: escape a brace before a name in Kamelet descriptions
The documentation page renders descriptions and partial pages as
AsciiDoc, where {body} is an attribute reference that fails the
documentation check: write $\{body}, as the Camel documentation does.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
---------
Co-authored-by: Claude Opus 5.5 <[email protected]>
---
.../ROOT/partials/counter-source-description.adoc | 2 +-
.../ROOT/partials/cron-source-description.adoc | 4 +-
.../partials/earthquake-source-description.adoc | 2 +-
.../ROOT/partials/wttrin-source-description.adoc | 21 +++---
kamelets/chuck-norris-source.kamelet.yaml | 12 +++-
kamelets/counter-source.kamelet.yaml | 29 ++++++--
kamelets/cron-source.kamelet.yaml | 17 +++--
kamelets/delay-action.kamelet.yaml | 13 +++-
kamelets/dns-dig-action.kamelet.yaml | 30 +++++++-
kamelets/dns-ip-action.kamelet.yaml | 22 +++++-
kamelets/drop-header-action.kamelet.yaml | 19 +++--
kamelets/drop-headers-action.kamelet.yaml | 23 ++++--
kamelets/earthquake-source.kamelet.yaml | 19 +++--
kamelets/has-header-filter-action.kamelet.yaml | 21 ++++--
kamelets/header-matches-filter-action.kamelet.yaml | 24 +++++--
kamelets/insert-header-action.kamelet.yaml | 24 +++++--
kamelets/json-deserialize-action.kamelet.yaml | 11 ++-
kamelets/json-schema-validator-action.kamelet.yaml | 15 +++-
kamelets/json-serialize-action.kamelet.yaml | 18 ++++-
kamelets/jsonata-action.kamelet.yaml | 15 +++-
kamelets/log-action.kamelet.yaml | 59 ++++++++-------
kamelets/log-sink.kamelet.yaml | 59 ++++++++-------
kamelets/simple-filter-action.kamelet.yaml | 18 +++--
kamelets/throttle-action.kamelet.yaml | 18 +++--
kamelets/wttrin-source.kamelet.yaml | 26 ++++---
.../main/resources/META-INF/kamelets-index.json | 84 +++++++++++-----------
.../kamelets/chuck-norris-source.kamelet.yaml | 12 +++-
.../resources/kamelets/counter-source.kamelet.yaml | 29 ++++++--
.../resources/kamelets/cron-source.kamelet.yaml | 17 +++--
.../resources/kamelets/delay-action.kamelet.yaml | 13 +++-
.../resources/kamelets/dns-dig-action.kamelet.yaml | 30 +++++++-
.../resources/kamelets/dns-ip-action.kamelet.yaml | 22 +++++-
.../kamelets/drop-header-action.kamelet.yaml | 19 +++--
.../kamelets/drop-headers-action.kamelet.yaml | 23 ++++--
.../kamelets/earthquake-source.kamelet.yaml | 19 +++--
.../kamelets/has-header-filter-action.kamelet.yaml | 21 ++++--
.../header-matches-filter-action.kamelet.yaml | 24 +++++--
.../kamelets/insert-header-action.kamelet.yaml | 24 +++++--
.../kamelets/json-deserialize-action.kamelet.yaml | 11 ++-
.../json-schema-validator-action.kamelet.yaml | 15 +++-
.../kamelets/json-serialize-action.kamelet.yaml | 18 ++++-
.../resources/kamelets/jsonata-action.kamelet.yaml | 15 +++-
.../resources/kamelets/log-action.kamelet.yaml | 59 ++++++++-------
.../main/resources/kamelets/log-sink.kamelet.yaml | 59 ++++++++-------
.../kamelets/simple-filter-action.kamelet.yaml | 18 +++--
.../kamelets/throttle-action.kamelet.yaml | 18 +++--
.../resources/kamelets/wttrin-source.kamelet.yaml | 26 ++++---
47 files changed, 781 insertions(+), 316 deletions(-)
diff --git a/docs/modules/ROOT/partials/counter-source-description.adoc
b/docs/modules/ROOT/partials/counter-source-description.adoc
index 0c6fe53b0..397931c4a 100644
--- a/docs/modules/ROOT/partials/counter-source-description.adoc
+++ b/docs/modules/ROOT/partials/counter-source-description.adoc
@@ -4,7 +4,7 @@ This Kamelet provides a simple counting source that generates
sequential numbers
=== Output format
-The Kamelet outputs each number as a plain text integer. Each message contains
a single number that increments from the starting value.
+The Kamelet outputs each number as an `Integer` body (a whole number, not
text), even though the `Content-Type` header is `text/plain`. Each message
contains a single number that increments by one from the starting value.
=== Special headers
diff --git a/docs/modules/ROOT/partials/cron-source-description.adoc
b/docs/modules/ROOT/partials/cron-source-description.adoc
index 827832262..09251bc3a 100644
--- a/docs/modules/ROOT/partials/cron-source-description.adoc
+++ b/docs/modules/ROOT/partials/cron-source-description.adoc
@@ -15,14 +15,14 @@ This Kamelet requires the following mandatory properties:
=== Cron expression format
-The cron expression follows the standard format:
+The cron expression follows the Quartz format, with the seconds first (a Unix
cron expression of five fields, without the seconds, works too):
```
<seconds> <minutes> <hours> <day-of-month> <month> <day-of-week> [year]
```
=== Usage examples
-Send a message every 3 seconds during the 10th hour:
+Send a message every 3 seconds during minute 10 of every hour:
[source,yaml,subs='+attributes,macros']
----
diff --git a/docs/modules/ROOT/partials/earthquake-source-description.adoc
b/docs/modules/ROOT/partials/earthquake-source-description.adoc
index e35bd6352..2fe37928c 100644
--- a/docs/modules/ROOT/partials/earthquake-source-description.adoc
+++ b/docs/modules/ROOT/partials/earthquake-source-description.adoc
@@ -26,7 +26,7 @@ The Kamelet uses the official USGS Earthquake API at
`https://earthquake.usgs.go
The Kamelet maintains state to avoid duplicate earthquake reports by:
1. Caching the timestamp of the last update
-2. Only fetching earthquakes that occurred after the last known update
+2. Only fetching earthquakes whose report was updated after the last known
update, so an earthquake is sent again when USGS updates its report
3. Using the USGS API's `updatedafter` parameter for efficient filtering
=== Usage examples
diff --git a/docs/modules/ROOT/partials/wttrin-source-description.adoc
b/docs/modules/ROOT/partials/wttrin-source-description.adoc
index 0255eea36..38dbc5f48 100644
--- a/docs/modules/ROOT/partials/wttrin-source-description.adoc
+++ b/docs/modules/ROOT/partials/wttrin-source-description.adoc
@@ -1,24 +1,21 @@
== Wttrin Source Kamelet Description
-=== Authentication methods
+=== Authentication
-This Kamelet connects to Wttrin using appropriate authentication mechanisms:
-
-- Service-specific authentication methods
-- API keys, tokens, or credential-based authentication
-- Connection configuration
+The Kamelet calls the public `https://wttr.in` service, which needs no
account, API key or credentials.
=== Output format
-The Kamelet consumes data from Wttrin and produces the data in JSON format.
+The Kamelet fetches data from wttr.in and produces the data in JSON format.
=== Configuration
-The Kamelet requires connection parameters specific to Wttrin:
+No option is required:
-- Service connection details
-- Authentication credentials
-- Query or consumption parameters
+- `wttrLocation`: the place to get the weather for; when it is not set,
wttr.in guesses the place from the IP address of the machine
+- `wttrLanguage`: the language of the weather descriptions
+- `output`: `current`, `weather` or `full`
+- `period`: how long to wait between two fetches, in milliseconds
=== Usage example
@@ -34,7 +31,7 @@ spec:
apiVersion: camel.apache.org/v1alpha1
name: wttrin-source
properties:
- # Add service-specific properties here
+ wttrLocation: Paris
sink:
ref:
kind: Service
diff --git a/kamelets/chuck-norris-source.kamelet.yaml
b/kamelets/chuck-norris-source.kamelet.yaml
index 82507b261..8bcd63426 100644
--- a/kamelets/chuck-norris-source.kamelet.yaml
+++ b/kamelets/chuck-norris-source.kamelet.yaml
@@ -30,14 +30,22 @@ metadata:
spec:
definition:
title: "Chuck Norris Source"
- description: Gets periodically Chuck Norris jokes
+ description: |-
+ Fetches a random Chuck Norris joke from the public api.chucknorris.io
service at a regular interval, and sends it as a message.
+
+ Use it to get short, changing text messages to try out a sink, an action
or a demo, with no account and no setup. For the same fixed message every time,
use `timer-source`.
+
+ Output: the body is the text of one joke. The message has no headers.
+
+ Good to know: it calls `https://api.chucknorris.io` over the internet
for every message, so it needs internet access.
type: object
properties:
period:
title: Period
- description: The interval (msec) to wait before getting the next joke
+ description: "How long to wait between two jokes, in milliseconds. For
example, 60000 is one minute."
type: integer
default: 10000
+ example: 60000
types:
out:
mediaType: text/plain
diff --git a/kamelets/counter-source.kamelet.yaml
b/kamelets/counter-source.kamelet.yaml
index 067fa36b6..58ee2daf2 100644
--- a/kamelets/counter-source.kamelet.yaml
+++ b/kamelets/counter-source.kamelet.yaml
@@ -32,23 +32,40 @@ metadata:
spec:
definition:
title: "Counter Source"
- description: Generates sequential number events starting from a
configurable value, incrementing by a specified step. Useful for testing,
scheduled tasks, or creating ordered event sequences.
+ description: |-
+ Sends a message with a number that counts up by one, such as 1, 2, 3, at
a regular interval.
+
+ Use it to try out a sink or an action with messages that are each
different and easy to follow, or to make ordered test data. For the same fixed
message every time use `timer-source`, and for a calendar schedule such as
"every weekday at 9:00" use `cron-source`.
+
+ Output: the body is the number, as an Integer (a whole number, not
text). The `Content-Type` header is `text/plain`.
+
+ Good to know: it keeps sending until the integration is stopped, unless
`numbers` is set. The count starts again from `start` when the integration
restarts.
type: object
properties:
period:
title: Period
- description: The time interval between two numbers
+ description: "How long to wait between two messages, in milliseconds.
For example, 60000 is one minute."
type: integer
default: 1000
+ example: 60000
start:
- title: Starting Number
- description: The starting number
+ title: Start
+ description: "The number in the first message. Each next message has a
number one higher."
type: integer
default: 1
+ example: 100
numbers:
- title: Numbers
- description: How many numbers to generate
+ title: Number of Messages
+ description: "How many messages to send in total. When it is not set,
a message is sent every `period` until the integration is stopped."
type: integer
+ example: 10
+ dataTypes:
+ out:
+ headers:
+ Content-Type:
+ title: Content Type
+ description: "Always `text/plain`."
+ type: string
dependencies:
- "camel:timer"
- "camel:kamelet"
diff --git a/kamelets/cron-source.kamelet.yaml
b/kamelets/cron-source.kamelet.yaml
index fea1afd9e..9c4cf8c8e 100644
--- a/kamelets/cron-source.kamelet.yaml
+++ b/kamelets/cron-source.kamelet.yaml
@@ -31,7 +31,14 @@ metadata:
spec:
definition:
title: "Cron Source"
- description: Send events at specific time.
+ description: |-
+ Sends the same fixed message on a calendar schedule, written as a cron
expression, such as every weekday at 9:00.
+
+ Use it to start a flow at set times, such as a report every morning or a
clean-up every night. For a message every few seconds or minutes,
`timer-source` is simpler, and for a message that counts up use
`counter-source`.
+
+ Output: the body is the `message` option as text, the same on every
message. Headers about the schedule are set too, such as `fireTime` (the time
of this message) and `nextFireTime`.
+
+ Good to know: the times are in the time zone of the machine it runs on.
It keeps sending until the integration is stopped.
required:
- schedule
- message
@@ -39,14 +46,14 @@ spec:
properties:
schedule:
title: Cron Schedule
- description: A cron expression that is used to trigger events
generation.
+ description: "When to send a message, as a Quartz cron expression of
six or seven fields: seconds, minutes, hours, day of month, month, day of week,
and an optional year. For example, `0 0 9 ? * MON-FRI` is 9:00 every weekday,
and `0 */5 * * * ?` is every five minutes. A Unix cron expression of five
fields, without the seconds, works too."
type: string
- example: "0/3 10 * * * ?"
+ example: "0 0 9 ? * MON-FRI"
message:
title: Message
- description: The message to generate
+ description: "The body of every message, sent as text exactly as
written."
type: string
- example: hello world
+ example: "hello world"
types:
out:
mediaType: text/plain
diff --git a/kamelets/delay-action.kamelet.yaml
b/kamelets/delay-action.kamelet.yaml
index 894d92611..655997955 100644
--- a/kamelets/delay-action.kamelet.yaml
+++ b/kamelets/delay-action.kamelet.yaml
@@ -31,14 +31,21 @@ metadata:
spec:
definition:
title: "Delay Action"
- description: Delay the processing using a specific amount of time
+ description: |-
+ Holds each message for a fixed time, such as one second, before passing
it on.
+
+ Use it to slow down a flow, for example to give another system time to
finish its work before the next step, or to space out the calls of a test. To
limit how many messages pass per second or per minute, rather than holding each
one, use `throttle-action`.
+
+ Input: any message.
+
+ Output: the same message, unchanged, after the wait.
required:
- milliseconds
type: object
properties:
milliseconds:
- title: Milliseconds
- description: The number of milliseconds of delay
+ title: Delay in Milliseconds
+ description: "How long to hold each message, in milliseconds. For
example, 1000 is one second."
type: integer
example: 1000
dependencies:
diff --git a/kamelets/dns-dig-action.kamelet.yaml
b/kamelets/dns-dig-action.kamelet.yaml
index 31314894c..76c97ae62 100644
--- a/kamelets/dns-dig-action.kamelet.yaml
+++ b/kamelets/dns-dig-action.kamelet.yaml
@@ -30,8 +30,36 @@ metadata:
spec:
definition:
title: "DNS DIG Action"
- description: Query a DNS through Dig.
+ description: |-
+ Asks the DNS for the records of one kind, such as A or MX, of a name,
and gives the answer as text, in the format of the `dig` tool.
+
+ Use it to see the records of a domain, such as its mail (MX) records,
for example to check a DNS change. To get only the IP address of a name, use
`dns-ip-action`, and to get its address records as JSON, use
`dns-lookup-action`.
+
+ Input: the name to look up, taken from the `domain-name` header, else
from the `ce-domainname` header, else from the body as text. The kind of record
comes from the `dns-type` header, else from the `ce-dnstype` header, else it is
`A` (the IPv4 addresses).
+
+ Output: the body is the whole answer as text, as the `dig` command shows
it: the question, the records found, and the status, such as `NOERROR`.
+
+ Good to know: a name the DNS does not know does not fail the message:
the answer has the status `NXDOMAIN` and no records. The Kamelet has no
options; it asks the DNS servers of the machine it runs on.
type: object
+ dataTypes:
+ in:
+ headers:
+ domain-name:
+ title: Domain Name
+ description: "The name to look up, such as `apache.org`. When it is
not set, `ce-domainname` is used, and then the body."
+ type: string
+ ce-domainname:
+ title: Domain Name (CloudEvents)
+ description: "The name to look up, when the message is a CloudEvent.
Used only when `domain-name` is not set."
+ type: string
+ dns-type:
+ title: Record Type
+ description: "The kind of record to ask for, such as `A`, `AAAA` or
`MX`. When it is not set, `ce-dnstype` is used, and then `A`."
+ type: string
+ ce-dnstype:
+ title: Record Type (CloudEvents)
+ description: "The kind of record to ask for, when the message is a
CloudEvent. Used only when `dns-type` is not set."
+ type: string
dependencies:
- "camel:dns"
- "camel:kamelet"
diff --git a/kamelets/dns-ip-action.kamelet.yaml
b/kamelets/dns-ip-action.kamelet.yaml
index 3d9b91735..b1bff351e 100644
--- a/kamelets/dns-ip-action.kamelet.yaml
+++ b/kamelets/dns-ip-action.kamelet.yaml
@@ -31,8 +31,28 @@ metadata:
spec:
definition:
title: "DNS IP Action"
- description: Get an IP from a DNS
+ description: |-
+ Finds the IP address of a host name, such as `apache.org`, and gives it
as text.
+
+ Use it to turn a host name into an address for a later step, or to check
that a name can be resolved. To see all the address records of a name with how
long they may be cached, use `dns-lookup-action`, and to ask for other kinds of
record, such as mail (MX) records, use `dns-dig-action`.
+
+ Input: the name to look up, taken from the `domain` header, else from
the `ce-domain` header, else from the body as text.
+
+ Output: the body is one IP address, as text, such as `151.101.2.132`.
+
+ Good to know: when a name has several addresses, only one of them is
given. A name the DNS does not know fails the message with an unknown host
error. The headers are `domain` and `ce-domain`, not `domain-name` as for
`dns-lookup-action` and `dns-dig-action`. The Kamelet has no options; it uses
the name resolution of the machine it runs on.
type: object
+ dataTypes:
+ in:
+ headers:
+ domain:
+ title: Domain
+ description: "The host name to look up, such as `apache.org`. When
it is not set, `ce-domain` is used, and then the body."
+ type: string
+ ce-domain:
+ title: Domain (CloudEvents)
+ description: "The host name to look up, when the message is a
CloudEvent. Used only when `domain` is not set."
+ type: string
dependencies:
- "camel:dns"
- "camel:kamelet"
diff --git a/kamelets/drop-header-action.kamelet.yaml
b/kamelets/drop-header-action.kamelet.yaml
index 03e62617d..7ecdac0b1 100644
--- a/kamelets/drop-header-action.kamelet.yaml
+++ b/kamelets/drop-header-action.kamelet.yaml
@@ -30,16 +30,25 @@ metadata:
spec:
definition:
title: "Drop Header Action"
- description: "Remove an header from the message in transit."
+ description: |-
+ Removes one header, given by its name, from each message.
+
+ Use it to remove a header that the next step must not see, for example
an `Authorization` header with a secret, or a header that would change what a
sink does. To remove several headers at once by a pattern, such as all the
headers whose names start with `Camel`, use `drop-headers-action`.
+
+ Input: any message.
+
+ Output: the same body, and the same headers without the one named by
`name`. A message without that header passes on unchanged.
+
+ Good to know: the name is not case-sensitive: `FOO` also removes the
header `foo`.
required:
- name
+ type: object
properties:
name:
- title: Name
- description: The name of the header to be removed.
+ title: Header Name
+ description: "The name of the header to remove, such as
`Authorization`. Upper and lower case do not matter."
type: string
- example: headername
- type: object
+ example: "Authorization"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/drop-headers-action.kamelet.yaml
b/kamelets/drop-headers-action.kamelet.yaml
index 05330707e..5317a9499 100644
--- a/kamelets/drop-headers-action.kamelet.yaml
+++ b/kamelets/drop-headers-action.kamelet.yaml
@@ -30,21 +30,30 @@ metadata:
spec:
definition:
title: "Drop Headers Action"
- description: "Remove headers from the message in transit based on a
pattern."
+ description: |-
+ Removes from each message all the headers whose names match a pattern,
such as `Camel*`.
+
+ Use it to remove the internal `Camel*` headers that came with a message
from outside before it reaches a sink, or to clear many headers at once before
a message goes to another system. To remove a single header by its name,
`drop-header-action` is enough.
+
+ Input: any message.
+
+ Output: the same body, without the headers that match `pattern`. The
headers that match `excludePattern` are kept.
+
+ Good to know: a pattern is compared with each header name first as an
exact name, then as a wildcard when it ends with `*` (`x-*` matches every name
that starts with `x-`), and then as a Java regular expression, such as
`x-(one|two)`. None of these comparisons is case-sensitive.
required:
- pattern
+ type: object
properties:
pattern:
- title: Pattern
- description: Name or pattern of headers to remove. The pattern is
matched in the following order, 1 = exact match 2 = wildcard (pattern ends with
a and the name starts with the pattern) 3 = regular expression (all of above is
case in-sensitive).
+ title: Header Pattern
+ description: "The headers to remove: an exact header name, a text that
ends with `*` to match every name that starts with the text before it, or a
regular expression. Upper and lower case do not matter."
type: string
- example: Camel*
+ example: "Camel*"
excludePattern:
title: Exclusion Pattern
- description: Name or pattern of headers to not remove. The pattern is
matched in the following order, 1 = exact match 2 = wildcard (pattern ends with
a and the name starts with the pattern) 3 = regular expression (all of above is
case in-sensitive).
+ description: "The headers to keep even when they match `pattern`,
written in the same way. When it is not set, every header that matches
`pattern` is removed."
type: string
- example: Camel*
- type: object
+ example: "CamelKafkaKey"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/earthquake-source.kamelet.yaml
b/kamelets/earthquake-source.kamelet.yaml
index c705b3aac..4b2bb1f7c 100644
--- a/kamelets/earthquake-source.kamelet.yaml
+++ b/kamelets/earthquake-source.kamelet.yaml
@@ -31,19 +31,28 @@ metadata:
spec:
definition:
title: "Earthquake Source"
- description: Get data about current earthquake events happening in the
world using the USGS API
+ description: |-
+ Sends a message for each earthquake reported by the USGS (United States
Geological Survey), checking for new reports at a regular interval.
+
+ Use it to follow the earthquakes around the world, for example to alert
on the strong ones, or as a stream of real, changing JSON data for a demo. No
account is needed.
+
+ Output: one message per earthquake. The body is a GeoJSON feature, as
JSON text: `properties` has the magnitude (`mag`), the place, the time and a
link to the USGS page, and `geometry` has the longitude, the latitude and the
depth. The `Content-Type` header is `application/json`.
+
+ Good to know: the first check sends the earthquakes whose report was
updated in the last `lookAhead` minutes, and each later check those updated
since the check before. An earthquake is sent again when USGS updates its
report. The time of the last check is kept in memory only, so a restart begins
again with the last `lookAhead` minutes. It calls `https://earthquake.usgs.gov`
over the internet.
type: object
properties:
period:
- title: Period between Polls
- description: The interval between fetches to the earthquake API in
milliseconds.
+ title: Period
+ description: "How long to wait between two checks for new reports, in
milliseconds. For example, 300000 is five minutes."
type: integer
default: 60000
+ example: 300000
lookAhead:
- title: Look-ahead Minutes
- description: The amount of minutes to look ahead when starting the
integration afresh.
+ title: Minutes to Look Back
+ description: "When the integration starts, how many minutes back to
look for earthquake reports. For example, 1440 first sends the reports of the
last day."
type: integer
default: 120
+ example: 1440
types:
out:
mediaType: application/json
diff --git a/kamelets/has-header-filter-action.kamelet.yaml
b/kamelets/has-header-filter-action.kamelet.yaml
index 97f2c00ad..87094259f 100644
--- a/kamelets/has-header-filter-action.kamelet.yaml
+++ b/kamelets/has-header-filter-action.kamelet.yaml
@@ -30,21 +30,30 @@ metadata:
spec:
definition:
title: "Has Header Filter Action"
- description: "Filter message based on the presence of one header."
+ description: |-
+ Keeps only the messages that have a given header, optionally with a
given value, and drops all others.
+
+ Use it to pass on only the messages that carry a marker, such as a
`priority` header, or only those of one kind, such as the events whose `type`
header is `order`. To match the value of a header against a pattern, use
`header-matches-filter-action`, and to keep or drop messages by the content of
a JSON body, use `predicate-filter-action`.
+
+ Input: any message. The header named by `name` is read.
+
+ Output: the same message, unchanged, when it has the header and, when
`value` is set, when the header has exactly that value. Otherwise the message
is dropped and nothing is sent on.
+
+ Good to know: the comparison with `value` is case-sensitive: `order`
does not match `Order`. A header with an empty value counts as present when
`value` is not set.
required:
- name
+ type: object
properties:
name:
title: Header Name
- description: The header name to evaluate. The header name must be
passed by the source Kamelet. For Knative only, the name of the header requires
a CloudEvent (ce-) prefix.
+ description: "The name of the header the message must have to be kept,
such as `priority`. The header must already be on the message, for example set
by the source. With Knative, the name of a CloudEvent attribute starts with
`ce-`, such as `ce-type`."
type: string
- example: headerName
+ example: "priority"
value:
title: Header Value
- description: An optional header value to compare the header to
+ description: "The value the header must have, exactly, for the message
to be kept, such as `high`. When it is not set, any value is enough, as long as
the header is there."
type: string
- example: headerValue
- type: object
+ example: "high"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/header-matches-filter-action.kamelet.yaml
b/kamelets/header-matches-filter-action.kamelet.yaml
index 10050d0f8..9f5021d80 100644
--- a/kamelets/header-matches-filter-action.kamelet.yaml
+++ b/kamelets/header-matches-filter-action.kamelet.yaml
@@ -30,21 +30,31 @@ metadata:
spec:
definition:
title: "Header Matches Filter Action"
- description: "Filter based on header value compared to regex."
+ description: |-
+ Keeps only the messages whose value of a given header matches a regular
expression, and drops all others.
+
+ Use it to pass on only some messages, for example only the events whose
`type` header has the form `order-` followed by a number, or only the messages
of some customers by a `customerId` header. To check only that a header is
there, or has one exact value, `has-header-filter-action` is simpler, and to
filter Kafka records by their topic, use `topic-name-matches-filter-action`.
+
+ Input: any message. The header named by `headerName` is read.
+
+ Output: the same message, unchanged, when the value of the header
matches `regex`. Otherwise, and when the message does not have the header, the
message is dropped and nothing is sent on.
+
+ Good to know: the expression must match the whole value, not only a part
of it: `order-[0-9]+` matches `order-1` but not `x-order-1`, and it is
case-sensitive. `headerName` must be set: the Kamelet does not start without it.
required:
- regex
- headerName
+ type: object
properties:
regex:
- title: Regex
- description: The Regex to Evaluate against the Kafka topic name
+ title: Regular Expression
+ description: "A Java regular expression that the whole value of the
header must match for the message to be kept. For example, `order-[0-9]+` keeps
the values `order-1` and `order-55`."
type: string
+ example: "order-[0-9]+"
headerName:
- title: Header Name
- description: The header name to get the value to compare
+ title: Header Name
+ description: "The name of the header whose value is matched, such as
`type`. It must be set: the Kamelet does not start without it."
type: string
- example: headerName
- type: object
+ example: "type"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/insert-header-action.kamelet.yaml
b/kamelets/insert-header-action.kamelet.yaml
index 454b22d9c..5a61f5de2 100644
--- a/kamelets/insert-header-action.kamelet.yaml
+++ b/kamelets/insert-header-action.kamelet.yaml
@@ -30,21 +30,31 @@ metadata:
spec:
definition:
title: "Insert Header Action"
- description: "Adds an header with a simple language parsed expression to
the message in transit."
+ description: |-
+ Adds a header to each message, or replaces it, with a fixed text or a
value taken from the message.
+
+ Use it to give a sink the headers it reads, such as the `ce-projectKey`
header of `jira-add-issue-sink`, to tag messages with where they come from, or
to copy the body into a header for a later step. To set the key of a Kafka
record, `set-kafka-key-action` is simpler.
+
+ Input: any message.
+
+ Output: the same body. The header named by `name` is set to `value`, and
replaces a header of the same name.
+
+ Good to know: `value` is written in the Camel Simple language: plain
text is used as it is, and the `${...}` parts are filled in from the message,
such as `$\{body}` for the body, or `${header.source}` for the value of the
header `source`.
required:
- name
- value
+ type: object
properties:
name:
- title: Name
- description: The name of the header to be added. For Knative only, the
name of the header requires a CloudEvent (ce-) prefix.
+ title: Header Name
+ description: "The name of the header to set, such as `source`. With
Knative, the name must start with `ce-`, the prefix of the CloudEvent
attributes."
type: string
- example: headername
+ example: "source"
value:
- title: Value
- description: The value of the header to be added
+ title: Header Value
+ description: "The value of the header: plain text, such as
`orders-app`, or a Simple expression whose `${...}` parts are filled in from
the message, such as `$\\{body}` or `${header.customerId}`."
type: string
- type: object
+ example: "${header.customerId}"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/json-deserialize-action.kamelet.yaml
b/kamelets/json-deserialize-action.kamelet.yaml
index ebb18cb4c..d13cfc27e 100644
--- a/kamelets/json-deserialize-action.kamelet.yaml
+++ b/kamelets/json-deserialize-action.kamelet.yaml
@@ -30,7 +30,16 @@ metadata:
spec:
definition:
title: "Json Deserialize Action"
- description: "Deserialize payload to JSON."
+ description: |-
+ Turns a body of JSON text into parsed JSON, a Jackson `JsonNode`, so
that the next steps can work with its fields.
+
+ Use it to prepare a message for a step that needs parsed JSON rather
than text, such as `jsonata-action`, or to make sure that a body is well-formed
JSON. To turn parsed data back into JSON text, use `json-serialize-action`, and
to check JSON against a schema, use `json-schema-validator-action`.
+
+ Input: JSON text, as text or bytes: a JSON object or a JSON array.
+
+ Output: the body is parsed JSON, a Jackson `JsonNode`: an object node
for a JSON object, an array node for a JSON array. The `Content-Type` header is
removed.
+
+ Good to know: a body that is not valid JSON fails the message.
type: object
dependencies:
- "camel:kamelet"
diff --git a/kamelets/json-schema-validator-action.kamelet.yaml
b/kamelets/json-schema-validator-action.kamelet.yaml
index ee19799f1..7faa82c0f 100644
--- a/kamelets/json-schema-validator-action.kamelet.yaml
+++ b/kamelets/json-schema-validator-action.kamelet.yaml
@@ -30,16 +30,25 @@ metadata:
spec:
definition:
title: "Json Schema Validator Action"
- description: Apply a Json Schema Template to validate the payload against.
+ description: |-
+ Checks that each JSON message matches a JSON Schema, and fails the
messages that do not.
+
+ Use it to stop bad data early, for example to reject the orders that
miss a required field before they reach a database or another system. To keep
or drop messages by a condition instead of failing them, use
`predicate-filter-action`.
+
+ Input: JSON text, as text, bytes or a stream, or parsed JSON from
`json-deserialize-action`. A Map fails.
+
+ Output: the same message, unchanged, when it matches the schema.
+
+ Good to know: a message that does not match the schema, or that is not
JSON, fails with an error that lists what is wrong; it is not dropped silently,
so the error handling of the integration decides what happens to it. The schema
is loaded from the `template` location; it cannot come from the message.
required:
- template
type: object
properties:
template:
- title: Template
+ title: Schema Location
description: "Where to load the JSON Schema from, not the JSON Schema
itself: `file://` followed by the path of a file, `classpath://` followed by a
resource in the application, or an `http://` or `https://` URL."
type: string
- example: "file:////template.json"
+ example: "file:///etc/camel/order-schema.json"
pattern: "^(http|https|file|classpath|ref|bean)://.*"
dependencies:
- "camel:json-validator"
diff --git a/kamelets/json-serialize-action.kamelet.yaml
b/kamelets/json-serialize-action.kamelet.yaml
index 3af39183d..31bb72a8c 100644
--- a/kamelets/json-serialize-action.kamelet.yaml
+++ b/kamelets/json-serialize-action.kamelet.yaml
@@ -30,8 +30,24 @@ metadata:
spec:
definition:
title: "Json Serialize Action"
- description: "Serialize payload to JSON."
+ description: |-
+ Turns a body of parsed data, such as a Map, a List or parsed JSON, into
JSON text.
+
+ Use it to send parsed data to a sink that needs JSON text, for example
after `jsonata-action` or `json-deserialize-action`, whose output is parsed
JSON. To do the opposite, use `json-deserialize-action`.
+
+ Input: parsed data: a Map, a List, or parsed JSON (a Jackson `JsonNode`).
+
+ Output: the body is JSON text, as a stream of bytes. The `Content-Type`
header is set to `application/json`.
+
+ Good to know: a body that is already text becomes one JSON string, in
quotes: `hello` becomes `"hello"`, and JSON text is quoted the same way. Do not
use it on a body that is already JSON text.
type: object
+ dataTypes:
+ out:
+ headers:
+ Content-Type:
+ title: Content Type
+ description: "Always `application/json`."
+ type: string
dependencies:
- "camel:kamelet"
- "camel:jackson"
diff --git a/kamelets/jsonata-action.kamelet.yaml
b/kamelets/jsonata-action.kamelet.yaml
index b656ab4d5..975ae7a03 100644
--- a/kamelets/jsonata-action.kamelet.yaml
+++ b/kamelets/jsonata-action.kamelet.yaml
@@ -30,16 +30,25 @@ metadata:
spec:
definition:
title: "Jsonata Action"
- description: Apply a Jsonata Transformation.
+ description: |-
+ Transforms each JSON message with a JSONata expression, to reshape it,
pick out fields, or compute new values.
+
+ Use it to turn the JSON of one system into the JSON another system
expects, for example to rename fields, join a first and a last name, or add up
the lines of an order. For other ways to reshape JSON, see `jslt-action` and
`jolt-transformation-action`; to build text, such as an email, from a template,
use `mustache-template-action`.
+
+ Input: parsed JSON, such as a Map, a List, or the output of
`json-deserialize-action`.
+
+ Output: the body is the result of the expression, as parsed JSON (a
Jackson `JsonNode`), not as text: add `json-serialize-action` after it to get
JSON text. The headers are kept.
+
+ Good to know: put `json-deserialize-action` before it when the body is
JSON text, as depending on the Camel version the expression sees JSON text as
one string rather than as an object, and bytes or a stream fail. The expression
is loaded from the `template` location; it cannot come from the message.
required:
- template
type: object
properties:
template:
- title: Template
+ title: Expression Location
description: "Where to load the JSONata expression from, not the
JSONata expression itself: `file://` followed by the path of a file,
`classpath://` followed by a resource in the application, or an `http://` or
`https://` URL."
type: string
- example: "file:////template.spec"
+ example: "file:///etc/camel/order.jsonata"
pattern: "^(http|https|file|classpath|ref|bean)://.*"
dependencies:
- "camel:jsonata"
diff --git a/kamelets/log-action.kamelet.yaml b/kamelets/log-action.kamelet.yaml
index 5e23d38b3..c44530937 100644
--- a/kamelets/log-action.kamelet.yaml
+++ b/kamelets/log-action.kamelet.yaml
@@ -30,74 +30,85 @@ metadata:
spec:
definition:
title: "Log Action"
- description: Logs all data that flows between source and sink, useful for
debugging purposes.
+ description: |-
+ Writes each message to the log, with its body and optionally its
headers, and passes it on unchanged.
+
+ Use it to see what flows between two steps while you build or debug an
integration, for example what a source really sends before a sink fails on it.
To log at the end of a flow instead, use `log-sink`.
+
+ Input: any message.
+
+ Output: the message is unchanged.
+
+ Good to know: by default the log line shows the body and its Java type,
but not the headers. The body is logged as it is, secrets included, unless
`logMask` is true.
type: object
properties:
loggerName:
title: Logger Name
- description: Name of the logging category to use.
+ description: "The name of the logger, shown on each log line. Use it
to tell these log lines apart from others, or to set their level in the logging
configuration."
type: string
default: "log-action"
+ example: "orders-debug"
level:
title: Log Level
- description: Logging level to use.
+ description: "The level to log at. Lines at a level below the one the
logging is set to, such as `DEBUG` when the logging shows `INFO`, are not
shown. `OFF` logs nothing."
type: string
default: "INFO"
enum: ["TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF"]
logMask:
title: Log Mask
- description: Mask sensitive information like password or passphrase in
the log.
+ description: "If true, values that look like secrets, such as what
follows `password=` or a header named `token`, are replaced by `xxxxx` in the
log."
type: boolean
- default: false
+ default: false
marker:
title: Marker
- description: An optional Marker name to use.
+ description: "A logging marker to add to each log line, for logging
setups that filter or send log lines by marker. When it is not set, no marker
is added."
type: string
+ example: "AUDIT"
multiline:
title: Multiline
- description: If enabled then each information is outputted on a
newline.
+ description: "If true, each part of the log line, such as the headers,
the body type and the body, is written on a line of its own, which is easier to
read for large messages."
type: boolean
- default: false
+ default: false
showAllProperties:
title: Show All Properties
- description: Show all of the exchange properties (both internal and
custom).
+ description: "If true, also logs all the properties Camel keeps with
the message, including its internal ones. Mostly useful to Camel developers."
type: boolean
- default: false
+ default: false
showBody:
title: Show Body
- description: Show the message body.
+ description: "If true, the body is logged. Set it to false for large
bodies, or bodies that must not appear in the log."
type: boolean
- default: true
+ default: true
showBodyType:
title: Show Body Type
- description: Show the body Java type
+ description: "If true, the Java type of the body is logged, such as
`String`, `byte[]` or `java.util.LinkedHashMap`, which shows what kind of body
the next step receives."
type: boolean
- default: true
+ default: true
showExchangePattern:
title: Show Exchange Pattern
- description: Shows the Message Exchange Pattern (or MEP for short)
+ description: "If true, the message pattern is logged: `InOnly` for a
one-way message, `InOut` when a reply is expected."
type: boolean
- default: true
+ default: true
showHeaders:
title: Show Headers
- description: Show the headers received
+ description: "If true, the headers of the message are logged too."
type: boolean
- default: false
+ default: false
showProperties:
title: Show Properties
- description: Show the exchange properties (only custom). Use
showAllProperties to show both internal and custom properties.
+ description: "If true, also logs the properties that the steps of the
integration set on the message, but not Camel's internal ones. Use
`showAllProperties` to see those too."
type: boolean
- default: false
+ default: false
showStreams:
title: Show Streams
- description: Show the stream bodies (they may not be available in
following steps)
+ description: "If true, a body that is a stream not cached by Camel is
logged too. Logging reads such a stream, so the next step may then get an empty
body."
type: boolean
- default: false
+ default: false
showCachedStreams:
title: Show Cached Streams
- description: Whether Camel should show cached stream bodies or not.
+ description: "If true, a body that is a stream cached by Camel, which
can be read again, is logged. Camel caches stream bodies by default, so this is
the usual case."
type: boolean
- default: true
+ default: true
dependencies:
- "camel:kamelet"
- "camel:log"
diff --git a/kamelets/log-sink.kamelet.yaml b/kamelets/log-sink.kamelet.yaml
index 341df6965..1cebd3443 100644
--- a/kamelets/log-sink.kamelet.yaml
+++ b/kamelets/log-sink.kamelet.yaml
@@ -30,74 +30,85 @@ metadata:
spec:
definition:
title: "Log Sink"
- description: A sink that logs all data that it receives, useful for
debugging purposes.
+ description: |-
+ Writes each message it receives to the log, with its body and optionally
its headers.
+
+ Use it to see what a source sends while you build or try out an
integration, or to end a flow during a test without a real system behind it. To
log in the middle of a flow and pass the message on, use `log-action`.
+
+ Input: any message, with any kind of body.
+
+ Output: the message is unchanged.
+
+ Good to know: by default the log line shows the body and its Java type,
but not the headers. The body is logged as it is, secrets included, unless
`logMask` is true.
type: object
properties:
loggerName:
title: Logger Name
- description: Name of the logging category to use
+ description: "The name of the logger, shown on each log line. Use it
to tell these log lines apart from others, or to set their level in the logging
configuration."
type: string
default: "log-sink"
+ example: "orders"
level:
title: Log Level
- description: Logging level to use
+ description: "The level to log at. Lines at a level below the one the
logging is set to, such as `DEBUG` when the logging shows `INFO`, are not
shown. `OFF` logs nothing."
type: string
default: "INFO"
enum: ["TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF"]
logMask:
title: Log Mask
- description: Mask sensitive information like password or passphrase in
the log
+ description: "If true, values that look like secrets, such as what
follows `password=` or a header named `token`, are replaced by `xxxxx` in the
log."
type: boolean
- default: false
+ default: false
marker:
title: Marker
- description: An optional Marker name to use
+ description: "A logging marker to add to each log line, for logging
setups that filter or send log lines by marker. When it is not set, no marker
is added."
type: string
+ example: "AUDIT"
multiline:
title: Multiline
- description: If enabled then each information is outputted on a newline
+ description: "If true, each part of the log line, such as the headers,
the body type and the body, is written on a line of its own, which is easier to
read for large messages."
type: boolean
- default: false
+ default: false
showAllProperties:
title: Show All Properties
- description: Show all of the exchange properties (both internal and
custom)
+ description: "If true, also logs all the properties Camel keeps with
the message, including its internal ones. Mostly useful to Camel developers."
type: boolean
- default: false
+ default: false
showBody:
title: Show Body
- description: Show the message body
+ description: "If true, the body is logged. Set it to false for large
bodies, or bodies that must not appear in the log."
type: boolean
- default: true
+ default: true
showBodyType:
title: Show Body Type
- description: Show the body Java type
+ description: "If true, the Java type of the body is logged, such as
`String`, `byte[]` or `java.util.LinkedHashMap`, which shows what kind of body
the next step receives."
type: boolean
- default: true
+ default: true
showExchangePattern:
title: Show Exchange Pattern
- description: Shows the Message Exchange Pattern (or MEP for short)
+ description: "If true, the message pattern is logged: `InOnly` for a
one-way message, `InOut` when a reply is expected."
type: boolean
- default: true
+ default: true
showHeaders:
title: Show Headers
- description: Show the headers received
+ description: "If true, the headers of the message are logged too."
type: boolean
- default: false
+ default: false
showProperties:
title: Show Properties
- description: Show the exchange properties (only custom). Use
showAllProperties to show both internal and custom properties.
+ description: "If true, also logs the properties that the steps of the
integration set on the message, but not Camel's internal ones. Use
`showAllProperties` to see those too."
type: boolean
- default: false
+ default: false
showStreams:
title: Show Streams
- description: Show the stream bodies (they may not be available in
following steps)
+ description: "If true, a body that is a stream not cached by Camel is
logged too. Logging reads such a stream, so the next step may then get an empty
body."
type: boolean
- default: false
+ default: false
showCachedStreams:
title: Show Cached Streams
- description: Whether Camel should show cached stream bodies or not.
+ description: "If true, a body that is a stream cached by Camel, which
can be read again, is logged. Camel caches stream bodies by default, so this is
the usual case."
type: boolean
- default: true
+ default: true
dependencies:
- "camel:kamelet"
- "camel:log"
diff --git a/kamelets/simple-filter-action.kamelet.yaml
b/kamelets/simple-filter-action.kamelet.yaml
index 63b78fe87..eedb3e873 100644
--- a/kamelets/simple-filter-action.kamelet.yaml
+++ b/kamelets/simple-filter-action.kamelet.yaml
@@ -31,15 +31,25 @@ metadata:
spec:
definition:
title: "Simple Filter Action"
- description: "Filter based on simple expression."
+ description: |-
+ Drops the messages for which a condition, written in the Camel Simple
language, is true, and passes on all others.
+
+ Use it to leave out the messages you do not want, for example the test
events, with the condition `${header.type} == 'test'`. To keep only the
messages that match a condition instead, use `predicate-filter-action` (a
condition on a JSON body), `has-header-filter-action` or
`header-matches-filter-action`.
+
+ Input: any message.
+
+ Output: the same message, unchanged, when the condition is false. When
it is true, the message is dropped and nothing is sent on.
+
+ Good to know: this is the opposite of the other filter actions of the
catalog, which keep the messages that match. A condition on a header the
message does not have is false, so such a message is passed on.
required:
- expression
+ type: object
properties:
expression:
- title: Simple Expression
- description: A simple expression to apply on the exchange to filter
out some exchange
+ title: Condition
+ description: "The condition, in the Camel Simple language, that makes
a message be dropped. `$\\{body}` is the body and `${header.name}` the value of
a header. For example, `${header.type} == 'test'` drops the messages whose
`type` header is `test`, and `${header.amount} > 100` those whose `amount`
header is more than 100."
type: string
- type: object
+ example: "${header.type} == 'test'"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/throttle-action.kamelet.yaml
b/kamelets/throttle-action.kamelet.yaml
index 317295685..aeece49e7 100644
--- a/kamelets/throttle-action.kamelet.yaml
+++ b/kamelets/throttle-action.kamelet.yaml
@@ -31,21 +31,29 @@ metadata:
spec:
definition:
title: "Throttle Action"
- description: "The Throttle action allows you to ensure that a specific
sink does not get overloaded."
+ description: |-
+ Lets through at most a set number of messages per period of time, such
as 10 per second, and holds back the rest for a later period.
+
+ Use it to protect a sink or a service that cannot take more than a
certain rate, for example an API that allows 100 calls per minute. To hold
every message for a fixed time instead, use `delay-action`.
+
+ Input: any message.
+
+ Output: the same message, unchanged. The messages over the limit are not
dropped: they wait, and are passed on in a later period.
required:
- messages
+ type: object
properties:
messages:
- title: Messages Number
- description: The number of messages to send in the time period set
+ title: Message Limit
+ description: "How many messages may pass in each `timePeriod`. For
example, 10 with a `timePeriod` of 1000 lets 10 messages through per second."
type: integer
example: 10
timePeriod:
title: Time Period
- description: Sets the time period during which the maximum request
count is valid for, in milliseconds
+ description: "The length of the period that `messages` counts in, in
milliseconds. For example, 60000 is one minute."
type: string
default: "1000"
- type: object
+ example: "60000"
dependencies:
- "camel:kamelet"
template:
diff --git a/kamelets/wttrin-source.kamelet.yaml
b/kamelets/wttrin-source.kamelet.yaml
index 8621e046f..844e7c75f 100644
--- a/kamelets/wttrin-source.kamelet.yaml
+++ b/kamelets/wttrin-source.kamelet.yaml
@@ -30,29 +30,37 @@ metadata:
spec:
definition:
title: "wttr.in Source"
- description: Get weather forecasts from the wttr.in weather forecast
service
+ description: |-
+ Fetches the current weather or the forecast for a place from the public
wttr.in service at a regular interval, and sends it as JSON.
+
+ Use it to feed weather data into a dashboard, a chat message or a
decision, such as a frost alert, or as real, changing JSON data for a demo. No
account is needed.
+
+ Output: the body is JSON text. With `output` set to `current`, the
default, it is an object with the current conditions, such as `temp_C`,
`humidity` and `weatherDesc`. With `weather`, it is a list with the forecast
for each day, starting today. With `full`, it is the whole answer of wttr.in,
which has both. The `Content-Type` header is `application/json`, and the other
headers of the HTTP answer are kept.
+
+ Good to know: it calls `https://wttr.in` over the internet. When
`wttrLocation` is not set, wttr.in guesses the place from the IP address of the
machine.
type: object
properties:
period:
title: Period
- description: The interval between fetches to the wttr.in service in
milliseconds
+ description: "How long to wait between two fetches, in milliseconds.
For example, 3600000 is one hour."
type: integer
default: 60000
+ example: 3600000
wttrLocation:
title: Location
- description: The location to get weather forecasts
+ description: "The place to get the weather for: a city name such as
`Paris` or `New York`, an airport code such as `muc`, a landmark after `~` such
as `~Eiffel+tower`, a postal code, or a latitude and longitude such as
`48.85,2.35`. When it is not set, wttr.in guesses the place from the IP address
of the machine."
type: string
- example: '"paris", "~Eiffel+tower", "Москва", "muc",
"@stackoverflow.com", "94107", "-78.46,106.79"'
+ example: "Paris"
wttrLanguage:
title: Language
- description: The language to use for displaying weather forecasts
+ description: "The language of the weather descriptions, as a language
code such as `fr` or `de`. The descriptions in that language are added to the
JSON in a field such as `lang_fr`; the other fields stay in English. When it is
not set, the descriptions are in English only."
type: string
- example: 'am ar af be bn ca da de el et fr fa hi hu ia id it lt mg nb
nl oc pl pt-br ro ru ta tr th uk vi zh-cn zh-tw'
+ example: "fr"
output:
- title: Output Type
- description: The type of output
+ title: Output
+ description: "What to send: `current` for the current conditions,
`weather` for the forecast of each day, or `full` for the whole answer of
wttr.in. Any other value works like `full`."
type: string
- example: 'current, weather, full'
+ example: "weather"
default: current
types:
out:
diff --git
a/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
b/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
index 0c059e5cf..a44ff643d 100644
--- a/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
+++ b/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
@@ -594,8 +594,8 @@
"type" : "source",
"supportLevel" : "Stable",
"title" : "Chuck Norris Source",
- "summary" : "Gets periodically Chuck Norris jokes",
- "description" : "Gets periodically Chuck Norris jokes",
+ "summary" : "Fetches a random Chuck Norris joke from the public
api.chucknorris.io service at a regular interval, and sends it as a message.",
+ "description" : "Fetches a random Chuck Norris joke from the public
api.chucknorris.io service at a regular interval, and sends it as a
message.\n\nUse it to get short, changing text messages to try out a sink, an
action or a demo, with no account and no setup. For the same fixed message
every time, use `timer-source`.\n\nOutput: the body is the text of one joke.
The message has no headers.\n\nGood to know: it calls
`https://api.chucknorris.io` over the internet for every message, so [...]
"group" : "Chuck Norris",
"namespace" : "Dataset",
"provider" : "Apache Software Foundation"
@@ -634,8 +634,8 @@
"type" : "source",
"supportLevel" : "Stable",
"title" : "Counter Source",
- "summary" : "Generates sequential number events starting from a
configurable value, incrementing by a specified step. Useful for testing,
scheduled tasks, or creating ordered event sequences.",
- "description" : "Generates sequential number events starting from a
configurable value, incrementing by a specified step. Useful for testing,
scheduled tasks, or creating ordered event sequences.",
+ "summary" : "Sends a message with a number that counts up by one, such as
1, 2, 3, at a regular interval.",
+ "description" : "Sends a message with a number that counts up by one, such
as 1, 2, 3, at a regular interval.\n\nUse it to try out a sink or an action
with messages that are each different and easy to follow, or to make ordered
test data. For the same fixed message every time use `timer-source`, and for a
calendar schedule such as \"every weekday at 9:00\" use
`cron-source`.\n\nOutput: the body is the number, as an Integer (a whole
number, not text). The `Content-Type` header is `tex [...]
"group" : "Timer",
"namespace" : "Scheduling",
"provider" : "Apache Software Foundation"
@@ -644,8 +644,8 @@
"type" : "source",
"supportLevel" : "Stable",
"title" : "Cron Source",
- "summary" : "Send events at specific time.",
- "description" : "Send events at specific time.",
+ "summary" : "Sends the same fixed message on a calendar schedule, written
as a cron expression, such as every weekday at 9:00.",
+ "description" : "Sends the same fixed message on a calendar schedule,
written as a cron expression, such as every weekday at 9:00.\n\nUse it to start
a flow at set times, such as a report every morning or a clean-up every night.
For a message every few seconds or minutes, `timer-source` is simpler, and for
a message that counts up use `counter-source`.\n\nOutput: the body is the
`message` option as text, the same on every message. Headers about the schedule
are set too, such as `fire [...]
"group" : "Cron",
"namespace" : "Scheduling",
"provider" : "Apache Software Foundation"
@@ -704,8 +704,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Delay Action",
- "summary" : "Delay the processing using a specific amount of time",
- "description" : "Delay the processing using a specific amount of time",
+ "summary" : "Holds each message for a fixed time, such as one second,
before passing it on.",
+ "description" : "Holds each message for a fixed time, such as one second,
before passing it on.\n\nUse it to slow down a flow, for example to give
another system time to finish its work before the next step, or to space out
the calls of a test. To limit how many messages pass per second or per minute,
rather than holding each one, use `throttle-action`.\n\nInput: any
message.\n\nOutput: the same message, unchanged, after the wait.",
"group" : "Delay",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -724,8 +724,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "DNS DIG Action",
- "summary" : "Query a DNS through Dig.",
- "description" : "Query a DNS through Dig.",
+ "summary" : "Asks the DNS for the records of one kind, such as A or MX, of
a name, and gives the answer as text, in the format of the `dig` tool.",
+ "description" : "Asks the DNS for the records of one kind, such as A or
MX, of a name, and gives the answer as text, in the format of the `dig`
tool.\n\nUse it to see the records of a domain, such as its mail (MX) records,
for example to check a DNS change. To get only the IP address of a name, use
`dns-ip-action`, and to get its address records as JSON, use
`dns-lookup-action`.\n\nInput: the name to look up, taken from the
`domain-name` header, else from the `ce-domainname` header, [...]
"group" : "DNS",
"namespace" : "Networking",
"provider" : "Apache Software Foundation"
@@ -734,8 +734,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "DNS IP Action",
- "summary" : "Get an IP from a DNS",
- "description" : "Get an IP from a DNS",
+ "summary" : "Finds the IP address of a host name, such as `apache.org`,
and gives it as text.",
+ "description" : "Finds the IP address of a host name, such as
`apache.org`, and gives it as text.\n\nUse it to turn a host name into an
address for a later step, or to check that a name can be resolved. To see all
the address records of a name with how long they may be cached, use
`dns-lookup-action`, and to ask for other kinds of record, such as mail (MX)
records, use `dns-dig-action`.\n\nInput: the name to look up, taken from the
`domain` header, else from the `ce-domain` header, e [...]
"group" : "DNS",
"namespace" : "Networking",
"provider" : "Apache Software Foundation"
@@ -774,8 +774,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Drop Header Action",
- "summary" : "Remove an header from the message in transit.",
- "description" : "Remove an header from the message in transit.",
+ "summary" : "Removes one header, given by its name, from each message.",
+ "description" : "Removes one header, given by its name, from each
message.\n\nUse it to remove a header that the next step must not see, for
example an `Authorization` header with a secret, or a header that would change
what a sink does. To remove several headers at once by a pattern, such as all
the headers whose names start with `Camel`, use
`drop-headers-action`.\n\nInput: any message.\n\nOutput: the same body, and the
same headers without the one named by `name`. A message withou [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -784,8 +784,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Drop Headers Action",
- "summary" : "Remove headers from the message in transit based on a
pattern.",
- "description" : "Remove headers from the message in transit based on a
pattern.",
+ "summary" : "Removes from each message all the headers whose names match a
pattern, such as `Camel*`.",
+ "description" : "Removes from each message all the headers whose names
match a pattern, such as `Camel*`.\n\nUse it to remove the internal `Camel*`
headers that came with a message from outside before it reaches a sink, or to
clear many headers at once before a message goes to another system. To remove a
single header by its name, `drop-header-action` is enough.\n\nInput: any
message.\n\nOutput: the same body, without the headers that match `pattern`.
The headers that match `excludeP [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -814,8 +814,8 @@
"type" : "source",
"supportLevel" : "Stable",
"title" : "Earthquake Source",
- "summary" : "Get data about current earthquake events happening in the
world using the USGS API",
- "description" : "Get data about current earthquake events happening in the
world using the USGS API",
+ "summary" : "Sends a message for each earthquake reported by the USGS
(United States Geological Survey), checking for new reports at a regular
interval.",
+ "description" : "Sends a message for each earthquake reported by the USGS
(United States Geological Survey), checking for new reports at a regular
interval.\n\nUse it to follow the earthquakes around the world, for example to
alert on the strong ones, or as a stream of real, changing JSON data for a
demo. No account is needed.\n\nOutput: one message per earthquake. The body is
a GeoJSON feature, as JSON text: `properties` has the magnitude (`mag`), the
place, the time and a link to t [...]
"group" : "Earthquake",
"namespace" : "Dataset",
"provider" : "Apache Software Foundation"
@@ -1124,8 +1124,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Has Header Filter Action",
- "summary" : "Filter message based on the presence of one header.",
- "description" : "Filter message based on the presence of one header.",
+ "summary" : "Keeps only the messages that have a given header, optionally
with a given value, and drops all others.",
+ "description" : "Keeps only the messages that have a given header,
optionally with a given value, and drops all others.\n\nUse it to pass on only
the messages that carry a marker, such as a `priority` header, or only those of
one kind, such as the events whose `type` header is `order`. To match the value
of a header against a pattern, use `header-matches-filter-action`, and to keep
or drop messages by the content of a JSON body, use
`predicate-filter-action`.\n\nInput: any message. T [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -1134,8 +1134,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Header Matches Filter Action",
- "summary" : "Filter based on header value compared to regex.",
- "description" : "Filter based on header value compared to regex.",
+ "summary" : "Keeps only the messages whose value of a given header matches
a regular expression, and drops all others.",
+ "description" : "Keeps only the messages whose value of a given header
matches a regular expression, and drops all others.\n\nUse it to pass on only
some messages, for example only the events whose `type` header has the form
`order-` followed by a number, or only the messages of some customers by a
`customerId` header. To check only that a header is there, or has one exact
value, `has-header-filter-action` is simpler, and to filter Kafka records by
their topic, use `topic-name-matche [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -1254,8 +1254,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Insert Header Action",
- "summary" : "Adds an header with a simple language parsed expression to
the message in transit.",
- "description" : "Adds an header with a simple language parsed expression
to the message in transit.",
+ "summary" : "Adds a header to each message, or replaces it, with a fixed
text or a value taken from the message.",
+ "description" : "Adds a header to each message, or replaces it, with a
fixed text or a value taken from the message.\n\nUse it to give a sink the
headers it reads, such as the `ce-projectKey` header of `jira-add-issue-sink`,
to tag messages with where they come from, or to copy the body into a header
for a later step. To set the key of a Kafka record, `set-kafka-key-action` is
simpler.\n\nInput: any message.\n\nOutput: the same body. The header named by
`name` is set to `value`, and [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -1434,8 +1434,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Json Deserialize Action",
- "summary" : "Deserialize payload to JSON.",
- "description" : "Deserialize payload to JSON.",
+ "summary" : "Turns a body of JSON text into parsed JSON, a Jackson
`JsonNode`, so that the next steps can work with its fields.",
+ "description" : "Turns a body of JSON text into parsed JSON, a Jackson
`JsonNode`, so that the next steps can work with its fields.\n\nUse it to
prepare a message for a step that needs parsed JSON rather than text, such as
`jsonata-action`, or to make sure that a body is well-formed JSON. To turn
parsed data back into JSON text, use `json-serialize-action`, and to check JSON
against a schema, use `json-schema-validator-action`.\n\nInput: JSON text, as
text or bytes: a JSON object or [...]
"group" : "Actions",
"namespace" : "JSON",
"provider" : "Apache Software Foundation"
@@ -1444,8 +1444,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Json Schema Validator Action",
- "summary" : "Apply a Json Schema Template to validate the payload
against.",
- "description" : "Apply a Json Schema Template to validate the payload
against.",
+ "summary" : "Checks that each JSON message matches a JSON Schema, and
fails the messages that do not.",
+ "description" : "Checks that each JSON message matches a JSON Schema, and
fails the messages that do not.\n\nUse it to stop bad data early, for example
to reject the orders that miss a required field before they reach a database or
another system. To keep or drop messages by a condition instead of failing
them, use `predicate-filter-action`.\n\nInput: JSON text, as text, bytes or a
stream, or parsed JSON from `json-deserialize-action`. A Map fails.\n\nOutput:
the same message, unchan [...]
"group" : "Actions",
"namespace" : "JSON",
"provider" : "Apache Software Foundation"
@@ -1454,8 +1454,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Json Serialize Action",
- "summary" : "Serialize payload to JSON.",
- "description" : "Serialize payload to JSON.",
+ "summary" : "Turns a body of parsed data, such as a Map, a List or parsed
JSON, into JSON text.",
+ "description" : "Turns a body of parsed data, such as a Map, a List or
parsed JSON, into JSON text.\n\nUse it to send parsed data to a sink that needs
JSON text, for example after `jsonata-action` or `json-deserialize-action`,
whose output is parsed JSON. To do the opposite, use
`json-deserialize-action`.\n\nInput: parsed data: a Map, a List, or parsed JSON
(a Jackson `JsonNode`).\n\nOutput: the body is JSON text, as a stream of bytes.
The `Content-Type` header is set to `application [...]
"group" : "Actions",
"namespace" : "JSON",
"provider" : "Apache Software Foundation"
@@ -1464,8 +1464,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Jsonata Action",
- "summary" : "Apply a Jsonata Transformation.",
- "description" : "Apply a Jsonata Transformation.",
+ "summary" : "Transforms each JSON message with a JSONata expression, to
reshape it, pick out fields, or compute new values.",
+ "description" : "Transforms each JSON message with a JSONata expression,
to reshape it, pick out fields, or compute new values.\n\nUse it to turn the
JSON of one system into the JSON another system expects, for example to rename
fields, join a first and a last name, or add up the lines of an order. For
other ways to reshape JSON, see `jslt-action` and `jolt-transformation-action`;
to build text, such as an email, from a template, use
`mustache-template-action`.\n\nInput: parsed JSON, [...]
"group" : "Actions",
"namespace" : "JSON",
"provider" : "Apache Software Foundation"
@@ -1674,8 +1674,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Log Action",
- "summary" : "Logs all data that flows between source and sink, useful for
debugging purposes.",
- "description" : "Logs all data that flows between source and sink, useful
for debugging purposes.",
+ "summary" : "Writes each message to the log, with its body and optionally
its headers, and passes it on unchanged.",
+ "description" : "Writes each message to the log, with its body and
optionally its headers, and passes it on unchanged.\n\nUse it to see what flows
between two steps while you build or debug an integration, for example what a
source really sends before a sink fails on it. To log at the end of a flow
instead, use `log-sink`.\n\nInput: any message.\n\nOutput: the message is
unchanged.\n\nGood to know: by default the log line shows the body and its Java
type, but not the headers. The bod [...]
"group" : "Logging",
"namespace" : "Logging",
"provider" : "Apache Software Foundation"
@@ -1684,8 +1684,8 @@
"type" : "sink",
"supportLevel" : "Stable",
"title" : "Log Sink",
- "summary" : "A sink that logs all data that it receives, useful for
debugging purposes.",
- "description" : "A sink that logs all data that it receives, useful for
debugging purposes.",
+ "summary" : "Writes each message it receives to the log, with its body and
optionally its headers.",
+ "description" : "Writes each message it receives to the log, with its body
and optionally its headers.\n\nUse it to see what a source sends while you
build or try out an integration, or to end a flow during a test without a real
system behind it. To log in the middle of a flow and pass the message on, use
`log-action`.\n\nInput: any message, with any kind of body.\n\nOutput: the
message is unchanged.\n\nGood to know: by default the log line shows the body
and its Java type, but not t [...]
"group" : "Logging",
"namespace" : "Logging",
"provider" : "Apache Software Foundation"
@@ -2254,8 +2254,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Simple Filter Action",
- "summary" : "Filter based on simple expression.",
- "description" : "Filter based on simple expression.",
+ "summary" : "Drops the messages for which a condition, written in the
Camel Simple language, is true, and passes on all others.",
+ "description" : "Drops the messages for which a condition, written in the
Camel Simple language, is true, and passes on all others.\n\nUse it to leave
out the messages you do not want, for example the test events, with the
condition `${header.type} == 'test'`. To keep only the messages that match a
condition instead, use `predicate-filter-action` (a condition on a JSON body),
`has-header-filter-action` or `header-matches-filter-action`.\n\nInput: any
message.\n\nOutput: the same mess [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -2454,8 +2454,8 @@
"type" : "action",
"supportLevel" : "Stable",
"title" : "Throttle Action",
- "summary" : "The Throttle action allows you to ensure that a specific sink
does not get overloaded.",
- "description" : "The Throttle action allows you to ensure that a specific
sink does not get overloaded.",
+ "summary" : "Lets through at most a set number of messages per period of
time, such as 10 per second, and holds back the rest for a later period.",
+ "description" : "Lets through at most a set number of messages per period
of time, such as 10 per second, and holds back the rest for a later
period.\n\nUse it to protect a sink or a service that cannot take more than a
certain rate, for example an API that allows 100 calls per minute. To hold
every message for a fixed time instead, use `delay-action`.\n\nInput: any
message.\n\nOutput: the same message, unchanged. The messages over the limit
are not dropped: they wait, and are passed [...]
"group" : "Actions",
"namespace" : "EIP",
"provider" : "Apache Software Foundation"
@@ -2564,8 +2564,8 @@
"type" : "source",
"supportLevel" : "Stable",
"title" : "wttr.in Source",
- "summary" : "Get weather forecasts from the wttr.in weather forecast
service",
- "description" : "Get weather forecasts from the wttr.in weather forecast
service",
+ "summary" : "Fetches the current weather or the forecast for a place from
the public wttr.in service at a regular interval, and sends it as JSON.",
+ "description" : "Fetches the current weather or the forecast for a place
from the public wttr.in service at a regular interval, and sends it as
JSON.\n\nUse it to feed weather data into a dashboard, a chat message or a
decision, such as a frost alert, or as real, changing JSON data for a demo. No
account is needed.\n\nOutput: the body is JSON text. With `output` set to
`current`, the default, it is an object with the current conditions, such as
`temp_C`, `humidity` and `weatherDesc`. [...]
"group" : "Weather",
"namespace" : "Dataset",
"provider" : "Apache Software Foundation"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/chuck-norris-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/chuck-norris-source.kamelet.yaml
index 82507b261..8bcd63426 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/chuck-norris-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/chuck-norris-source.kamelet.yaml
@@ -30,14 +30,22 @@ metadata:
spec:
definition:
title: "Chuck Norris Source"
- description: Gets periodically Chuck Norris jokes
+ description: |-
+ Fetches a random Chuck Norris joke from the public api.chucknorris.io
service at a regular interval, and sends it as a message.
+
+ Use it to get short, changing text messages to try out a sink, an action
or a demo, with no account and no setup. For the same fixed message every time,
use `timer-source`.
+
+ Output: the body is the text of one joke. The message has no headers.
+
+ Good to know: it calls `https://api.chucknorris.io` over the internet
for every message, so it needs internet access.
type: object
properties:
period:
title: Period
- description: The interval (msec) to wait before getting the next joke
+ description: "How long to wait between two jokes, in milliseconds. For
example, 60000 is one minute."
type: integer
default: 10000
+ example: 60000
types:
out:
mediaType: text/plain
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/counter-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/counter-source.kamelet.yaml
index 067fa36b6..58ee2daf2 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/counter-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/counter-source.kamelet.yaml
@@ -32,23 +32,40 @@ metadata:
spec:
definition:
title: "Counter Source"
- description: Generates sequential number events starting from a
configurable value, incrementing by a specified step. Useful for testing,
scheduled tasks, or creating ordered event sequences.
+ description: |-
+ Sends a message with a number that counts up by one, such as 1, 2, 3, at
a regular interval.
+
+ Use it to try out a sink or an action with messages that are each
different and easy to follow, or to make ordered test data. For the same fixed
message every time use `timer-source`, and for a calendar schedule such as
"every weekday at 9:00" use `cron-source`.
+
+ Output: the body is the number, as an Integer (a whole number, not
text). The `Content-Type` header is `text/plain`.
+
+ Good to know: it keeps sending until the integration is stopped, unless
`numbers` is set. The count starts again from `start` when the integration
restarts.
type: object
properties:
period:
title: Period
- description: The time interval between two numbers
+ description: "How long to wait between two messages, in milliseconds.
For example, 60000 is one minute."
type: integer
default: 1000
+ example: 60000
start:
- title: Starting Number
- description: The starting number
+ title: Start
+ description: "The number in the first message. Each next message has a
number one higher."
type: integer
default: 1
+ example: 100
numbers:
- title: Numbers
- description: How many numbers to generate
+ title: Number of Messages
+ description: "How many messages to send in total. When it is not set,
a message is sent every `period` until the integration is stopped."
type: integer
+ example: 10
+ dataTypes:
+ out:
+ headers:
+ Content-Type:
+ title: Content Type
+ description: "Always `text/plain`."
+ type: string
dependencies:
- "camel:timer"
- "camel:kamelet"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/cron-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/cron-source.kamelet.yaml
index fea1afd9e..9c4cf8c8e 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/cron-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/cron-source.kamelet.yaml
@@ -31,7 +31,14 @@ metadata:
spec:
definition:
title: "Cron Source"
- description: Send events at specific time.
+ description: |-
+ Sends the same fixed message on a calendar schedule, written as a cron
expression, such as every weekday at 9:00.
+
+ Use it to start a flow at set times, such as a report every morning or a
clean-up every night. For a message every few seconds or minutes,
`timer-source` is simpler, and for a message that counts up use
`counter-source`.
+
+ Output: the body is the `message` option as text, the same on every
message. Headers about the schedule are set too, such as `fireTime` (the time
of this message) and `nextFireTime`.
+
+ Good to know: the times are in the time zone of the machine it runs on.
It keeps sending until the integration is stopped.
required:
- schedule
- message
@@ -39,14 +46,14 @@ spec:
properties:
schedule:
title: Cron Schedule
- description: A cron expression that is used to trigger events
generation.
+ description: "When to send a message, as a Quartz cron expression of
six or seven fields: seconds, minutes, hours, day of month, month, day of week,
and an optional year. For example, `0 0 9 ? * MON-FRI` is 9:00 every weekday,
and `0 */5 * * * ?` is every five minutes. A Unix cron expression of five
fields, without the seconds, works too."
type: string
- example: "0/3 10 * * * ?"
+ example: "0 0 9 ? * MON-FRI"
message:
title: Message
- description: The message to generate
+ description: "The body of every message, sent as text exactly as
written."
type: string
- example: hello world
+ example: "hello world"
types:
out:
mediaType: text/plain
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/delay-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/delay-action.kamelet.yaml
index 894d92611..655997955 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/delay-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/delay-action.kamelet.yaml
@@ -31,14 +31,21 @@ metadata:
spec:
definition:
title: "Delay Action"
- description: Delay the processing using a specific amount of time
+ description: |-
+ Holds each message for a fixed time, such as one second, before passing
it on.
+
+ Use it to slow down a flow, for example to give another system time to
finish its work before the next step, or to space out the calls of a test. To
limit how many messages pass per second or per minute, rather than holding each
one, use `throttle-action`.
+
+ Input: any message.
+
+ Output: the same message, unchanged, after the wait.
required:
- milliseconds
type: object
properties:
milliseconds:
- title: Milliseconds
- description: The number of milliseconds of delay
+ title: Delay in Milliseconds
+ description: "How long to hold each message, in milliseconds. For
example, 1000 is one second."
type: integer
example: 1000
dependencies:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/dns-dig-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/dns-dig-action.kamelet.yaml
index 31314894c..76c97ae62 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/dns-dig-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/dns-dig-action.kamelet.yaml
@@ -30,8 +30,36 @@ metadata:
spec:
definition:
title: "DNS DIG Action"
- description: Query a DNS through Dig.
+ description: |-
+ Asks the DNS for the records of one kind, such as A or MX, of a name,
and gives the answer as text, in the format of the `dig` tool.
+
+ Use it to see the records of a domain, such as its mail (MX) records,
for example to check a DNS change. To get only the IP address of a name, use
`dns-ip-action`, and to get its address records as JSON, use
`dns-lookup-action`.
+
+ Input: the name to look up, taken from the `domain-name` header, else
from the `ce-domainname` header, else from the body as text. The kind of record
comes from the `dns-type` header, else from the `ce-dnstype` header, else it is
`A` (the IPv4 addresses).
+
+ Output: the body is the whole answer as text, as the `dig` command shows
it: the question, the records found, and the status, such as `NOERROR`.
+
+ Good to know: a name the DNS does not know does not fail the message:
the answer has the status `NXDOMAIN` and no records. The Kamelet has no
options; it asks the DNS servers of the machine it runs on.
type: object
+ dataTypes:
+ in:
+ headers:
+ domain-name:
+ title: Domain Name
+ description: "The name to look up, such as `apache.org`. When it is
not set, `ce-domainname` is used, and then the body."
+ type: string
+ ce-domainname:
+ title: Domain Name (CloudEvents)
+ description: "The name to look up, when the message is a CloudEvent.
Used only when `domain-name` is not set."
+ type: string
+ dns-type:
+ title: Record Type
+ description: "The kind of record to ask for, such as `A`, `AAAA` or
`MX`. When it is not set, `ce-dnstype` is used, and then `A`."
+ type: string
+ ce-dnstype:
+ title: Record Type (CloudEvents)
+ description: "The kind of record to ask for, when the message is a
CloudEvent. Used only when `dns-type` is not set."
+ type: string
dependencies:
- "camel:dns"
- "camel:kamelet"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/dns-ip-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/dns-ip-action.kamelet.yaml
index 3d9b91735..b1bff351e 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/dns-ip-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/dns-ip-action.kamelet.yaml
@@ -31,8 +31,28 @@ metadata:
spec:
definition:
title: "DNS IP Action"
- description: Get an IP from a DNS
+ description: |-
+ Finds the IP address of a host name, such as `apache.org`, and gives it
as text.
+
+ Use it to turn a host name into an address for a later step, or to check
that a name can be resolved. To see all the address records of a name with how
long they may be cached, use `dns-lookup-action`, and to ask for other kinds of
record, such as mail (MX) records, use `dns-dig-action`.
+
+ Input: the name to look up, taken from the `domain` header, else from
the `ce-domain` header, else from the body as text.
+
+ Output: the body is one IP address, as text, such as `151.101.2.132`.
+
+ Good to know: when a name has several addresses, only one of them is
given. A name the DNS does not know fails the message with an unknown host
error. The headers are `domain` and `ce-domain`, not `domain-name` as for
`dns-lookup-action` and `dns-dig-action`. The Kamelet has no options; it uses
the name resolution of the machine it runs on.
type: object
+ dataTypes:
+ in:
+ headers:
+ domain:
+ title: Domain
+ description: "The host name to look up, such as `apache.org`. When
it is not set, `ce-domain` is used, and then the body."
+ type: string
+ ce-domain:
+ title: Domain (CloudEvents)
+ description: "The host name to look up, when the message is a
CloudEvent. Used only when `domain` is not set."
+ type: string
dependencies:
- "camel:dns"
- "camel:kamelet"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/drop-header-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/drop-header-action.kamelet.yaml
index 03e62617d..7ecdac0b1 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/drop-header-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/drop-header-action.kamelet.yaml
@@ -30,16 +30,25 @@ metadata:
spec:
definition:
title: "Drop Header Action"
- description: "Remove an header from the message in transit."
+ description: |-
+ Removes one header, given by its name, from each message.
+
+ Use it to remove a header that the next step must not see, for example
an `Authorization` header with a secret, or a header that would change what a
sink does. To remove several headers at once by a pattern, such as all the
headers whose names start with `Camel`, use `drop-headers-action`.
+
+ Input: any message.
+
+ Output: the same body, and the same headers without the one named by
`name`. A message without that header passes on unchanged.
+
+ Good to know: the name is not case-sensitive: `FOO` also removes the
header `foo`.
required:
- name
+ type: object
properties:
name:
- title: Name
- description: The name of the header to be removed.
+ title: Header Name
+ description: "The name of the header to remove, such as
`Authorization`. Upper and lower case do not matter."
type: string
- example: headername
- type: object
+ example: "Authorization"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/drop-headers-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/drop-headers-action.kamelet.yaml
index 05330707e..5317a9499 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/drop-headers-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/drop-headers-action.kamelet.yaml
@@ -30,21 +30,30 @@ metadata:
spec:
definition:
title: "Drop Headers Action"
- description: "Remove headers from the message in transit based on a
pattern."
+ description: |-
+ Removes from each message all the headers whose names match a pattern,
such as `Camel*`.
+
+ Use it to remove the internal `Camel*` headers that came with a message
from outside before it reaches a sink, or to clear many headers at once before
a message goes to another system. To remove a single header by its name,
`drop-header-action` is enough.
+
+ Input: any message.
+
+ Output: the same body, without the headers that match `pattern`. The
headers that match `excludePattern` are kept.
+
+ Good to know: a pattern is compared with each header name first as an
exact name, then as a wildcard when it ends with `*` (`x-*` matches every name
that starts with `x-`), and then as a Java regular expression, such as
`x-(one|two)`. None of these comparisons is case-sensitive.
required:
- pattern
+ type: object
properties:
pattern:
- title: Pattern
- description: Name or pattern of headers to remove. The pattern is
matched in the following order, 1 = exact match 2 = wildcard (pattern ends with
a and the name starts with the pattern) 3 = regular expression (all of above is
case in-sensitive).
+ title: Header Pattern
+ description: "The headers to remove: an exact header name, a text that
ends with `*` to match every name that starts with the text before it, or a
regular expression. Upper and lower case do not matter."
type: string
- example: Camel*
+ example: "Camel*"
excludePattern:
title: Exclusion Pattern
- description: Name or pattern of headers to not remove. The pattern is
matched in the following order, 1 = exact match 2 = wildcard (pattern ends with
a and the name starts with the pattern) 3 = regular expression (all of above is
case in-sensitive).
+ description: "The headers to keep even when they match `pattern`,
written in the same way. When it is not set, every header that matches
`pattern` is removed."
type: string
- example: Camel*
- type: object
+ example: "CamelKafkaKey"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/earthquake-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/earthquake-source.kamelet.yaml
index c705b3aac..4b2bb1f7c 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/earthquake-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/earthquake-source.kamelet.yaml
@@ -31,19 +31,28 @@ metadata:
spec:
definition:
title: "Earthquake Source"
- description: Get data about current earthquake events happening in the
world using the USGS API
+ description: |-
+ Sends a message for each earthquake reported by the USGS (United States
Geological Survey), checking for new reports at a regular interval.
+
+ Use it to follow the earthquakes around the world, for example to alert
on the strong ones, or as a stream of real, changing JSON data for a demo. No
account is needed.
+
+ Output: one message per earthquake. The body is a GeoJSON feature, as
JSON text: `properties` has the magnitude (`mag`), the place, the time and a
link to the USGS page, and `geometry` has the longitude, the latitude and the
depth. The `Content-Type` header is `application/json`.
+
+ Good to know: the first check sends the earthquakes whose report was
updated in the last `lookAhead` minutes, and each later check those updated
since the check before. An earthquake is sent again when USGS updates its
report. The time of the last check is kept in memory only, so a restart begins
again with the last `lookAhead` minutes. It calls `https://earthquake.usgs.gov`
over the internet.
type: object
properties:
period:
- title: Period between Polls
- description: The interval between fetches to the earthquake API in
milliseconds.
+ title: Period
+ description: "How long to wait between two checks for new reports, in
milliseconds. For example, 300000 is five minutes."
type: integer
default: 60000
+ example: 300000
lookAhead:
- title: Look-ahead Minutes
- description: The amount of minutes to look ahead when starting the
integration afresh.
+ title: Minutes to Look Back
+ description: "When the integration starts, how many minutes back to
look for earthquake reports. For example, 1440 first sends the reports of the
last day."
type: integer
default: 120
+ example: 1440
types:
out:
mediaType: application/json
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/has-header-filter-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/has-header-filter-action.kamelet.yaml
index 97f2c00ad..87094259f 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/has-header-filter-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/has-header-filter-action.kamelet.yaml
@@ -30,21 +30,30 @@ metadata:
spec:
definition:
title: "Has Header Filter Action"
- description: "Filter message based on the presence of one header."
+ description: |-
+ Keeps only the messages that have a given header, optionally with a
given value, and drops all others.
+
+ Use it to pass on only the messages that carry a marker, such as a
`priority` header, or only those of one kind, such as the events whose `type`
header is `order`. To match the value of a header against a pattern, use
`header-matches-filter-action`, and to keep or drop messages by the content of
a JSON body, use `predicate-filter-action`.
+
+ Input: any message. The header named by `name` is read.
+
+ Output: the same message, unchanged, when it has the header and, when
`value` is set, when the header has exactly that value. Otherwise the message
is dropped and nothing is sent on.
+
+ Good to know: the comparison with `value` is case-sensitive: `order`
does not match `Order`. A header with an empty value counts as present when
`value` is not set.
required:
- name
+ type: object
properties:
name:
title: Header Name
- description: The header name to evaluate. The header name must be
passed by the source Kamelet. For Knative only, the name of the header requires
a CloudEvent (ce-) prefix.
+ description: "The name of the header the message must have to be kept,
such as `priority`. The header must already be on the message, for example set
by the source. With Knative, the name of a CloudEvent attribute starts with
`ce-`, such as `ce-type`."
type: string
- example: headerName
+ example: "priority"
value:
title: Header Value
- description: An optional header value to compare the header to
+ description: "The value the header must have, exactly, for the message
to be kept, such as `high`. When it is not set, any value is enough, as long as
the header is there."
type: string
- example: headerValue
- type: object
+ example: "high"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/header-matches-filter-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/header-matches-filter-action.kamelet.yaml
index 10050d0f8..9f5021d80 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/header-matches-filter-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/header-matches-filter-action.kamelet.yaml
@@ -30,21 +30,31 @@ metadata:
spec:
definition:
title: "Header Matches Filter Action"
- description: "Filter based on header value compared to regex."
+ description: |-
+ Keeps only the messages whose value of a given header matches a regular
expression, and drops all others.
+
+ Use it to pass on only some messages, for example only the events whose
`type` header has the form `order-` followed by a number, or only the messages
of some customers by a `customerId` header. To check only that a header is
there, or has one exact value, `has-header-filter-action` is simpler, and to
filter Kafka records by their topic, use `topic-name-matches-filter-action`.
+
+ Input: any message. The header named by `headerName` is read.
+
+ Output: the same message, unchanged, when the value of the header
matches `regex`. Otherwise, and when the message does not have the header, the
message is dropped and nothing is sent on.
+
+ Good to know: the expression must match the whole value, not only a part
of it: `order-[0-9]+` matches `order-1` but not `x-order-1`, and it is
case-sensitive. `headerName` must be set: the Kamelet does not start without it.
required:
- regex
- headerName
+ type: object
properties:
regex:
- title: Regex
- description: The Regex to Evaluate against the Kafka topic name
+ title: Regular Expression
+ description: "A Java regular expression that the whole value of the
header must match for the message to be kept. For example, `order-[0-9]+` keeps
the values `order-1` and `order-55`."
type: string
+ example: "order-[0-9]+"
headerName:
- title: Header Name
- description: The header name to get the value to compare
+ title: Header Name
+ description: "The name of the header whose value is matched, such as
`type`. It must be set: the Kamelet does not start without it."
type: string
- example: headerName
- type: object
+ example: "type"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/insert-header-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/insert-header-action.kamelet.yaml
index 454b22d9c..5a61f5de2 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/insert-header-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/insert-header-action.kamelet.yaml
@@ -30,21 +30,31 @@ metadata:
spec:
definition:
title: "Insert Header Action"
- description: "Adds an header with a simple language parsed expression to
the message in transit."
+ description: |-
+ Adds a header to each message, or replaces it, with a fixed text or a
value taken from the message.
+
+ Use it to give a sink the headers it reads, such as the `ce-projectKey`
header of `jira-add-issue-sink`, to tag messages with where they come from, or
to copy the body into a header for a later step. To set the key of a Kafka
record, `set-kafka-key-action` is simpler.
+
+ Input: any message.
+
+ Output: the same body. The header named by `name` is set to `value`, and
replaces a header of the same name.
+
+ Good to know: `value` is written in the Camel Simple language: plain
text is used as it is, and the `${...}` parts are filled in from the message,
such as `$\{body}` for the body, or `${header.source}` for the value of the
header `source`.
required:
- name
- value
+ type: object
properties:
name:
- title: Name
- description: The name of the header to be added. For Knative only, the
name of the header requires a CloudEvent (ce-) prefix.
+ title: Header Name
+ description: "The name of the header to set, such as `source`. With
Knative, the name must start with `ce-`, the prefix of the CloudEvent
attributes."
type: string
- example: headername
+ example: "source"
value:
- title: Value
- description: The value of the header to be added
+ title: Header Value
+ description: "The value of the header: plain text, such as
`orders-app`, or a Simple expression whose `${...}` parts are filled in from
the message, such as `$\\{body}` or `${header.customerId}`."
type: string
- type: object
+ example: "${header.customerId}"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/json-deserialize-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/json-deserialize-action.kamelet.yaml
index ebb18cb4c..d13cfc27e 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/json-deserialize-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/json-deserialize-action.kamelet.yaml
@@ -30,7 +30,16 @@ metadata:
spec:
definition:
title: "Json Deserialize Action"
- description: "Deserialize payload to JSON."
+ description: |-
+ Turns a body of JSON text into parsed JSON, a Jackson `JsonNode`, so
that the next steps can work with its fields.
+
+ Use it to prepare a message for a step that needs parsed JSON rather
than text, such as `jsonata-action`, or to make sure that a body is well-formed
JSON. To turn parsed data back into JSON text, use `json-serialize-action`, and
to check JSON against a schema, use `json-schema-validator-action`.
+
+ Input: JSON text, as text or bytes: a JSON object or a JSON array.
+
+ Output: the body is parsed JSON, a Jackson `JsonNode`: an object node
for a JSON object, an array node for a JSON array. The `Content-Type` header is
removed.
+
+ Good to know: a body that is not valid JSON fails the message.
type: object
dependencies:
- "camel:kamelet"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/json-schema-validator-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/json-schema-validator-action.kamelet.yaml
index ee19799f1..7faa82c0f 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/json-schema-validator-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/json-schema-validator-action.kamelet.yaml
@@ -30,16 +30,25 @@ metadata:
spec:
definition:
title: "Json Schema Validator Action"
- description: Apply a Json Schema Template to validate the payload against.
+ description: |-
+ Checks that each JSON message matches a JSON Schema, and fails the
messages that do not.
+
+ Use it to stop bad data early, for example to reject the orders that
miss a required field before they reach a database or another system. To keep
or drop messages by a condition instead of failing them, use
`predicate-filter-action`.
+
+ Input: JSON text, as text, bytes or a stream, or parsed JSON from
`json-deserialize-action`. A Map fails.
+
+ Output: the same message, unchanged, when it matches the schema.
+
+ Good to know: a message that does not match the schema, or that is not
JSON, fails with an error that lists what is wrong; it is not dropped silently,
so the error handling of the integration decides what happens to it. The schema
is loaded from the `template` location; it cannot come from the message.
required:
- template
type: object
properties:
template:
- title: Template
+ title: Schema Location
description: "Where to load the JSON Schema from, not the JSON Schema
itself: `file://` followed by the path of a file, `classpath://` followed by a
resource in the application, or an `http://` or `https://` URL."
type: string
- example: "file:////template.json"
+ example: "file:///etc/camel/order-schema.json"
pattern: "^(http|https|file|classpath|ref|bean)://.*"
dependencies:
- "camel:json-validator"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/json-serialize-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/json-serialize-action.kamelet.yaml
index 3af39183d..31bb72a8c 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/json-serialize-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/json-serialize-action.kamelet.yaml
@@ -30,8 +30,24 @@ metadata:
spec:
definition:
title: "Json Serialize Action"
- description: "Serialize payload to JSON."
+ description: |-
+ Turns a body of parsed data, such as a Map, a List or parsed JSON, into
JSON text.
+
+ Use it to send parsed data to a sink that needs JSON text, for example
after `jsonata-action` or `json-deserialize-action`, whose output is parsed
JSON. To do the opposite, use `json-deserialize-action`.
+
+ Input: parsed data: a Map, a List, or parsed JSON (a Jackson `JsonNode`).
+
+ Output: the body is JSON text, as a stream of bytes. The `Content-Type`
header is set to `application/json`.
+
+ Good to know: a body that is already text becomes one JSON string, in
quotes: `hello` becomes `"hello"`, and JSON text is quoted the same way. Do not
use it on a body that is already JSON text.
type: object
+ dataTypes:
+ out:
+ headers:
+ Content-Type:
+ title: Content Type
+ description: "Always `application/json`."
+ type: string
dependencies:
- "camel:kamelet"
- "camel:jackson"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/jsonata-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/jsonata-action.kamelet.yaml
index b656ab4d5..975ae7a03 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/jsonata-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/jsonata-action.kamelet.yaml
@@ -30,16 +30,25 @@ metadata:
spec:
definition:
title: "Jsonata Action"
- description: Apply a Jsonata Transformation.
+ description: |-
+ Transforms each JSON message with a JSONata expression, to reshape it,
pick out fields, or compute new values.
+
+ Use it to turn the JSON of one system into the JSON another system
expects, for example to rename fields, join a first and a last name, or add up
the lines of an order. For other ways to reshape JSON, see `jslt-action` and
`jolt-transformation-action`; to build text, such as an email, from a template,
use `mustache-template-action`.
+
+ Input: parsed JSON, such as a Map, a List, or the output of
`json-deserialize-action`.
+
+ Output: the body is the result of the expression, as parsed JSON (a
Jackson `JsonNode`), not as text: add `json-serialize-action` after it to get
JSON text. The headers are kept.
+
+ Good to know: put `json-deserialize-action` before it when the body is
JSON text, as depending on the Camel version the expression sees JSON text as
one string rather than as an object, and bytes or a stream fail. The expression
is loaded from the `template` location; it cannot come from the message.
required:
- template
type: object
properties:
template:
- title: Template
+ title: Expression Location
description: "Where to load the JSONata expression from, not the
JSONata expression itself: `file://` followed by the path of a file,
`classpath://` followed by a resource in the application, or an `http://` or
`https://` URL."
type: string
- example: "file:////template.spec"
+ example: "file:///etc/camel/order.jsonata"
pattern: "^(http|https|file|classpath|ref|bean)://.*"
dependencies:
- "camel:jsonata"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/log-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/log-action.kamelet.yaml
index 5e23d38b3..c44530937 100644
--- a/library/camel-kamelets/src/main/resources/kamelets/log-action.kamelet.yaml
+++ b/library/camel-kamelets/src/main/resources/kamelets/log-action.kamelet.yaml
@@ -30,74 +30,85 @@ metadata:
spec:
definition:
title: "Log Action"
- description: Logs all data that flows between source and sink, useful for
debugging purposes.
+ description: |-
+ Writes each message to the log, with its body and optionally its
headers, and passes it on unchanged.
+
+ Use it to see what flows between two steps while you build or debug an
integration, for example what a source really sends before a sink fails on it.
To log at the end of a flow instead, use `log-sink`.
+
+ Input: any message.
+
+ Output: the message is unchanged.
+
+ Good to know: by default the log line shows the body and its Java type,
but not the headers. The body is logged as it is, secrets included, unless
`logMask` is true.
type: object
properties:
loggerName:
title: Logger Name
- description: Name of the logging category to use.
+ description: "The name of the logger, shown on each log line. Use it
to tell these log lines apart from others, or to set their level in the logging
configuration."
type: string
default: "log-action"
+ example: "orders-debug"
level:
title: Log Level
- description: Logging level to use.
+ description: "The level to log at. Lines at a level below the one the
logging is set to, such as `DEBUG` when the logging shows `INFO`, are not
shown. `OFF` logs nothing."
type: string
default: "INFO"
enum: ["TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF"]
logMask:
title: Log Mask
- description: Mask sensitive information like password or passphrase in
the log.
+ description: "If true, values that look like secrets, such as what
follows `password=` or a header named `token`, are replaced by `xxxxx` in the
log."
type: boolean
- default: false
+ default: false
marker:
title: Marker
- description: An optional Marker name to use.
+ description: "A logging marker to add to each log line, for logging
setups that filter or send log lines by marker. When it is not set, no marker
is added."
type: string
+ example: "AUDIT"
multiline:
title: Multiline
- description: If enabled then each information is outputted on a
newline.
+ description: "If true, each part of the log line, such as the headers,
the body type and the body, is written on a line of its own, which is easier to
read for large messages."
type: boolean
- default: false
+ default: false
showAllProperties:
title: Show All Properties
- description: Show all of the exchange properties (both internal and
custom).
+ description: "If true, also logs all the properties Camel keeps with
the message, including its internal ones. Mostly useful to Camel developers."
type: boolean
- default: false
+ default: false
showBody:
title: Show Body
- description: Show the message body.
+ description: "If true, the body is logged. Set it to false for large
bodies, or bodies that must not appear in the log."
type: boolean
- default: true
+ default: true
showBodyType:
title: Show Body Type
- description: Show the body Java type
+ description: "If true, the Java type of the body is logged, such as
`String`, `byte[]` or `java.util.LinkedHashMap`, which shows what kind of body
the next step receives."
type: boolean
- default: true
+ default: true
showExchangePattern:
title: Show Exchange Pattern
- description: Shows the Message Exchange Pattern (or MEP for short)
+ description: "If true, the message pattern is logged: `InOnly` for a
one-way message, `InOut` when a reply is expected."
type: boolean
- default: true
+ default: true
showHeaders:
title: Show Headers
- description: Show the headers received
+ description: "If true, the headers of the message are logged too."
type: boolean
- default: false
+ default: false
showProperties:
title: Show Properties
- description: Show the exchange properties (only custom). Use
showAllProperties to show both internal and custom properties.
+ description: "If true, also logs the properties that the steps of the
integration set on the message, but not Camel's internal ones. Use
`showAllProperties` to see those too."
type: boolean
- default: false
+ default: false
showStreams:
title: Show Streams
- description: Show the stream bodies (they may not be available in
following steps)
+ description: "If true, a body that is a stream not cached by Camel is
logged too. Logging reads such a stream, so the next step may then get an empty
body."
type: boolean
- default: false
+ default: false
showCachedStreams:
title: Show Cached Streams
- description: Whether Camel should show cached stream bodies or not.
+ description: "If true, a body that is a stream cached by Camel, which
can be read again, is logged. Camel caches stream bodies by default, so this is
the usual case."
type: boolean
- default: true
+ default: true
dependencies:
- "camel:kamelet"
- "camel:log"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/log-sink.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/log-sink.kamelet.yaml
index 341df6965..1cebd3443 100644
--- a/library/camel-kamelets/src/main/resources/kamelets/log-sink.kamelet.yaml
+++ b/library/camel-kamelets/src/main/resources/kamelets/log-sink.kamelet.yaml
@@ -30,74 +30,85 @@ metadata:
spec:
definition:
title: "Log Sink"
- description: A sink that logs all data that it receives, useful for
debugging purposes.
+ description: |-
+ Writes each message it receives to the log, with its body and optionally
its headers.
+
+ Use it to see what a source sends while you build or try out an
integration, or to end a flow during a test without a real system behind it. To
log in the middle of a flow and pass the message on, use `log-action`.
+
+ Input: any message, with any kind of body.
+
+ Output: the message is unchanged.
+
+ Good to know: by default the log line shows the body and its Java type,
but not the headers. The body is logged as it is, secrets included, unless
`logMask` is true.
type: object
properties:
loggerName:
title: Logger Name
- description: Name of the logging category to use
+ description: "The name of the logger, shown on each log line. Use it
to tell these log lines apart from others, or to set their level in the logging
configuration."
type: string
default: "log-sink"
+ example: "orders"
level:
title: Log Level
- description: Logging level to use
+ description: "The level to log at. Lines at a level below the one the
logging is set to, such as `DEBUG` when the logging shows `INFO`, are not
shown. `OFF` logs nothing."
type: string
default: "INFO"
enum: ["TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF"]
logMask:
title: Log Mask
- description: Mask sensitive information like password or passphrase in
the log
+ description: "If true, values that look like secrets, such as what
follows `password=` or a header named `token`, are replaced by `xxxxx` in the
log."
type: boolean
- default: false
+ default: false
marker:
title: Marker
- description: An optional Marker name to use
+ description: "A logging marker to add to each log line, for logging
setups that filter or send log lines by marker. When it is not set, no marker
is added."
type: string
+ example: "AUDIT"
multiline:
title: Multiline
- description: If enabled then each information is outputted on a newline
+ description: "If true, each part of the log line, such as the headers,
the body type and the body, is written on a line of its own, which is easier to
read for large messages."
type: boolean
- default: false
+ default: false
showAllProperties:
title: Show All Properties
- description: Show all of the exchange properties (both internal and
custom)
+ description: "If true, also logs all the properties Camel keeps with
the message, including its internal ones. Mostly useful to Camel developers."
type: boolean
- default: false
+ default: false
showBody:
title: Show Body
- description: Show the message body
+ description: "If true, the body is logged. Set it to false for large
bodies, or bodies that must not appear in the log."
type: boolean
- default: true
+ default: true
showBodyType:
title: Show Body Type
- description: Show the body Java type
+ description: "If true, the Java type of the body is logged, such as
`String`, `byte[]` or `java.util.LinkedHashMap`, which shows what kind of body
the next step receives."
type: boolean
- default: true
+ default: true
showExchangePattern:
title: Show Exchange Pattern
- description: Shows the Message Exchange Pattern (or MEP for short)
+ description: "If true, the message pattern is logged: `InOnly` for a
one-way message, `InOut` when a reply is expected."
type: boolean
- default: true
+ default: true
showHeaders:
title: Show Headers
- description: Show the headers received
+ description: "If true, the headers of the message are logged too."
type: boolean
- default: false
+ default: false
showProperties:
title: Show Properties
- description: Show the exchange properties (only custom). Use
showAllProperties to show both internal and custom properties.
+ description: "If true, also logs the properties that the steps of the
integration set on the message, but not Camel's internal ones. Use
`showAllProperties` to see those too."
type: boolean
- default: false
+ default: false
showStreams:
title: Show Streams
- description: Show the stream bodies (they may not be available in
following steps)
+ description: "If true, a body that is a stream not cached by Camel is
logged too. Logging reads such a stream, so the next step may then get an empty
body."
type: boolean
- default: false
+ default: false
showCachedStreams:
title: Show Cached Streams
- description: Whether Camel should show cached stream bodies or not.
+ description: "If true, a body that is a stream cached by Camel, which
can be read again, is logged. Camel caches stream bodies by default, so this is
the usual case."
type: boolean
- default: true
+ default: true
dependencies:
- "camel:kamelet"
- "camel:log"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/simple-filter-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/simple-filter-action.kamelet.yaml
index 63b78fe87..eedb3e873 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/simple-filter-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/simple-filter-action.kamelet.yaml
@@ -31,15 +31,25 @@ metadata:
spec:
definition:
title: "Simple Filter Action"
- description: "Filter based on simple expression."
+ description: |-
+ Drops the messages for which a condition, written in the Camel Simple
language, is true, and passes on all others.
+
+ Use it to leave out the messages you do not want, for example the test
events, with the condition `${header.type} == 'test'`. To keep only the
messages that match a condition instead, use `predicate-filter-action` (a
condition on a JSON body), `has-header-filter-action` or
`header-matches-filter-action`.
+
+ Input: any message.
+
+ Output: the same message, unchanged, when the condition is false. When
it is true, the message is dropped and nothing is sent on.
+
+ Good to know: this is the opposite of the other filter actions of the
catalog, which keep the messages that match. A condition on a header the
message does not have is false, so such a message is passed on.
required:
- expression
+ type: object
properties:
expression:
- title: Simple Expression
- description: A simple expression to apply on the exchange to filter
out some exchange
+ title: Condition
+ description: "The condition, in the Camel Simple language, that makes
a message be dropped. `$\\{body}` is the body and `${header.name}` the value of
a header. For example, `${header.type} == 'test'` drops the messages whose
`type` header is `test`, and `${header.amount} > 100` those whose `amount`
header is more than 100."
type: string
- type: object
+ example: "${header.type} == 'test'"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/throttle-action.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/throttle-action.kamelet.yaml
index 317295685..aeece49e7 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/throttle-action.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/throttle-action.kamelet.yaml
@@ -31,21 +31,29 @@ metadata:
spec:
definition:
title: "Throttle Action"
- description: "The Throttle action allows you to ensure that a specific
sink does not get overloaded."
+ description: |-
+ Lets through at most a set number of messages per period of time, such
as 10 per second, and holds back the rest for a later period.
+
+ Use it to protect a sink or a service that cannot take more than a
certain rate, for example an API that allows 100 calls per minute. To hold
every message for a fixed time instead, use `delay-action`.
+
+ Input: any message.
+
+ Output: the same message, unchanged. The messages over the limit are not
dropped: they wait, and are passed on in a later period.
required:
- messages
+ type: object
properties:
messages:
- title: Messages Number
- description: The number of messages to send in the time period set
+ title: Message Limit
+ description: "How many messages may pass in each `timePeriod`. For
example, 10 with a `timePeriod` of 1000 lets 10 messages through per second."
type: integer
example: 10
timePeriod:
title: Time Period
- description: Sets the time period during which the maximum request
count is valid for, in milliseconds
+ description: "The length of the period that `messages` counts in, in
milliseconds. For example, 60000 is one minute."
type: string
default: "1000"
- type: object
+ example: "60000"
dependencies:
- "camel:kamelet"
template:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/wttrin-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/wttrin-source.kamelet.yaml
index 8621e046f..844e7c75f 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/wttrin-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/wttrin-source.kamelet.yaml
@@ -30,29 +30,37 @@ metadata:
spec:
definition:
title: "wttr.in Source"
- description: Get weather forecasts from the wttr.in weather forecast
service
+ description: |-
+ Fetches the current weather or the forecast for a place from the public
wttr.in service at a regular interval, and sends it as JSON.
+
+ Use it to feed weather data into a dashboard, a chat message or a
decision, such as a frost alert, or as real, changing JSON data for a demo. No
account is needed.
+
+ Output: the body is JSON text. With `output` set to `current`, the
default, it is an object with the current conditions, such as `temp_C`,
`humidity` and `weatherDesc`. With `weather`, it is a list with the forecast
for each day, starting today. With `full`, it is the whole answer of wttr.in,
which has both. The `Content-Type` header is `application/json`, and the other
headers of the HTTP answer are kept.
+
+ Good to know: it calls `https://wttr.in` over the internet. When
`wttrLocation` is not set, wttr.in guesses the place from the IP address of the
machine.
type: object
properties:
period:
title: Period
- description: The interval between fetches to the wttr.in service in
milliseconds
+ description: "How long to wait between two fetches, in milliseconds.
For example, 3600000 is one hour."
type: integer
default: 60000
+ example: 3600000
wttrLocation:
title: Location
- description: The location to get weather forecasts
+ description: "The place to get the weather for: a city name such as
`Paris` or `New York`, an airport code such as `muc`, a landmark after `~` such
as `~Eiffel+tower`, a postal code, or a latitude and longitude such as
`48.85,2.35`. When it is not set, wttr.in guesses the place from the IP address
of the machine."
type: string
- example: '"paris", "~Eiffel+tower", "Москва", "muc",
"@stackoverflow.com", "94107", "-78.46,106.79"'
+ example: "Paris"
wttrLanguage:
title: Language
- description: The language to use for displaying weather forecasts
+ description: "The language of the weather descriptions, as a language
code such as `fr` or `de`. The descriptions in that language are added to the
JSON in a field such as `lang_fr`; the other fields stay in English. When it is
not set, the descriptions are in English only."
type: string
- example: 'am ar af be bn ca da de el et fr fa hi hu ia id it lt mg nb
nl oc pl pt-br ro ru ta tr th uk vi zh-cn zh-tw'
+ example: "fr"
output:
- title: Output Type
- description: The type of output
+ title: Output
+ description: "What to send: `current` for the current conditions,
`weather` for the forecast of each day, or `full` for the whole answer of
wttr.in. Any other value works like `full`."
type: string
- example: 'current, weather, full'
+ example: "weather"
default: current
types:
out: