|
| 1 | +id: core-dispatch-with-results |
| 2 | +snapshots: |
| 3 | + ? | |
| 4 | + # Using dispatch_with_results in a chain |
| 5 | + value = core.dispatch_with_results("my.event", (x,)).result.value |
| 6 | + print(value) |
| 7 | + : labels: |
| 8 | + - source: core.dispatch_with_results("my.event", (x,)) |
| 9 | + style: primary |
| 10 | + start: 49 |
| 11 | + end: 93 |
| 12 | + core.dispatch_with_results("my.event", (arg1, arg2)): |
| 13 | + labels: |
| 14 | + - source: core.dispatch_with_results("my.event", (arg1, arg2)) |
| 15 | + style: primary |
| 16 | + start: 0 |
| 17 | + end: 52 |
| 18 | + ? | |
| 19 | + data = core.dispatch_with_results("my.event", (arg1, arg2)) |
| 20 | + if data.result_key: |
| 21 | + process(data.result_key.value) |
| 22 | + : labels: |
| 23 | + - source: core.dispatch_with_results("my.event", (arg1, arg2)) |
| 24 | + style: primary |
| 25 | + start: 7 |
| 26 | + end: 59 |
| 27 | + dispatch_with_results("my.event", (arg1,)): |
| 28 | + labels: |
| 29 | + - source: dispatch_with_results("my.event", (arg1,)) |
| 30 | + style: primary |
| 31 | + start: 0 |
| 32 | + end: 42 |
| 33 | + event_hub.dispatch_with_results("my.event", ()): |
| 34 | + labels: |
| 35 | + - source: event_hub.dispatch_with_results("my.event", ()) |
| 36 | + style: primary |
| 37 | + start: 0 |
| 38 | + end: 47 |
| 39 | + ? | |
| 40 | + from ddtrace.internal import core |
| 41 | + result = core.dispatch_with_results("my.event", (arg1, arg2)) |
| 42 | + : labels: |
| 43 | + - source: core.dispatch_with_results("my.event", (arg1, arg2)) |
| 44 | + style: primary |
| 45 | + start: 43 |
| 46 | + end: 95 |
| 47 | + from ddtrace.internal.core import dispatch, dispatch_with_results: |
| 48 | + labels: |
| 49 | + - source: from ddtrace.internal.core import dispatch, dispatch_with_results |
| 50 | + style: primary |
| 51 | + start: 0 |
| 52 | + end: 65 |
| 53 | + from ddtrace.internal.core import dispatch, dispatch_with_results, on: |
| 54 | + labels: |
| 55 | + - source: from ddtrace.internal.core import dispatch, dispatch_with_results, on |
| 56 | + style: primary |
| 57 | + start: 0 |
| 58 | + end: 69 |
| 59 | + from ddtrace.internal.core import dispatch_with_results: |
| 60 | + labels: |
| 61 | + - source: from ddtrace.internal.core import dispatch_with_results |
| 62 | + style: primary |
| 63 | + start: 0 |
| 64 | + end: 55 |
| 65 | + ? | |
| 66 | + from ddtrace.internal.core import dispatch_with_results |
| 67 | + result = dispatch_with_results("my.event", (arg1,)) |
| 68 | + : labels: |
| 69 | + - source: from ddtrace.internal.core import dispatch_with_results |
| 70 | + style: primary |
| 71 | + start: 0 |
| 72 | + end: 55 |
| 73 | + from ddtrace.internal.core import dispatch_with_results as dwr: |
| 74 | + labels: |
| 75 | + - source: from ddtrace.internal.core import dispatch_with_results as dwr |
| 76 | + style: primary |
| 77 | + start: 0 |
| 78 | + end: 62 |
| 79 | + from ddtrace.internal.core import dispatch_with_results, on: |
| 80 | + labels: |
| 81 | + - source: from ddtrace.internal.core import dispatch_with_results, on |
| 82 | + style: primary |
| 83 | + start: 0 |
| 84 | + end: 59 |
| 85 | + from ddtrace.internal.core.event_hub import dispatch, dispatch_with_results: |
| 86 | + labels: |
| 87 | + - source: from ddtrace.internal.core.event_hub import dispatch, dispatch_with_results |
| 88 | + style: primary |
| 89 | + start: 0 |
| 90 | + end: 75 |
| 91 | + from ddtrace.internal.core.event_hub import dispatch_with_results: |
| 92 | + labels: |
| 93 | + - source: from ddtrace.internal.core.event_hub import dispatch_with_results |
| 94 | + style: primary |
| 95 | + start: 0 |
| 96 | + end: 65 |
| 97 | + ? | |
| 98 | + from ddtrace.internal.core.event_hub import dispatch_with_results |
| 99 | + result = dispatch_with_results("my.event", ()) |
| 100 | + : labels: |
| 101 | + - source: from ddtrace.internal.core.event_hub import dispatch_with_results |
| 102 | + style: primary |
| 103 | + start: 0 |
| 104 | + end: 65 |
| 105 | + from ddtrace.internal.core.event_hub import dispatch_with_results as dwr: |
| 106 | + labels: |
| 107 | + - source: from ddtrace.internal.core.event_hub import dispatch_with_results as dwr |
| 108 | + style: primary |
| 109 | + start: 0 |
| 110 | + end: 72 |
| 111 | + ? | |
| 112 | + result = core.dispatch_with_results("my.event", (arg1, arg2)).result_key.value |
| 113 | + : labels: |
| 114 | + - source: core.dispatch_with_results("my.event", (arg1, arg2)) |
| 115 | + style: primary |
| 116 | + start: 9 |
| 117 | + end: 61 |
0 commit comments