mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-11-29 00:53:24 +00:00
Remove and read alert on sync offset (#19862)
(cherry picked from commit fce358eaa2c154acabcce851aa22dc783c30d5dc)
This commit is contained in:
parent
b7611081a4
commit
aac55afaa7
@ -115,7 +115,7 @@ public class EventSubscriptionRepository extends EntityRepository<EventSubscript
|
|||||||
}
|
}
|
||||||
|
|
||||||
public EventSubscriptionOffset syncEventSubscriptionOffset(String eventSubscriptionName) {
|
public EventSubscriptionOffset syncEventSubscriptionOffset(String eventSubscriptionName) {
|
||||||
EventSubscription eventSubscription = getByName(null, eventSubscriptionName, getFields("id"));
|
EventSubscription eventSubscription = getByName(null, eventSubscriptionName, getFields("*"));
|
||||||
long latestOffset = daoCollection.changeEventDAO().getLatestOffset();
|
long latestOffset = daoCollection.changeEventDAO().getLatestOffset();
|
||||||
long currentTime = System.currentTimeMillis();
|
long currentTime = System.currentTimeMillis();
|
||||||
// Upsert Offset
|
// Upsert Offset
|
||||||
@ -133,6 +133,7 @@ public class EventSubscriptionRepository extends EntityRepository<EventSubscript
|
|||||||
"eventSubscriptionOffset",
|
"eventSubscriptionOffset",
|
||||||
JsonUtils.pojoToJson(eventSubscriptionOffset));
|
JsonUtils.pojoToJson(eventSubscriptionOffset));
|
||||||
|
|
||||||
|
EventSubscriptionScheduler.getInstance().updateEventSubscription(eventSubscription);
|
||||||
return eventSubscriptionOffset;
|
return eventSubscriptionOffset;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user