You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the documentation suggests using another worker for RPC services and DurableObjects. link
There isn't a documented way to bring the DurableObject into the same worker of a nextjs service.
Describe the solution you'd like
Ideally we can add/import DurableObject classes to an index.ts file in the src/ directory and have those made available in the bundle's worker.js file upon build. This would reduce the need for multiple workers to host a nextjs site with access to DO's. I imagine there would also be performance and latency gains as well (but I don't know enough about the RPC protocol to make that claim for sure).
Describe alternatives you've considered
The alternative right now is to build multiple workers and delegate RPC Services and DurableObject code to those workers.
@opennextjs/cloudflare version
0.3.0
Additional context
No response
Before submitting
I have checked that there isn't already a similar feature request
This is a single feature (not multiple features in one request)
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem?
Currently the documentation suggests using another worker for RPC services and DurableObjects. link
There isn't a documented way to bring the DurableObject into the same worker of a nextjs service.
Describe the solution you'd like
Ideally we can add/import
DurableObject
classes to an index.ts file in thesrc/
directory and have those made available in the bundle'sworker.js
file upon build. This would reduce the need for multiple workers to host a nextjs site with access to DO's. I imagine there would also be performance and latency gains as well (but I don't know enough about the RPC protocol to make that claim for sure).Describe alternatives you've considered
The alternative right now is to build multiple workers and delegate RPC Services and DurableObject code to those workers.
@opennextjs/cloudflare version
0.3.0
Additional context
No response
Before submitting
The text was updated successfully, but these errors were encountered: