Conversation
|
@yuandrew is attempting to deploy a commit to the Temporal Team on Vercel. A member of the Team first needs to authorize it. |
|
Reviewing, editing, and merging this today. |
|
Go SDK v1.40.0 was just released today, so the SDK should now support all of these code snippets for users to use themselves https://github.com/temporalio/sdk-go/releases/tag/v1.40.0. So good to merge whenever, from my side! Thanks @jsundai |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
@prasek Could you take a quick look at this when you get a chance? Thanks! |
…tion into standalone-activities
|
@jsundai Phil is pretty backed up with other tasks. We should be good to merge here, we can always update the docs when Phil gets a chance to review later on |
|
This looks good to me. Since it's experimental, we'll create another follow up PR to change it to pre-release next week. |
|
|
||
| :::info PREREQUISITES | ||
|
|
||
| Standalone Activities require server-side support. If you are running a self-hosted Temporal Server, the following |
There was a problem hiding this comment.
Remove this section. This feature will only work on a special CLI release and in Temporal Cloud. In server 1.31.0 (the next OSS server release) all of this will be enabled by default.
| You can pass the Activity as either a function reference or a string Activity type name: | ||
|
|
||
| ```go | ||
| // Using a function reference (recommended — enables compile-time parameter validation) |
There was a problem hiding this comment.
That's false. It's runtime parameter validation (assuming that was implemented).
prasek
left a comment
There was a problem hiding this comment.
overall looks good, added some suggestions
|
|
||
| ::: | ||
|
|
||
| :::info PREREQUISITES |
There was a problem hiding this comment.
We should have them run with dev server, similar to https://docs.temporal.io/develop/typescript/nexus#run-the-temporal-nexus-development-server
@dandavison @bergundy will there be a temporal server start-dev flag to enable Standalone Activities?
There was a problem hiding this comment.
No, there will not be a flag. The special release of the dev server will enable it by default.
|
|
||
| :::info PREREQUISITES | ||
|
|
||
| Standalone Activities require server-side support. If you are running a self-hosted Temporal Server, the following |
There was a problem hiding this comment.
These self-hosted options should be moved to the self-hosted guide, similar to https://docs.temporal.io/production-deployment/self-hosted-guide/nexus
Also we should stick with dev server (and Cloud) for these SDK dev guides.
There was a problem hiding this comment.
This isn't available and not relevant to document.
| ::: | ||
|
|
||
|
|
||
| ## Execute a Standalone Activity {#execute-activity} |
There was a problem hiding this comment.
ideally this quick start should allow users to cut/paste commands and have it working on their local machine with the least amount of work possible
so before this would add:
- note saying everything is based on an SDK sample (with link), so they can clone it
- commands (they can cut/paste) to clone, get dev server initialized, and the sample activity worker running, so it's ready to for a client to execute a Standalone Activity
- then after this code walkthrough, would provide a command (they can cut/paste) to execute the standalone activity
There was a problem hiding this comment.
see comments above (and below) re: specific quick start commands
|
What about list and count for standalone activities? |
…tion into standalone-activities
|
@jsundai we decided this should wait until a special server release that will fully support standalone activities for this to go live, converting to a draft for now. Will re-publish when we're ready to merge this |
prasek
left a comment
There was a problem hiding this comment.
overall lgtm, but we need a cloud example and think we should add CLI commands for a better quickstart experience
| - [Get the result of a Standalone Activity](#get-activity-result) | ||
| - [Get a handle to an existing Standalone Activity](#get-activity-handle) | ||
| - [List Standalone Activities](#list-activities) | ||
| - [Count Standalone Activities](#count-activities) |
There was a problem hiding this comment.
We also need a cloud example here "Run Standalone Activities with Temporal Cloud" similar to https://docs.temporal.io/develop/go/nexus#nexus-calls-across-namespaces-temporal-cloud
| The Temporal Web UI should now be accessible at [http://localhost:8233](http://localhost:8233), and the Temporal Server | ||
| should now be available for client connections on `localhost:7233`. | ||
|
|
||
| ## Run a worker with the activity registered {#run-worker} |
There was a problem hiding this comment.
would add a CLI quick start so they can get up and running faster
git clone https://github.com/temporalio/samples-go.git
cd samples-go
go run standalone-activity/helloworld/worker/main.go
| ::: | ||
|
|
||
|
|
||
| ## Execute a Standalone Activity {#execute-activity} |
There was a problem hiding this comment.
see comments above (and below) re: specific quick start commands
| ``` | ||
|
|
||
| ## Execute a Standalone Activity {#execute-activity} | ||
|
|
There was a problem hiding this comment.
add quick start command so they can get it running on their machine faster
go run standalone-activity/helloworld/starter/main.go
| in the API reference for the full set of options. | ||
|
|
||
| ## Get the result of a Standalone Activity {#get-activity-result} | ||
|
|
There was a problem hiding this comment.
add a CLI quick start command so they can see the result faster
temporal activity result --activity-id MyActivityId
| ``` | ||
|
|
||
| ## List Standalone Activities {#list-activities} | ||
|
|
There was a problem hiding this comment.
add a CLI quick start command so they can see the result faster
temporal activity list
remove TypeScript SDK -> Go support note for Standalone Activities
| --retention-days 1 | ||
| ``` | ||
|
|
||
| Alternatively, you can create a Namespace through the UI: [https://cloud.temporal.io/Namespaces](https://cloud.temporal.io/Namespaces). |
There was a problem hiding this comment.
nit: the N in Namespaces should be lowercase
|
Closing this in favor of 4243 |
Superseded by #4243