Skip to content

Handle Event Ordering and Duplicate Processing #71

@DakotaCondos

Description

@DakotaCondos

As a system maintainer,
I want the Function App to handle duplicate and out-of-order robot events,
so that the Cosmos DB bot read model remains accurate.

Acceptance Criteria

  • Given the same event is delivered more than once
    When the Function App processes the duplicate
    Then the duplicate does not create incorrect state or inventory changes.

  • Given an older telemetry event arrives after a newer telemetry event
    When timestamps are compared
    Then the older telemetry event is ignored for state updates.

  • Given an older stock event arrives after a newer stock event
    When timestamps are compared
    Then the older stock event is ignored for inventory updates.

  • Given a status event is newer than the current status timestamp
    When the Function App processes it
    Then the bot status is updated.

  • Given event processing fails
    When the Function App cannot update Cosmos DB
    Then the failure is logged and the event can be retried or investigated.

Metadata

Metadata

Assignees

Labels

No labels
No labels
No fields configured for User Story.

Projects

Status

In progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions