This is an automated email from the ASF dual-hosted git repository. marat pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel-karavan.git
The following commit(s) were added to refs/heads/main by this push: new 5e9f297 Update README.md 5e9f297 is described below commit 5e9f29779eee7537503f9c4d0c7c4aa584399e3e Author: Marat Gubaidullin <marat.gubaidul...@gmail.com> AuthorDate: Sun Mar 13 19:25:35 2022 -0400 Update README.md --- karavan-demo/postman/README.md | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/karavan-demo/postman/README.md b/karavan-demo/postman/README.md index a93c745..04ae89f 100644 --- a/karavan-demo/postman/README.md +++ b/karavan-demo/postman/README.md @@ -1,8 +1,35 @@ +# Demo: Parcels Delivery Service + + +## Prerequisites + +1. [VSCode](https://code.visualstudio.com/download) installed +2. Apache Camel [Karavan](https://marketplace.visualstudio.com/items?itemName=camel-karavan.karavan) extension installed +3. [Jbang](https://www.jbang.dev/download/) installed +4. Docker and Docker compose installed + +## How-to + +### Start environment +``` +docker-compose up +``` + +### Start integration +``` +jbang -Dcamel.jbang.version=3.16.0-SNAPSHOT camel@apache/camel run postman.yaml +``` + +### Publish parcel ``` -curl -X POST -H "Content-Type: application/json" --data '{"id":1,"address":"666 Sin Street, Holy City"}' http://0.0.0.0:8080/parcels +curl -X POST -H "Content-Type: application/json" --data '{"id":"1","address":"666 Sin Street, Holy City"}' http://0.0.0.0:8080/parcels ``` +### Publish payment +Open AMQ7 Broker Management [Console](http://localhost:8161) + +Send message to `payments` queue ``` <?xml version="1.0" encoding="UTF-8" ?> <root> @@ -10,4 +37,4 @@ curl -X POST -H "Content-Type: application/json" --data '{"id":1,"address":"666 <amount>777</amount> <status>confirmed</status> </root> -``` \ No newline at end of file +```