[AI-FSSDK] [FSSDK-12670] Block ODP identify event for single identifier#629
Open
jaeopt wants to merge 4 commits into
Open
[AI-FSSDK] [FSSDK-12670] Block ODP identify event for single identifier#629jaeopt wants to merge 4 commits into
jaeopt wants to merge 4 commits into
Conversation
Skip sending ODP identify event when fewer than 2 valid (non-null, non-empty) identifiers exist. Changed ODPEventManager.identifyUser to accept a Map<String, String> of identifiers and filter out null/empty values before checking count. Updated Optimizely.identifyUser to construct identifier map from userId string and pass to ODPEventManager. Updated all related tests to use Map-based API.
…compatibility Keep old identifyUser(String) and identifyUser(String, String) signatures as @deprecated wrappers that delegate to the new identifyUser(Map) method. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Mat001
requested changes
May 27, 2026
Contributor
Mat001
left a comment
There was a problem hiding this comment.
Looks pretty good. A few comments.
Additional comment:
Several tests use assertEquals(identifiers.size(), 2) (JUnit convention is assertEquals(expected, actual)). The new test identifyUserSendsWithThreeIdentifiers correctly uses assertEquals(3, eventIdentifiers.size()) but the updated identifyUserWithMultipleIdentifiers still has the args reversed: assertEquals(eventIdentifiers.size(), 2). Inconsistent within the same PR.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes the ODP identify event to only send when multiple valid identifiers exist. Previously, identify events were always sent even with a single identifier, which provided no linking value and generated unnecessary network traffic.
Changes
Jira Ticket
FSSDK-12670
Notes