Skip to content

Commit

Permalink
minor amends
Browse files Browse the repository at this point in the history
  • Loading branch information
davegarvey committed Oct 4, 2024
1 parent 15f9e44 commit 477fe2e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
"processors": [
{
"json_schema": {
"schema": "{\n \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"type\": \"string\",\n \"minLength\": 5\n },\n \"age\": {\n \"type\": \"integer\",\n \"minimum\": 19\n }\n },\n \"required\": [\"name\", \"age\"],\n \"additionalProperties\": false\n\n}\n"
"schema": "{\n \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"type\": \"string\"\n },\n \"age\": {\n \"type\": \"integer\",\n \"minimum\": 0\n }\n },\n \"required\": [\"name\", \"age\"]\n}\n"
}
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ echo "Part 2: Publishing a valid message"
echo "This script publishes a valid message to the clients connected in script 1."
echo "Check the first terminal to see the messages received."

curl http://tyk-gateway.localhost:8080/streams-simple-pubsub/validated-pub -d '{ "name": "Tyk Streams", "age": 21 }'
curl http://tyk-gateway.localhost:8080/streams-simple-pubsub/validated-pub -d '{ "name": "Tyk Streams", "age": 1 }'
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ echo "Part 3: Publishing an invalid message"
echo "This script publishes an invalid message, which the gateway prevents subscribers from receiving."
echo "Check the first terminal to see that the message is not received, and the fourth terminal to see the logged error."

curl http://tyk-gateway.localhost:8080/streams-simple-pubsub/validated-pub -d '{ "name": "Tyk", "age": 3 }'
curl http://tyk-gateway.localhost:8080/streams-simple-pubsub/validated-pub -d '{ "name": "Tyk Streams", "age": -1 }'

0 comments on commit 477fe2e

Please sign in to comment.