Skip to content

#1915 fix retrieving the historical value of a thing with at-historical-timestamp#2033

Merged
thjaeckle merged 1 commit intoeclipse-ditto:masterfrom
beyonnex-io:bugfix/1915-at-historical-timestamp
Sep 27, 2024
Merged

#1915 fix retrieving the historical value of a thing with at-historical-timestamp#2033
thjaeckle merged 1 commit intoeclipse-ditto:masterfrom
beyonnex-io:bugfix/1915-at-historical-timestamp

Conversation

@thjaeckle
Copy link
Member

There were several issues with the logic:

  • the first issue was that as fallback when no at-historical-revision was provided, the "Latest" sequence number was selected -> which resulted in returning the latest state
    • that was fixed by not falling back at that place to this "fallback value", but work with a Optional instead
  • the second problem was that for a thing which was freshly created (and as a result of that "freshness" no Snapshot was yet written into the snapshot store), Ditto did not distinguish correctly between "has not yet a snapshot" and "is not existing at the provided timestamp"

Both issues are fixed by this PR and using at-historical-timestamp should now work.

Fixes: #1915

…h `at-historical-timestamp` when a snapshot was not yet written
@thjaeckle thjaeckle added the bug label Sep 26, 2024
@thjaeckle thjaeckle added this to the 3.6.0 milestone Sep 26, 2024
@thjaeckle thjaeckle self-assigned this Sep 26, 2024
@thjaeckle
Copy link
Member Author

@alstanchev @kalinkostashki could you please have a look?

Copy link
Contributor

@alstanchev alstanchev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@thjaeckle thjaeckle merged commit fa6537d into eclipse-ditto:master Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Cannot retrieve entity at revision

2 participants