Skip to content
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

chore: Bind Object Store bucket stream when getting object. #1568

Conversation

dmitryabramov-f3
Copy link
Contributor

The change is needed to properly operate on mirrored object store buckets. By binding stream nats.go does not need to search for stream by subjects (which does not work for mirrors).

Related issue: nats-io/nats-server#5106

@dmitryabramov-f3 dmitryabramov-f3 marked this pull request as draft February 26, 2024 15:07
@dmitryabramov-f3 dmitryabramov-f3 force-pushed the dabramov-bind-stream-when-getting-obj branch 3 times, most recently from 0648187 to c88ede9 Compare February 26, 2024 16:21
@dmitryabramov-f3 dmitryabramov-f3 marked this pull request as ready for review February 26, 2024 16:28
@dmitryabramov-f3 dmitryabramov-f3 force-pushed the dabramov-bind-stream-when-getting-obj branch from c88ede9 to 8dd5559 Compare February 26, 2024 17:13
Copy link
Collaborator

@piotrpio piotrpio left a comment

Choose a reason for hiding this comment

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

That's a great change, thanks! LGTM, just one nit.

Name: fmt.Sprintf("OBJ_%s", mirrorBucketName),
Mirror: &nats.StreamSource{
Name: fmt.Sprintf("OBJ_%s", bucketName),
//FilterSubject: fmt.Sprintf("$O.%s.>", bucketName),
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should be removed

Copy link
Contributor Author

@dmitryabramov-f3 dmitryabramov-f3 Feb 27, 2024

Choose a reason for hiding this comment

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

The change is needed to properly operate on mirrored object store buckets.
By binding stream nats.go does not need to search for stream by subjects (which does not work for mirrors).
@dmitryabramov-f3 dmitryabramov-f3 force-pushed the dabramov-bind-stream-when-getting-obj branch from 8dd5559 to dce3c36 Compare February 27, 2024 07:27
Copy link
Collaborator

@piotrpio piotrpio left a comment

Choose a reason for hiding this comment

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

LGTM!

@piotrpio piotrpio merged commit 21d3482 into nats-io:main Mar 3, 2024
1 check passed
@piotrpio piotrpio mentioned this pull request Mar 20, 2024
piotrpio pushed a commit that referenced this pull request Aug 15, 2024
The change is needed to properly operate on mirrored object store buckets.
By binding stream nats.go does not need to search for stream by subjects (which does not work for mirrors).
piotrpio pushed a commit that referenced this pull request Aug 15, 2024
The change is needed to properly operate on mirrored object store buckets.
By binding stream nats.go does not need to search for stream by subjects (which does not work for mirrors).
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