Skip to content

add temporal worker deployment create-version#971

Open
jaypipes wants to merge 1 commit intotemporalio:serverlessfrom
jaypipes:jaypipes/serverless
Open

add temporal worker deployment create-version#971
jaypipes wants to merge 1 commit intotemporalio:serverlessfrom
jaypipes:jaypipes/serverless

Conversation

@jaypipes
Copy link
Copy Markdown

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

TODO: add unit tests.

@jaypipes jaypipes requested review from a team as code owners March 31, 2026 15:57
@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
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 from 765f4f8 to 935a0d6 Compare April 1, 2026 14:37
Adds implementation of the `temporal worker deployment create-version`
CLI command using only direct gRPC API calls, not the sdk-go client
code.

TODO: add unit tests.

Signed-off-by: Jay Pipes <jay.pipes@temporal.io>
@jaypipes jaypipes force-pushed the jaypipes/serverless branch 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.

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?

@chaptersix
Copy link
Copy Markdown
Contributor

CI failures seem relevant to this change.

Comment on lines +1095 to +1100
Scaler: &computeScaler{
// NOTE(jaypipes): Hard-coding the no-sync scaling
// algorithm since as of April 1, 2026, this is the only
// supported one in temporal-auto-scaled-workers.
Type: "no-sync",
},
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

you don't even need to set the scaler config - there is a default config deduced from the provider to avoid this.

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.

4 participants