-
Notifications
You must be signed in to change notification settings - Fork 29
[MOB-9340] Fix for removing recalled campaigns from device memory #893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
…val- Ensure in-app messages are marked as consumed before being removed from local storage to prevent re-display.- Add unit test to verify that recalled messages are correctly marked as consumed and inAppConsume is called.
…ter message removal in `IterableFirebaseMessagingService`.- Mark messages as consumed before removal in `IterableInAppManager` to prevent re-display.
…Central, upgrade Kotlin to 1.9.22, and configure JVMtoolchain to 17. Refactor javadoc task for compatibility with new Android Gradle Plugin.
…or message retrieval- Replaced array with Arrays.asList for better readability and flexibility.- Added missing import for Arrays.
…n-app messages are marked as consumed through the API before being removed from storage to prevent re-display.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added suggestions
buildFeatures { | ||
buildConfig true | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets remove all the build and embedded related changes from this PR
storage.removeMessage(localMessage); | ||
api.inAppConsume(localMessage, null, null, null, null); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets get a confirmation from product to see if recalled message should be consumed. As it could affect the analytics.
Also referencing localMessage
after its removal could cause problems.
Ticket: https://iterable.atlassian.net/browse/MOB-9340
ISSUE: In-App Messages Remain Visible After Server Recall
PROBLEM DESCRIPTION:
In-app messages continue to display on Android devices even after they've been recalled server-side. The SDK recognizes the recall event but fails to mark these messages as consumed locally, causing them to remain visible to users.
ROOT CAUSE:
During synchronization, the SDK correctly identifies messages that have been removed from the server (missing from server response but present in local storage)
FIX IMPLEMENTED:
Modified the syncWithRemoteQueue() method in IterableInAppManager.java to mark messages as consumed before removing them from storage when they're no longer present in the server response.
The changes are minimal and targeted, similar to the iOS fix. Added unit test to verify the fix works correctly.