Skip to content

Commit e38b6d8

Browse files
committed
Fixes to the examples
- Use long form CLI commands in readme - Upgrade Restate dev dependencies to compatible version - Add missing @types/node dependency
1 parent 082f687 commit e38b6d8

File tree

9 files changed

+23
-16
lines changed

9 files changed

+23
-16
lines changed

patterns-use-cases/async-signals-payment/async-signals-payment-typescript/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ webhooks to your local machine.
3131

3232
4. Run this application code here: `npm run app-dev`
3333

34-
5. Connect the apps: `npx restate dep reg localhost:9080`
34+
5. Connect the apps: `npx restate deployment register localhost:9080`
3535

3636
6. Run launch _ngrok_: Get a free account and download the binary, or launch a docker container.
3737
Make it forward http calls to local port 8080

patterns-use-cases/async-signals-payment/async-signals-payment-typescript/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@
1313
"stripe": "^14.15.0"
1414
},
1515
"devDependencies": {
16-
"@restatedev/restate": "0.8.0",
17-
"@restatedev/restate-server": "0.8.0",
16+
"@restatedev/restate": "^0.9.2",
17+
"@restatedev/restate-server": "^0.9.2",
18+
"@types/node": "^20.12.12",
1819
"ts-node-dev": "^1.1.1",
1920
"typescript": "^5.0.2"
2021
}

patterns-use-cases/durable-promises/durable-promises-typescript/package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,12 @@
1515
},
1616
"dependencies": {
1717
"@restatedev/restate-sdk": "^0.9.2",
18-
"@restatedev/restate-sdk-clients": "dev"
18+
"@restatedev/restate-sdk-clients": "^0.9.2"
1919
},
2020
"devDependencies": {
21-
"@restatedev/restate": "0.8.0",
22-
"@restatedev/restate-server": "0.8.0",
21+
"@restatedev/restate": "^0.9.2",
22+
"@restatedev/restate-server": "^0.9.2",
23+
"@types/node": "^20.12.7",
2324
"ts-node": "^10.9.2",
2425
"typescript": "^5.0.2"
2526
}

patterns-use-cases/payment-state-machine/payment-state-machine-typescript/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,17 @@ and failures.
2323

2424
## Running this example
2525

26-
Start a Restate Server: `npx restate-server`
26+
First, install all dependencies via `npm install`.
2727

28-
Build and start the example
28+
Next, start a Restate Server: `npx restate-server`
29+
30+
Now build and start the example (in a new terminal):
2931
```shell
30-
npm install
3132
npm run build
3233
npm run app
3334
```
3435

35-
Register the services: `npx restate dep reg "localhost:9080"`
36+
Register the services: `npx restate deployment register "localhost:9080"`
3637

3738
Make some requests:
3839

patterns-use-cases/payment-state-machine/payment-state-machine-typescript/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@
1616
"@restatedev/restate-sdk": "^0.9.2"
1717
},
1818
"devDependencies": {
19-
"@restatedev/restate": "0.8.0",
20-
"@restatedev/restate-server": "0.8.0",
19+
"@restatedev/restate": "^0.9.2",
20+
"@restatedev/restate-server": "^0.9.2",
21+
"@types/node": "^20.12.7",
2122
"ts-node-dev": "^2.0.0",
2223
"typescript": "^5.1.6"
2324
}

patterns-use-cases/sagas/sagas-typescript/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"@restatedev/restate-sdk": "^0.9.2"
1111
},
1212
"devDependencies": {
13+
"@types/node": "^20.12.7",
1314
"typescript": "^5.0.2"
1415
}
1516
}

patterns-use-cases/state-machines/state-machines-typescript/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ avoiding accidental state corruption and concurrency issues.
2525
* Start Restate Server in a separate shell: `npx restate-server`
2626
* Start this example: `npm run example`. (Use `npm run example-crash` to use the
2727
variant that crashes the process and restarts, to see the state recovery happen).
28-
* Register the example at Restate server by calling `npx restate -y dep reg --force "localhost:9080"`.
28+
* Register the example at Restate server by calling `npx restate -y deployment register --force "localhost:9080"`.
2929

3030
Invoke the state machine transitions like
3131
```shell

patterns-use-cases/state-machines/state-machines-typescript/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,9 @@
1515
"@restatedev/restate-sdk": "^0.9.2"
1616
},
1717
"devDependencies": {
18-
"@restatedev/restate": "^0.8.0",
19-
"@restatedev/restate-server": "^0.8.0",
18+
"@restatedev/restate": "^0.9.2",
19+
"@restatedev/restate-server": "^0.9.2",
20+
"@types/node": "^20.12.7",
2021
"ts-node": "^10.9.2",
2122
"ts-node-dev": "^2.0.0",
2223
"typescript": "^5.0.2"

patterns-use-cases/ticket-reservation/ticket-reservation-typescript/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@
1919
"@restatedev/restate-sdk": "^0.9.2"
2020
},
2121
"devDependencies": {
22-
"@restatedev/restate": "0.8.0",
22+
"@restatedev/restate": "^0.9.2",
2323
"@typescript-eslint/eslint-plugin": "^6.3.0",
2424
"@typescript-eslint/parser": "^6.3.0",
25+
"@types/node": "^20.12.7",
2526
"eslint": "^8.46.0",
2627
"prettier": "^2.8.8",
2728
"ts-node-dev": "^2.0.0"

0 commit comments

Comments
 (0)