Skip to content

feat(transform): Add Meta KV Store Lock Transform#177

Merged
jshlbrd merged 9 commits intomainfrom
jshlbrd/feat/tf-kv-lock
Jun 4, 2024
Merged

feat(transform): Add Meta KV Store Lock Transform#177
jshlbrd merged 9 commits intomainfrom
jshlbrd/feat/tf-kv-lock

Conversation

@jshlbrd
Copy link
Contributor

@jshlbrd jshlbrd commented May 22, 2024

Description

  • Adds meta_kv_store_lock transform
    • Adds Locker interface to internal/kv
    • Adds Locker support to DynamoDB and Memory KV stores
  • Adds "exactly once" examples to docs
  • Refactors enrich_kv_store_set transform

Motivation and Context

This adds the ability for any message to become "locked" in a KV store (typically, a distributed database) and have a transform applied to it. This addresses #59 with some additions and caveats:

  • This is not idempotency, but idempotency is possible by combining this transform with a few others
  • Any transform function can make use of this feature, not just "producers" (this concept no longer exists in Substation v1.0+)

How Has This Been Tested?

Integration tested using the added examples. Failure scenarios can be tested using the DynamoDB distributed lock example.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@jshlbrd jshlbrd marked this pull request as ready for review June 3, 2024 22:06
@jshlbrd jshlbrd requested a review from a team as a code owner June 3, 2024 22:06
@jshlbrd jshlbrd merged commit 34d2ffb into main Jun 4, 2024
@jshlbrd jshlbrd deleted the jshlbrd/feat/tf-kv-lock branch June 4, 2024 23:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants