[
https://issues.apache.org/jira/browse/SENTRY-1760?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16008259#comment-16008259
]
Sergio Peña commented on SENTRY-1760:
-------------------------------------
[~akolb] I finally got these decisions ideas on the HMSFollower that will
require a full snapshot. One question first, should we allow forcing a snapshot
while HMSFollower is running? or should this forcing state be saved on the
Sentry store so we do a full snapshot on the next Sentry service restart?
How and when to detect a full snapshot is required?
During HMSFollower constructor:
- No transactions have been processed yet (current situation).
- Sentry store has a PARTIAL_SNAPSHOT state (Note: Any error while processing
notifications should set PARTIAL_SNAPSHOT state on the Sentry store).
During HMSFollower start:
- Sentry latest notification ID > HMS latest notification ID.
- HMS latest notification ID - Sentry latest notification ID has a gap of
notifications (due to HMS notification cleanup).
i.e. Sentry has id=40 and HMS has id=150. 150-40=110 notifications should be
fetched from HMS, but only 90 are fetched.
This is a new decision as well:
- What if Sentry id 40 and HMS id 40 are different? Let's say HMS had a
cleanup, and HMS did exactly 40 notifications after it. Sentry won't be in sync
because even if it already processed 40 notifications before, the HMS has
different metadata. This looks too unlikely, but should we take it into account?
> HMSFollower should detect when a full snapshot from HMS is required
> -------------------------------------------------------------------
>
> Key: SENTRY-1760
> URL: https://issues.apache.org/jira/browse/SENTRY-1760
> Project: Sentry
> Issue Type: Sub-task
> Components: Sentry
> Affects Versions: sentry-ha-redesign
> Reporter: Alexander Kolbasov
> Assignee: Sergio Peña
> Priority: Blocker
> Fix For: sentry-ha-redesign
>
>
> The current criteria for getting a full snapshot from HMS is insufficient. We
> need to get full snapshot every time when there is a gap between last stored
> notification and the smallest notification available from HMS.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)