Skip to content

Add support for Direct Get API with key in subject#771

Merged
mtmk merged 2 commits into
mainfrom
kv-direct-get-api-subject-option
Mar 12, 2025
Merged

Add support for Direct Get API with key in subject#771
mtmk merged 2 commits into
mainfrom
kv-direct-get-api-subject-option

Conversation

@mtmk

@mtmk mtmk commented Mar 11, 2025

Copy link
Copy Markdown
Member

@garrett-sutton

Copy link
Copy Markdown
Contributor

@mtmk This is great. Thanks for hopping on it so quickly. This approach will work for our use case.

@garrett-sutton

Copy link
Copy Markdown
Contributor

potential for future

One additional piece that I had to think about for a little bit. In my use case's current state, we rely on the extensions that are defined in src/NATS.Client.KeyValueStore/NatsClientExtensions.cs to create an INatsKVContext . With the enhancements that are proposed as part of this PR we'll need to transition to setting up the INatsKVContext directly (rather than via the extension off of the INatsConnection).

Like I said in my other comment, I think the current proposal is good and we are OK with setting up the INatsKVConext directly though. This is largely just food for thought.

@mtmk

mtmk commented Mar 11, 2025

Copy link
Copy Markdown
Member Author

One additional piece that I had to think about for a little bit. In my use case's current state, we rely on the extensions that are defined in src/NATS.Client.KeyValueStore/NatsClientExtensions.cs to create an INatsKVContext . With the enhancements that are proposed as part of this PR we'll need to transition to setting up the INatsKVContext directly (rather than via the extension off of the INatsConnection).

@garrett-sutton that is a good point. I think we have a similar case for JetStream as well off the top of my head. I'll put that in a separate PR.

@scottf scottf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@mtmk
mtmk merged commit 077e342 into main Mar 12, 2025
@mtmk
mtmk deleted the kv-direct-get-api-subject-option branch March 12, 2025 13:58
mtmk added a commit that referenced this pull request Mar 12, 2025
* Add support for Direct Get API with key in subject (#771)
* Add Metadata to KV Bucket (#741)
* Added an ability to specify pool size with a callback using IServiceProvider (#757)
* Add NatsPayloadTooLargeException class (#761)
* Make the parameter-less StreamConfig constructor public (#768)
* Release 2.5.10-preview.1 (#766)
* Fix reconnect getting stuck (#758)
* Fix task tracking (#764)
* Fix Windows build (#765)
@mtmk mtmk mentioned this pull request Mar 12, 2025
mtmk added a commit that referenced this pull request Mar 12, 2025
* Add support for Direct Get API with key in subject (#771)
* Add Metadata to KV Bucket (#741)
* Added an ability to specify pool size with a callback using IServiceProvider (#757)
* Add NatsPayloadTooLargeException class (#761)
* Make the parameter-less StreamConfig constructor public (#768)
* Release 2.5.10-preview.1 (#766)
* Fix reconnect getting stuck (#758)
* Fix task tracking (#764)
* Fix Windows build (#765)
@mtmk mtmk added this to the v2.5.11 milestone Mar 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Subject in GetDirectAsync differs across client library implementations

3 participants