-
Notifications
You must be signed in to change notification settings - Fork 544
State: KeysLike #4087
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
State: KeysLike #4087
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9c07640 to
556591d
Compare
PR adds a new state store API `KeysLike`, which allows listing keys
which match a given SQL LIKE style wildcard pattern ("%" and "_"). This
API is implemented currently solely to enable the workflow instance
listing functionality in Dapr, however could be exposed to the general
state APIs in future.
The request takes and requires a input `Pattern` field which is used to
match keys on. Also accepts an optional `PageSize` to limit the number of
results returned, and a `ContinueToken` to continue listing from a
previous request page.
Only returns the keys as a string slice. This function does not return
any values. Naturally, some state stores have better/more efficient
support for SQL LIKE style key queries.
Adds support for state stores:
- PostgreSQL (v1 and v2)
- MySQL
- SQLite
- SQL Server
- CockroachDB
- MongoDB
- Redis
- etcd
- In-Memory
Notes:
Both postgres v1 and v2 have a new migration to add a `row_id` column,
which is a unique identifier for each row. This is used to page results
efficiently and consistently.
The in-memory store now tracks an internal id for each key/value pair to
allow consistent paging when keys are added/removed during listing.
MySQL also introduces a new `row_id` column in migration for the same
purpose.
A new state feature `FeatureKeysLike` has been added to signal
`KeysLike` API support.
A conformance test has been added to test the `KeysLike` API for all
supported state stores.
Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: joshvanl <me@joshvanl.dev>
Contributor
|
LGTM |
acroca
reviewed
Nov 6, 2025
Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: joshvanl <me@joshvanl.dev>
cicoyle
requested changes
Nov 10, 2025
Contributor
cicoyle
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mostly lgtm just a few comments
Signed-off-by: joshvanl <me@joshvanl.dev>
cicoyle
approved these changes
Nov 13, 2025
javier-aliaga
pushed a commit
to javier-aliaga/components-contrib
that referenced
this pull request
Nov 20, 2025
Signed-off-by: joshvanl <me@joshvanl.dev>
kgal-akl
pushed a commit
to akeylesslabs/DAPR-components
that referenced
this pull request
Dec 1, 2025
Signed-off-by: joshvanl <me@joshvanl.dev> Signed-off-by: Kobbi Gal <kobbi.g@akeyless.io>
kgal-akl
pushed a commit
to akeylesslabs/DAPR-components
that referenced
this pull request
Dec 1, 2025
Signed-off-by: joshvanl <me@joshvanl.dev> Signed-off-by: Kobbi Gal <kobbi.g@akeyless.io>
kgal-akl
pushed a commit
to akeylesslabs/DAPR-components
that referenced
this pull request
Dec 1, 2025
Signed-off-by: joshvanl <me@joshvanl.dev> Signed-off-by: Kobbi Gal <kobbi.g@akeyless.io>
kgal-akl
pushed a commit
to akeylesslabs/DAPR-components
that referenced
this pull request
Dec 1, 2025
Signed-off-by: joshvanl <me@joshvanl.dev> Signed-off-by: Kobbi Gal <kobbi.g@akeyless.io>
kgal-akl
pushed a commit
to akeylesslabs/DAPR-components
that referenced
this pull request
Dec 9, 2025
Signed-off-by: joshvanl <me@joshvanl.dev> Signed-off-by: Kobbi Gal <kobbi.g@akeyless.io>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR adds a new state store API
KeysLike, which allows listing keyswhich match a given SQL LIKE style wildcard pattern ("%" and "_"). This
API is implemented currently solely to enable the workflow instance
listing functionality in Dapr, however could be exposed to the general
state APIs in future.
The request takes and requires a input
Patternfield which is used tomatch keys on. Also accepts an optional
PageSizeto limit the number ofresults returned, and a
ContinueTokento continue listing from aprevious request page.
Only returns the keys as a string slice. This function does not return
any values. Naturally, some state stores have better/more efficient
support for SQL LIKE style key queries.
Adds support for state stores:
Notes:
Both postgres v1 and v2 have a new migration to add a
row_idcolumn,which is a unique identifier for each row. This is used to page results
efficiently and consistently.
The in-memory store now tracks an internal id for each key/value pair to
allow consistent paging when keys are added/removed during listing.
MySQL also introduces a new
row_idcolumn in migration for the samepurpose.
A new state feature
FeatureKeysLikehas been added to signalKeysLikeAPI support.A conformance test has been added to test the
KeysLikeAPI for allsupported state stores.