Commit b60ddec
[FSSDK-11179] Update: Send CMAB uuid in impression events (#584)
* update: add CmabService to Optimizely class and builder
* update: integrate CMAB service into OptimizelyFactory
* update: change CmabService field to non-nullable in Optimizely class
* update: add CmabService to DecisionService and its tests
* update: implement CMAB traffic allocation in Bucketer and DecisionService
* update: enhance DecisionService, FeatureDecision, and DecisionResponse to support CMAB UUID handling
* update: enhance DecisionService and DecisionMessage to handle errors and include CMAB UUIDs in responses
* update: add validConfigJsonCMAB method to DatafileProjectConfigTestUtils for CMAB configuration
* update: add tests to verify precedence of whitelisted and forced variations over CMAB service decisions in DecisionService
* update: add test to verify error handling in getVariation for CMAB service failures
* update: modify DecisionResponse to include additional error handling information
* update: fix error handling assertion in DecisionServiceTest to correctly verify error state
* update: add tests for CMAB experiment variations in DecisionService
* update: implement decision-making methods to skip CMAB logic in Optimizely and DecisionService
* update: add methods to OptimizelyUserContext for decision-making without CMAB logic
* update: add asynchronous decision-making methods in OptimizelyUserContext and related fetcher classes
* update: add decision-making methods without CMAB logic in OptimizelyUserContextTest
* update: remove unused parameter 'useCmab' from DecisionService method documentation
* update: rename methods to use 'Sync' suffix for clarity in decision-making logic
* update: add cmabUUID parameter to impression event methods and related classes
* update: return cmab error decision whenever found
* update: enhance error handling by specifying CMAB error messages in decision responses
* update: improve error handling by checking for null values in experiment key retrieval
* update: fix CMAB error handling by providing a valid Experiment in FeatureDecision
* update: add Javadoc comments for async decision methods and config creation in CMAB client
* update: refactor build to use cmabClient instead of default service
* update: refactor DefaultCmabClient to utilize CmabClientHelper
* update: refactor AsyncDecisionsFetcher to AsyncDecisionFetcher and enhance decision handling
* update: add missing copyright notice and license information to CmabClientHelper
* update: enhance CMAB handling in bucketing and decision services, add backward compatibility for mobile apps
* update: add backward compatibility support for Android sync and async decisions in OptimizelyUserContext
* update: add empty list parameter to decision methods in OptimizelyUserContextTest for consistency
* update: replace null with empty list parameter in async decision method for consistency
* update: add useCmab parameter to decideForKeys methods for enhanced decision handling
* Update core-api/src/main/java/com/optimizely/ab/Optimizely.java
Co-authored-by: Jae Kim <45045038+jaeopt@users.noreply.github.com>
* update: refactor decision-making logic to use DecisionPath enum for clarity and maintainability
* Update core-api/src/main/java/com/optimizely/ab/Optimizely.java
Co-authored-by: Jae Kim <45045038+jaeopt@users.noreply.github.com>
* Update core-api/src/main/java/com/optimizely/ab/Optimizely.java
Co-authored-by: Jae Kim <45045038+jaeopt@users.noreply.github.com>
* update: modify OptimizelyUserContext to change optimizely field to package-private and add copyright notice to DecisionPath
* update: implement asynchronous decision-making methods in Optimizely and OptimizelyUserContext with corresponding tests
* update: refactor DefaultCmabService to remove CmabServiceOptions dependency and adjust related tests
* update: refactor DefaultCmabService to use a generic Cache interface and enhance builder methods for cache configuration
* fix to support android-sdk
* clean up
* update: refactor bucketing logic to remove CMAB handling from DecisionService and adjust tests accordingly
* update: introduce CacheWithRemove interface and refactor DefaultCmabService to utilize it
* update: implement CacheWithRemove interface in DefaultLRUCache class
* update: refactor OptimizelyFactory to remove CMAB cache methods and adjust instance creation logic
* update: refactor DefaultCmabService to streamline logger initialization and enhance cache handling logging
* cleanup
* triggering fsc with cmab flag on
* testing fix
* Revert
* Add support for CMAB traffic allocation in Bucketer class
* Add DecisionPath parameter to bucketing methods for CMAB support
* Remove unused imports from Optimizely.java
* Update core-api/src/main/java/com/optimizely/ab/bucketing/Bucketer.java
comment update
Co-authored-by: Jae Kim <45045038+jaeopt@users.noreply.github.com>
---------
Co-authored-by: Jae Kim <45045038+jaeopt@users.noreply.github.com>
Co-authored-by: Jae Kim <jae.kim@optimizely.com>1 parent efbda89 commit b60ddec
File tree
9 files changed
+208
-43
lines changed- core-api/src
- main/java/com/optimizely/ab
- bucketing
- event/internal
- payload
- test/java/com/optimizely/ab
- bucketing
- event/internal
9 files changed
+208
-43
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
47 | 46 | | |
48 | 47 | | |
49 | 48 | | |
| |||
306 | 305 | | |
307 | 306 | | |
308 | 307 | | |
309 | | - | |
| 308 | + | |
310 | 309 | | |
311 | 310 | | |
312 | 311 | | |
| |||
319 | 318 | | |
320 | 319 | | |
321 | 320 | | |
| 321 | + | |
322 | 322 | | |
323 | 323 | | |
324 | 324 | | |
| |||
327 | 327 | | |
328 | 328 | | |
329 | 329 | | |
330 | | - | |
| 330 | + | |
| 331 | + | |
331 | 332 | | |
332 | 333 | | |
333 | 334 | | |
| |||
337 | 338 | | |
338 | 339 | | |
339 | 340 | | |
340 | | - | |
| 341 | + | |
| 342 | + | |
341 | 343 | | |
342 | 344 | | |
343 | 345 | | |
| |||
499 | 501 | | |
500 | 502 | | |
501 | 503 | | |
502 | | - | |
| 504 | + | |
503 | 505 | | |
504 | 506 | | |
505 | 507 | | |
| |||
521 | 523 | | |
522 | 524 | | |
523 | 525 | | |
524 | | - | |
| 526 | + | |
| 527 | + | |
525 | 528 | | |
526 | 529 | | |
527 | 530 | | |
| |||
1336 | 1339 | | |
1337 | 1340 | | |
1338 | 1341 | | |
| 1342 | + | |
| 1343 | + | |
1339 | 1344 | | |
1340 | 1345 | | |
1341 | 1346 | | |
| |||
1345 | 1350 | | |
1346 | 1351 | | |
1347 | 1352 | | |
1348 | | - | |
| 1353 | + | |
| 1354 | + | |
1349 | 1355 | | |
1350 | 1356 | | |
1351 | 1357 | | |
| |||
Lines changed: 40 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
97 | 98 | | |
98 | 99 | | |
99 | 100 | | |
100 | | - | |
| 101 | + | |
| 102 | + | |
101 | 103 | | |
102 | 104 | | |
103 | 105 | | |
| |||
111 | 113 | | |
112 | 114 | | |
113 | 115 | | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
114 | 127 | | |
115 | | - | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
116 | 135 | | |
117 | 136 | | |
118 | 137 | | |
| |||
134 | 153 | | |
135 | 154 | | |
136 | 155 | | |
| 156 | + | |
137 | 157 | | |
138 | 158 | | |
139 | 159 | | |
140 | 160 | | |
141 | 161 | | |
142 | | - | |
| 162 | + | |
| 163 | + | |
143 | 164 | | |
144 | 165 | | |
145 | 166 | | |
| |||
154 | 175 | | |
155 | 176 | | |
156 | 177 | | |
157 | | - | |
158 | | - | |
159 | 178 | | |
160 | 179 | | |
161 | 180 | | |
| |||
172 | 191 | | |
173 | 192 | | |
174 | 193 | | |
175 | | - | |
| 194 | + | |
176 | 195 | | |
177 | 196 | | |
178 | 197 | | |
179 | 198 | | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
180 | 214 | | |
181 | 215 | | |
182 | 216 | | |
| |||
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
170 | 170 | | |
171 | 171 | | |
172 | 172 | | |
173 | | - | |
174 | | - | |
| 173 | + | |
| 174 | + | |
175 | 175 | | |
176 | 176 | | |
177 | 177 | | |
| |||
Lines changed: 10 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
| 44 | + | |
| 45 | + | |
45 | 46 | | |
46 | 47 | | |
47 | 48 | | |
| |||
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
71 | | - | |
| 72 | + | |
72 | 73 | | |
73 | 74 | | |
74 | 75 | | |
75 | 76 | | |
76 | | - | |
77 | | - | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
78 | 84 | | |
79 | 85 | | |
80 | 86 | | |
| |||
Lines changed: 18 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
36 | 38 | | |
37 | 39 | | |
38 | 40 | | |
39 | 41 | | |
40 | 42 | | |
41 | | - | |
| 43 | + | |
42 | 44 | | |
43 | 45 | | |
44 | 46 | | |
45 | 47 | | |
46 | 48 | | |
| 49 | + | |
47 | 50 | | |
48 | 51 | | |
49 | 52 | | |
| |||
66 | 69 | | |
67 | 70 | | |
68 | 71 | | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
69 | 76 | | |
70 | 77 | | |
71 | 78 | | |
| |||
77 | 84 | | |
78 | 85 | | |
79 | 86 | | |
| 87 | + | |
80 | 88 | | |
81 | 89 | | |
82 | 90 | | |
| |||
86 | 94 | | |
87 | 95 | | |
88 | 96 | | |
| 97 | + | |
89 | 98 | | |
90 | 99 | | |
91 | 100 | | |
| |||
97 | 106 | | |
98 | 107 | | |
99 | 108 | | |
| 109 | + | |
100 | 110 | | |
101 | 111 | | |
102 | 112 | | |
| |||
108 | 118 | | |
109 | 119 | | |
110 | 120 | | |
| 121 | + | |
111 | 122 | | |
112 | 123 | | |
113 | 124 | | |
| |||
134 | 145 | | |
135 | 146 | | |
136 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
137 | 153 | | |
138 | | - | |
| 154 | + | |
139 | 155 | | |
140 | 156 | | |
141 | 157 | | |
0 commit comments