Christoph Deppisch created CAMEL-22702:
------------------------------------------
Summary: Add structured output option for Camel JBang cmd receive
Key: CAMEL-22702
URL: https://issues.apache.org/jira/browse/CAMEL-22702
Project: Camel
Issue Type: Improvement
Components: camel-jbang
Reporter: Christoph Deppisch
It would be good to produce structured output for the Camel JBang cmd receive
command. I am thinking of something like
{code:java}
camel cmd receive my-route --endpoint kafka:inbox --output json{code}
The output is a Json array of already received messages on this endpoint
(according to the --tail option)
The receive command is waiting for new messages to arrive and each message will
be printed in a structured Json output like this:
{noformat}
[
{ "message": 1, "endpoint": "kafka://info", "body": "Hello Camel"},
{ "message": 2, "endpoint": "kafka://info", "body": "Hi Camel"}
]
Waiting for new messages ...
{
"message": 3,
"endpoint": "kafka://info",
"body": "Howdy Camel"
}{noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)