-
Notifications
You must be signed in to change notification settings - Fork 127
Special behaviour for temporal prefixes #1644
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
In this change, users are prevented from registering signals/updates/queries with reserved names from the handler. Users can still Alternatively, we can do the blocking in |
8170bc5
to
5f5103a
Compare
this is blocked on #1640 so we can handle the same prefix cases for updates as well |
… test needs to be fixed, need to add behaviour reserving prefixes from workflows, and waiting for default update to be merged to add behaviour preventing default update handler to be called with reserved names
5f5103a
to
8237158
Compare
1a7b249
to
55c641f
Compare
@@ -467,6 +468,7 @@ export class Worker { | |||
* This method initiates a connection to the server and will throw (asynchronously) on connection failure. | |||
*/ | |||
public static async create(options: WorkerOptions): Promise<Worker> { | |||
throwIfReservedName('task queue', options.taskQueue); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At this point, taskQueue
can be undefined. Won't that cause an NPE in throwIfServedName?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added a check but the WorkerOptions interface says that taskQueue can only be string
9eb4558
to
452602f
Compare
452602f
to
73823fa
Compare
What was changed
Special behavior handling reserved temporal prefixes. Prevent users from:
Note: this change does not cover handling reserved temporal prefixes for workflows, as it involves non-trivial changes to the workflow bundling.
Closes [Feature Request] Special behavior for Temporal built-in prefixes #1599
How was this tested:
unit/integration tests
Any docs updates needed?
I'm not sure.