From 51767818ef03c95d707d7c2b2b6eb36feaeb98c0 Mon Sep 17 00:00:00 2001 From: Michael Adler Date: Thu, 31 Aug 2023 15:35:29 +0200 Subject: [PATCH] docs: review comments Signed-off-by: Michael Adler --- docs/operations.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/docs/operations.md b/docs/operations.md index 692ee093..2c7c7029 100644 --- a/docs/operations.md +++ b/docs/operations.md @@ -132,8 +132,8 @@ wfxctl job events ``` This may result in a large number of events, though. For a more targeted approach, filter parameters may be used. -Assuming the job ids are known (because the jobs have been created already), the following will subscribe to events for -job IDs that match either of the two specified: +Assuming the job IDs are known (either because the jobs have been created already or the IDs are received via another +subscription channel), the following will subscribe to events matching either of the two specified job IDs: ```bash wfxctl job events --ids d305e539-1d41-4c95-b19a-2a7055c469d0,e692ad92-45e6-4164-b3fd-8c6aa884011c @@ -143,14 +143,15 @@ See `wfxctl job events --help` for other filter parameters, e.g. workflow names. #### Considerations and Limitations -1. **Asynchronous Job Status Updates**: Job status updates are sent asynchronously to minimize the risk of a subscriber - causing delays. As a result, messages could arrive in an unpredictable sequence, deviating from the client's +1. **Asynchronous Job Status Updates**: Job status updates are sent asynchronously to avoid the risk of a subscriber + causing delays. As a result, messages could arrive in a not necessarily linear order, deviating from the client's expectation of a naturally ordered flow of events. While this is generally not a concern, it could become an issue in high-concurrency situations. For example, when multiple clients try to modify the same job or when a single client issues a rapid sequence of status updates. 2. **Unacknowledged Server-Sent Events (SSE)**: SSE operates on a one-way communication model and does not include an acknowledgment or handshake protocol to confirm message delivery. This design choice aligns with the fundamental - principles of SSE but does mean that there's a possibility some events may not reach the intended subscriber. + principles of SSE but does mean that there's a possibility some events may not reach the intended subscriber (which + the client can possibly detect by keeping track of SSE event IDs). 3. **Load Balancer Stickiness for Horizontal Scaling**: When scaling out horizontally, ensure that the load balancer is configured to maintain stickiness based on job IDs. An alternative approach would be for the client to subscribe to updates from all instances in the workload orchestration system (e.g., every wfx instance) and then aggregate the