Looking for feedback: adds interceptor lifecycle hook#602
Looking for feedback: adds interceptor lifecycle hook#602
Conversation
This proposes a new hook to allow one to remotely push execution of a Burr Action. For example, if one wants to selectively push remote execution of an action to say Ray, then one can now build an interceptor. This also introduces companion hooks that would run pre & post on the remote to mirror what Burr has today - -I thought it would be simpler to not try to reuse those hooks, and instead make it explicit as to what is going on if you wanted to add something similar. See tests for examples, but open to feedback here. Note: we'd need to think through how this plays with parallelism functionality we have. E.g. currently interceptors aren't propagated to sub applications...
These examples needed to be vetted more. If the interceptors here seem good, we could look to bring them in first class to the library.
|
A preview of is uploaded and can be seen here: ✨ https://burr.dagworks.io/pull/602 ✨ Changes may take a few minutes to propagate. Since this is a preview of production, content with |
|
@skrawcz Thanks for opening this — I really like the direction of making remote execution explicit via lifecycle hooks. Before diving into design feedback, I’m trying to fully understand the current execution flow vs the new interception path. A few things I’m exploring:
I’ll follow up with more concrete observations once I’ve traced the execution path locally. |
|
Hey @skrawcz Running the full test suite locally shows failures related to missing optional integration dependencies (redis, mongodb, asyncpg, langchain, etc.), not interceptor behavior. From what I can see so far, the interceptor lifecycle implementation itself appears stable under 3.11. I’m continuing to look into what might be causing the CI 3.11/3.12 failures — especially around async execution paths or example validation. |
This proposes a new hook to allow one to remotely push execution of a Burr Action.
For example, if one wants to selectively push remote execution of an action to say Ray,
then one can now build an interceptor.
This also introduces companion hooks that would run pre & post on the remote to mirror
what Burr has today - -I thought it would be simpler to not try to reuse those hooks, and
instead make it explicit as to what is going on if you wanted to add something similar.
See tests for examples, but open to feedback here.
Note: we'd need to think through how this plays with parallelism functionality we have.
E.g. currently interceptors aren't propagated to sub applications...
Changes
How I tested this
Notes
This change needs to have some thought and discussion.
Checklist