Skip to content
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

Support disabling proto load via environment variable #335

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cretz
Copy link

@cretz cretz commented Feb 4, 2025

When working through an interop sample that has both https://github.com/coinbase/temporal-ruby and https://github.com/temporalio/sdk-ruby in the same process, it clashed due to how Google protobuf library does not allow the same qualified proto generated in different places.

After testing, I am happy to report the projects can coexist so long as the Temporal Ruby SDK's generated protos are loaded instead. So this PR checks for an env var and if that env var is set, the require is not called for loading protos. With this change, I have confirmed that the Coinbase Ruby SDK client can use Temporal Ruby SDK workflows, and vice versa, and that Coinbase Ruby SDK workflows can use Temporal Ruby SDK activities, and vice versa. I should have a sample showing this soon.

Note, for the sed changes to Makefile, the protos have not been regenerated for a couple of years, and if the latest protoc from grpc-tools is used it makes several changes which I didn't want to do. So I manually/temporarily run bundle add grpc-tools --version 1.53.2 (the version at the time of last proto gen in this repo) before make proto to ensure these changes add no unnecessary side effects.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant