From 6968d9f0360d148618e33053a0d58fe1ae766f58 Mon Sep 17 00:00:00 2001 From: slinkydeveloper Date: Mon, 18 Dec 2023 10:49:22 +0100 Subject: [PATCH] Service endpoint -> Deployment --- README.md | 4 ++-- typescript/ecommerce-store/deployment/aws/README.md | 2 +- typescript/ecommerce-store/deployment/aws/variables.tf | 2 +- .../ecommerce-store/deployment/docker/docker-compose-pg.yml | 2 +- .../ecommerce-store/deployment/docker/docker-compose.yml | 2 +- typescript/food-ordering/docker-compose.yml | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 6e1068e2..d07130e5 100644 --- a/README.md +++ b/README.md @@ -118,11 +118,11 @@ Once the runtime is up, let it discover the services of the example by executing - For MacOS: ```shell -curl -X POST http://localhost:9070/endpoints -H 'content-type: application/json' -d '{"uri": "http://host.docker.internal:9080"}' +curl -X POST http://localhost:9070/deployments -H 'content-type: application/json' -d '{"uri": "http://host.docker.internal:9080"}' ``` - For Linux: ```shell -curl -X POST http://localhost:9070/endpoints -H 'content-type: application/json' -d '{"uri": "http://localhost:9080"}' +curl -X POST http://localhost:9070/deployments -H 'content-type: application/json' -d '{"uri": "http://localhost:9080"}' ``` This should give you the following output in case of the ticket reservation example: diff --git a/typescript/ecommerce-store/deployment/aws/README.md b/typescript/ecommerce-store/deployment/aws/README.md index 34207b92..6c439c80 100644 --- a/typescript/ecommerce-store/deployment/aws/README.md +++ b/typescript/ecommerce-store/deployment/aws/README.md @@ -74,7 +74,7 @@ ssh -i shopping-demo-key.pem -L 5050:pgadmin.shopping-cart-demo:5050 -L 16686:ja Then discover the services from within the ssh session: ```shell -curl -X POST http://restate-runtime.shopping-cart-demo:9070/endpoints -H 'content-type: application/json' -d '{"uri": "http://shopping-services.shopping-cart-demo:8080"}' +curl -X POST http://restate-runtime.shopping-cart-demo:9070/deployments -H 'content-type: application/json' -d '{"uri": "http://shopping-services.shopping-cart-demo:8080"}' ``` This prints out the services were discovered by the Restate runtime. diff --git a/typescript/ecommerce-store/deployment/aws/variables.tf b/typescript/ecommerce-store/deployment/aws/variables.tf index e45bab33..919bab8b 100644 --- a/typescript/ecommerce-store/deployment/aws/variables.tf +++ b/typescript/ecommerce-store/deployment/aws/variables.tf @@ -40,7 +40,7 @@ variable "restate_runtime_ingress_port" { } variable "restate_runtime_discovery_port" { - description = "The port of the restate runtime to register service endpoints" + description = "The port of the restate runtime to register deployments" default = 9070 } diff --git a/typescript/ecommerce-store/deployment/docker/docker-compose-pg.yml b/typescript/ecommerce-store/deployment/docker/docker-compose-pg.yml index 750e3775..df160b2b 100644 --- a/typescript/ecommerce-store/deployment/docker/docker-compose-pg.yml +++ b/typescript/ecommerce-store/deployment/docker/docker-compose-pg.yml @@ -32,7 +32,7 @@ services: - runtime - services restart: "no" - entrypoint: ["sh", "-c", "sleep 5 && curl -X POST 'runtime:9070/endpoints' -H 'content-type: application/json' -d '{\"uri\": \"http://services:8080\"}' || exit 1"] + entrypoint: ["sh", "-c", "sleep 5 && curl -X POST 'runtime:9070/deployments' -H 'content-type: application/json' -d '{\"uri\": \"http://services:8080\"}' || exit 1"] db: image: 'postgres:15.0-alpine' diff --git a/typescript/ecommerce-store/deployment/docker/docker-compose.yml b/typescript/ecommerce-store/deployment/docker/docker-compose.yml index 09012772..de985f3c 100644 --- a/typescript/ecommerce-store/deployment/docker/docker-compose.yml +++ b/typescript/ecommerce-store/deployment/docker/docker-compose.yml @@ -36,7 +36,7 @@ services: - ../local/:/scripts - ../data/:/data entrypoint: ["sh", "-c", "sleep 5 && apk add --no-cache bash jq curl && - curl -X POST 'runtime:9070/endpoints' -H 'content-type: application/json' -d '{\"uri\": \"http://services:8080\"}' && + curl -X POST 'runtime:9070/deployments' -H 'content-type: application/json' -d '{\"uri\": \"http://services:8080\"}' && sleep 3 && cd /scripts && chmod +x init_state.sh && ./init_state.sh runtime:9090 || exit 1"] diff --git a/typescript/food-ordering/docker-compose.yml b/typescript/food-ordering/docker-compose.yml index f80eac9f..2f3d4ba9 100644 --- a/typescript/food-ordering/docker-compose.yml +++ b/typescript/food-ordering/docker-compose.yml @@ -33,7 +33,7 @@ services: - services restart: "no" entrypoint: ["sh", "-c", "sleep 5 && apk add --no-cache bash jq curl && - curl -X POST 'runtime:9070/endpoints' -H 'content-type: application/json' -d '{\"uri\": \"http://services:8080\"}' + curl -X POST 'runtime:9070/deployments' -H 'content-type: application/json' -d '{\"uri\": \"http://services:8080\"}' || exit 1"] grpcui: