Skip to content

temporal worker deployment create|create-version#971

Open
jaypipes wants to merge 9 commits intotemporalio:serverlessfrom
jaypipes:jaypipes/serverless
Open

temporal worker deployment create|create-version#971
jaypipes wants to merge 9 commits intotemporalio:serverlessfrom
jaypipes:jaypipes/serverless

Conversation

@jaypipes
Copy link
Copy Markdown

@jaypipes jaypipes commented Mar 31, 2026

Adds implementation of the temporal worker deployment create and
temporal worker deployment create-version CLI commands using only
direct gRPC API calls, not the sdk-go client code.

Adds some basic unit tests for both commands though due to the
server-side validation of proper AWS IAM credentials, the happy-path
temporal worker deployment create-version call with AWS Lambda compute
config is skipped until such time as we can figure out adding real AWS
test fixtures.

chaptersix and others added 5 commits March 12, 2026 15:54
Fixes temporalio#567

## What was changed
- When executing short-lived transactional commands (e.g. `start`,
`list` etc, as opposed to the long-running `server start-dev` process)
report errors/warnings as unstructured plain text instead of structured
logging-formatted messages.
- The logger is now used only by the server and SDK

## Why?
CLIs should report errors/warnings by printing to stderr. They should
not use structured logging messages for this.

## How was this tested
- New in-codebase tests
- Manually.
## Summary
- Replace `@temporalio/sdk @temporalio/server` with `@temporalio/act` as
code owners
…#966)

## What was changed
Add experimental warning around pause/update-options/unpause/reset
activity by type or use of --query flag with activity operations.

## Why?
These have been experimental commands and should have been marked
experimental from the beginning.

## Checklist
1. Closes NA

2. How was this tested: manually built and verified

3. Any docs updates needed?
…#970)

## Summary
- Bump `go.temporal.io/server` from v1.31.0-151.6 to v1.31.0-152.2 to
resolve CVEs
- Bump Go from 1.26.0 to 1.26.1, fixing 5 stdlib vulnerabilities
(GO-2026-4599 through GO-2026-4603)

## Test plan
- [ ] CI passes
@jaypipes jaypipes requested review from a team as code owners March 31, 2026 15:57
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Mar 31, 2026

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
4 out of 5 committers have signed the CLA.

✅ dandavison
✅ chaptersix
✅ tlalfano
✅ spkane31
❌ jaypipes
You have signed the CLA already but the status is still pending? Let us recheck it.

@jaypipes jaypipes force-pushed the jaypipes/serverless branch from 4dded90 to 765f4f8 Compare March 31, 2026 16:19
@jaypipes jaypipes force-pushed the jaypipes/serverless branch 2 times, most recently from 935a0d6 to aa347d3 Compare April 1, 2026 14:51
@chaptersix
Copy link
Copy Markdown
Contributor

chaptersix commented Apr 1, 2026

TODO: add unit tests.

Generally it'd be great to have tests coverage that matches existing coverage for worker deployments. IIRC there's some tests that hit the dev server.

case "nexus":
return enumspb.TASK_QUEUE_TYPE_NEXUS
default:
return enumspb.TASK_QUEUE_TYPE_UNSPECIFIED
Copy link
Copy Markdown
Contributor

@chaptersix chaptersix Apr 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

o.WorkflowIDConflictPolicy, err = stringToProtoEnum[enums.WorkflowIdConflictPolicy](

any reason that this shouldn't error if there isn't a match? case "" seems more appropriate for unspecified

you could use this generic. not blocking though

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice. didn't know about that :) will update shortly!

return "activity"
case enumspb.TASK_QUEUE_TYPE_NEXUS:
return "nexus"
default:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as above

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would be great if this could be a generic as well.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed this and using the existing taskQueueTypeToStr() defined above.

go.mod Outdated
Comment on lines +20 to +21
go.temporal.io/api v1.62.3-0.20260327234204-dbc016f3811d
go.temporal.io/sdk v1.41.1-0.20260310224809-feecdd6377fc
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you probably already know this but we need tagged dependencies for this to merge to main.

BUT you can use cloud tags from temporalio/temporal for the dev server. We just have to change it to a oss tag before we release from main

// ScalingGroups contains the set of ComputeConfigScalingGroup objects
// associated with the ComputeConfig. The key for the map is the ID of the
// scaling group.
ScalingGroups map[string]*computeConfigScalingGroup
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why map[string]*computeConfigScalingGroup and not map[string]computeConfigScalingGroup?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

habit mostly.

@chaptersix
Copy link
Copy Markdown
Contributor

CI failures seem relevant to this change.

…io#972)

## Summary

- Removes `experimental: true` from `--config-file`, `--profile`,
`--disable-config-file`, and `--disable-config-env` global flags in
`cliext/option-sets.yaml`
- Regenerates `cliext/flags.gen.go` to remove the `EXPERIMENTAL.` suffix
from the help strings for those flags

## Test plan

- [ ] Run `temporal --help` and verify the four flags no longer show
`EXPERIMENTAL.` in their descriptions
- [ ] Run `make build` to confirm clean build

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
spkane31 and others added 2 commits April 6, 2026 16:16
…lio#974)

## What was changed

- activity pause silently ignored the `--identity` flag, always sending
the global client identity instead of the per-command one
- activity pause had no `--reason` flag despite the server-side
`PauseActivityRequest` accepting one
- `--activity-type` showed `activity-id` as its value placeholder in
pause, unpause, and reset help output
- `--reset-heartbeats` on unpause and reset incorrectly claimed it only
works with `--reset-attempts`
- activity complete and activity fail lacked the `-a` shorthand for
`--activity-id` that the other activity subcommands already had

## Why?
These were found during an internal bug bash as either bugs or
inconsistencies.

## Checklist
1. Closes NA
2. How was this tested: Manually
3. Any docs updates needed? No
…ralio#975)

## Summary

- Upgrades `go.temporal.io/sdk` from v1.38.0 to v1.41.0 in both root and
`cliext` modules
- Upgrades `go.temporal.io/sdk/contrib/envconfig` from v0.1.0 to v1.0.0
in both modules

## Why

envconfig v0.1.0 had a bug where `ToClientOptions` did not set
`ConnectionOptions.TLSDisabled = true` when a profile had TLS disabled.
This meant that passing `--api-key X --tls=false` would still dial with
TLS enabled (because the SDK auto-enables TLS when credentials are
present), overriding the user's explicit `--tls=false` flag.

Fixed upstream in temporalio/sdk-go#2205, released in envconfig v1.0.0.
@jaypipes jaypipes force-pushed the jaypipes/serverless branch 2 times, most recently from 6e071ed to 058ec54 Compare April 8, 2026 22:48
option-sets:
- deployment-version
options:
- name: aws-lambda-invoke
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The name --aws-lambda-invoke doesn't feel right to me. How do I read it -- is it "This is the AWS Lambda that will be invoked"? If so I feel like in a CLI that would be --aws-lambda or --aws-lambda-arn. Unless "invoke" is needed to distinguish it from other Lambda ARNs that will be used for purposes other than invoking.

(Could be worth comparing with other popular CLIs that specify Lambda ARNs)

Comment on lines +991 to +993
Qualified (contains version suffix) or Unqualified AWS Lambda
Function ARN to invoke when there are no active pollers for task
queue targets in the Worker Deployment.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is Function conventionally capitalized in "Lambda Function"?

Suggested change
Qualified (contains version suffix) or Unqualified AWS Lambda
Function ARN to invoke when there are no active pollers for task
queue targets in the Worker Deployment.
Qualified (contains version suffix) or unqualified AWS Lambda
function ARN to invoke when there are no active pollers for task
queue targets in the Worker Deployment.

dc := converter.GetDefaultDataConverter()
requestID := uuid.NewString()

var cc *computeConfig
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR adds an additional set of data modeling structs and associated validation and conversion functions. Would you mind convincing me that it's really necessary? I think it would be more idiomatic in this codebase to work directly with the generated proto structs; it looks like ~320 lines would be removed from this PR by doing that. AI commit doing that: 8248868

@jaypipes jaypipes force-pushed the jaypipes/serverless branch from 058ec54 to ab657bb Compare April 9, 2026 13:05
Adds implementation of the `temporal worker deployment create` and
`temporal worker deployment create-version` CLI commands using only
direct gRPC API calls, not the sdk-go client code.

Adds some basic unit tests for both commands though due to the
server-side validation of proper AWS IAM credentials, the happy-path
`temporal worker deployment create-version` call with AWS Lambda compute
config is skipped until such time as we can figure out adding real AWS
test fixtures.

Signed-off-by: Jay Pipes <jay.pipes@temporal.io>
@jaypipes jaypipes force-pushed the jaypipes/serverless branch from ab657bb to bd0ea09 Compare April 9, 2026 22:22
@jaypipes jaypipes changed the title add temporal worker deployment create-version temporal worker deployment create|create-version Apr 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants