Commit c2bd091
authored
feat(core): Allow multiplexed transport to send to multiple releases (#8559)
The multiplexed transport can already route events to different or
multiple DSNs but we also need to be able to route to specific releases
too.
In a page with micro-frontends, it's possible (and probably even quite
common) to be using the same dependency multiple times but different
versions (ie. different releases). Depending on where an error occurs we
might want to send an event to `cool-internal-components@1.0.0-beta` or
`cool-internal-components@0.9.0` at the same DSN.
This PR:
- Adds a private `makeOverrideReleaseTransport` which can used to wrap a
transport and override the release on all events
- Modifies `makeMultiplexedTransport` so it now creates a transport for
each unique dsn/release pair
- And uses `makeOverrideReleaseTransport` whenever a release is returned
from the callback1 parent 6b009c0 commit c2bd091
File tree
2 files changed
+73
-11
lines changed- packages/core
- src/transports
- test/lib/transports
2 files changed
+73
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
| 28 | + | |
28 | 29 | | |
29 | | - | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
30 | 36 | | |
31 | 37 | | |
32 | 38 | | |
| |||
40 | 46 | | |
41 | 47 | | |
42 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
43 | 73 | | |
44 | 74 | | |
45 | 75 | | |
| |||
51 | 81 | | |
52 | 82 | | |
53 | 83 | | |
54 | | - | |
55 | | - | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
56 | 90 | | |
57 | 91 | | |
58 | 92 | | |
59 | 93 | | |
60 | 94 | | |
61 | | - | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
62 | 99 | | |
63 | 100 | | |
64 | | - | |
| 101 | + | |
65 | 102 | | |
66 | 103 | | |
67 | 104 | | |
| |||
71 | 108 | | |
72 | 109 | | |
73 | 110 | | |
74 | | - | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
75 | 118 | | |
76 | 119 | | |
77 | 120 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | | - | |
| 9 | + | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| |||
47 | 48 | | |
48 | 49 | | |
49 | 50 | | |
50 | | - | |
| 51 | + | |
51 | 52 | | |
52 | 53 | | |
53 | 54 | | |
| |||
57 | 58 | | |
58 | 59 | | |
59 | 60 | | |
60 | | - | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
61 | 65 | | |
62 | 66 | | |
63 | 67 | | |
| |||
111 | 115 | | |
112 | 116 | | |
113 | 117 | | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
114 | 133 | | |
115 | 134 | | |
116 | 135 | | |
| |||
0 commit comments