I am using the Java SDK to get blob-modification updates, and I am seeing surprising behavior from the continuationToken. I am storing the continuationToken from the last page of results and using that stored token for my next request, i.e.:
- String theCheckpoint = page.getContinuationToken();
- Wait a while, modify some blobs in the meantime
- results = blobChangefeedClient.getEvents(theCheckpoint);
results will be empty. I would expect results to contain the records of the blob-modifications I did.
The problem seems to be the EndTime field that is in the token, because if I take that token and manually modify the EndTime to be one day out, then the token works as desired and I get back the events that happened.
The question is: why doesn't the blob-change-feed request detect the latest changes when I pass it the continuation token?
After further exploration, I think I can narrow down the problem.
At 15:15 on April 9th, I requested the events from the change feed, passing a blank for a continuation-token. I got this back:
{"CursorVersion":1,"UrlHost":"zuse1hltd1lexists.blob.core.windows.net","EndTime":"2021-04-09T15:00:00Z","CurrentSegmentCursor":{"ShardCursors":[{"CurrentChunkPath":"log/00/2021/04/08/1700/00000.avro","BlockOffset":3054,"EventIndex":0}],"CurrentShardPath":"log/00/2021/04/08/1700/","SegmentPath":"idx/segments/2021/04/08/1700/meta.json"}}
The EndTime seems to render this cursor unusable. In order to make it usable, I have to manually modify the EndTime.