-
Notifications
You must be signed in to change notification settings - Fork 643
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
Add support for durable objects binding #2059
Conversation
changelog detected ✅ |
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.
thanks for starting this PR @afranche! unfortunately, we still have a bit of work to do here to get this over the line.
- we need to add the
durable_object_binding
to the worker script schema binding. right now, there is no way to configure/use the new functionality. - we'll need to fix the tests. right now, they don't pass as i suspect the durable object setup is going to be more involved (looking at https://developers.cloudflare.com/workers/learning/using-durable-objects/)
i have a feeling there may be more API calls involved here too as just testing this out on a dev account i have doesn't have DO working as smoothly as with wrangler.
@jacobbednarz Thanks a lot for the review! 🙇🏼
I'm unsure as to what the worker script schema binding is in this context. My thought process was given that the schema methods for Create, Read and Update all have a call to
I see for the tests. Based on the link you sent I read that if we're using ES Modules, the main module has to be provided to the DO when creating it hence I'm wondering how well is it working if we're providing the DO without providing the main module with it, that might also be an issue! 😄
I'd be happy knowing more details about how it worked if you may, and also what routine should be tested regarding how which cases we can stumble upon. 🙂 |
for the missing schema, check out #2051. it is adding another binding type that should point you in the right direction. as for what setup is involved for actual use and tests, I'm chasing down the internal team for clarification. if I can't get an answer in the next couple of days, I'll have to dissect wrangler and see what it is doing under the hood and hope the entire API is documented (or I'm just missing something completely) |
Marking this pull request as stale due to 14 days of inactivity. This helps our maintainers find and focus on the active pull requests. If this pull request receives no comments in the next 7 days it will automatically be closed. Maintainers can also remove the |
This PR was closed because it has been stalled for 7 days with no activity. |
Hi all, what happened to this PR? I'm looking at deploying a worker with a Durable Object binding and this is not currently supported... is there any other way to use terraform to bind the Durable Object to the worker? |
@davidfernandezm Sorry for the late answer. I gave up on Terraform on the worker I was implementing the following for.
@jacobbednarz I don't know if you have found an answer regarding this, I'm willing to take back the work on this if you have some answers for me 😄 |
We can just give up on durable objects and use wrangler as backup plan |
This PR addresses #1320 and follows upon the work done on cloudflare/cloudflare-go#949! 🙂
Closes #1320