-
Notifications
You must be signed in to change notification settings - Fork 18
feat: Enable per-component restart and update within workloads #221
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
base: main
Are you sure you want to change the base?
Conversation
8feaa12 to
cbdf8a8
Compare
Signed-off-by: Aditya <[email protected]>
Signed-off-by: Aditya <[email protected]>
cbdf8a8 to
254aa35
Compare
…ndler cache to reload component chain Signed-off-by: Aditya <[email protected]>
Signed-off-by: Aditya <[email protected]>
Signed-off-by: Aditya <[email protected]>
|
I don't think we'd want this behaviour at the protobuf / clustered level. maybe at the wash engine level only ⚖️ ( for embedding / wash dev ). Following Kubernetes / distributed-systems principles, "Restarts" are "Redeploys" by design for a few key reasons:
This "update-in-place" behavior is present in wasmcloud v1 + wadm and caused many outages / deploy issues and latency due to extra wrpc/nats layer. |
Signed-off-by: Aditya <[email protected]>
|
I agree with @lxfontes here. However, what if you have a workload consisting of components A and B. Component A changes a lot, so you have to redeploy your workload. But component B does not change a lot, which gives an overhead of redeploying component B as well. Would it then be wise to separate the components into two workloads and let component A and B communicate through wasmcloud/messaging? |
646481e to
5604816
Compare
…l component updates Introduce synchronization primitives and test coverage so component updates wait for in-flight requests to drain and queued requests are held until the component returns to Running. Signed-off-by: Aditya <[email protected]>
5604816 to
56366a1
Compare
Feature or Problem
This PR adds component-level lifecycle management to the wasmcloud runtime, enabling granular control over individual components within a workload without requiring full workload restarts. Previously, any component update or state change required restarting the entire workload, causing unnecessary downtime for unaffected components.
Key capabilities added:
workload_updateautomatically detects which components changed and updates only thoseRelated Issues
Release Information
nextConsumer Impact
Breaking Changes: None - this is a backwards-compatible addition.
API Additions:
WorkloadStartRequestnow accepts optionalcomponent_idsfilter to start specific componentsWorkloadStopRequestnow accepts optionalcomponent_idsfilter to stop specific componentsWorkloadUpdateRequestadded - takes aWorkloadspec and updates only changed componentsWorkloadStatusResponsenow includesComponentInfolist with per-component state (id, name, state, message)Componenttype now has optionalnamefield for stable identificationRuntime Behavior Changes:
component_idsremain in memory withStoppedstate (can be restarted quickly)Testing
Unit Test(s)
None
Acceptance or Integration
Will commit soon
Manual Verification
tested it in an integration test setup, locally