Skip to content

Conversation

@cretz
Copy link
Member

@cretz cretz commented Dec 17, 2025

What was changed

Added Temporalio::Client::Plugin, Temporalio::Worker::Plugin, and Temporalio::SimplePlugin and everything required to make those work.

Checklist

  1. Closes [Feature Request] Plugin support #318

@cretz cretz marked this pull request as ready for review December 17, 2025 21:06
@cretz cretz requested a review from a team as a code owner December 17, 2025 21:06
Copy link
Member

@chris-olszewski chris-olszewski left a comment

Choose a reason for hiding this comment

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

Everything makes sense to me. Appreciate the in depth comments.

# @param lazy_connect [Boolean] If true, there is no connection until the first call is attempted or a worker
# is created with it. Clients from lazy connections cannot be used for workers if they have not performed a
# connection.
# @param around_connect [Proc, nil] If present, this proc accepts two values: options and a block. The block is a
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# @param around_connect [Proc, nil] If present, this proc accepts two values: options and a block. The block is a
# @param around_connect [Proc, nil] If present, this proc accepts two values: options and a block. The block

)

# Create a client and worker with the plugin, run workflow, confirm success
client = Temporalio::Client.connect(env.client.connection.target_host, env.client.namespace, plugins: [plugin])
Copy link
Member

Choose a reason for hiding this comment

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

Not too concerned since the code is pretty straightforward, but adding some test coverage for composing plugins would be nice.

Copy link
Member Author

@cretz cretz Dec 18, 2025

Choose a reason for hiding this comment

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

I may do this, though really, plugins technically shouldn't need/want to know about each other, they should just each work. So effectively it's a test to confirm two plugins work instead of just one, so I may add a second here.

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.

[Feature Request] Plugin support

2 participants