Commit aeea6ff
committed
docs(insight): correct two rationales, note drain latency
The log filter's bind_invocation took a process-global lock on every
operation-start and user-function-start hook although the work is idempotent
after the first call on a thread. It now returns early when the thread
already carries this provider's claim.
Two comments described an ordering the SDK prevents. Insight's lock said a
checkpoint-path operation-change "genuinely races" the invocation-end hook;
the SDK joins the checkpoint thread and the branch pools before that hook is
dispatched. The lock stays -- it is what makes reentrancy from customer code
inside a build safe, and a guard resting on the SDK's join ordering is one
refactor from being wrong -- but the comment now says which of the two it is.
The Insight README documents what the invocation-end drain costs under
concurrency: it waits for every record any execution had pending, and one
worker serializes every export and flush, so ends are released together at
the slowest. Measured with a 30 ms exporter: ~72 ms at one execution, ~1.8 s
each at 48.1 parent 0559917 commit aeea6ff
3 files changed
Lines changed: 31 additions & 5 deletions
File tree
- packages
- aws-durable-execution-sdk-python-insight
- src/aws_durable_execution_sdk_python_insight
- aws-durable-execution-sdk-python-otel/src/aws_durable_execution_sdk_python_otel
Lines changed: 13 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
233 | 246 | | |
234 | 247 | | |
235 | 248 | | |
| |||
Lines changed: 10 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
281 | 281 | | |
282 | 282 | | |
283 | 283 | | |
284 | | - | |
285 | | - | |
286 | | - | |
287 | | - | |
288 | | - | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
289 | 294 | | |
290 | 295 | | |
291 | 296 | | |
| |||
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
135 | 140 | | |
136 | 141 | | |
137 | 142 | | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
138 | 146 | | |
139 | 147 | | |
140 | 148 | | |
| |||
0 commit comments