Skip to content

Conversation

@Gsantomaggio
Copy link
Member

@Gsantomaggio Gsantomaggio commented Apr 2, 2025

  • Reuse the locator connection. In this PR, the locator connection is always open ( like most other clients ) and can be reused. It is useful when API like storeOffset or queryOffest are often called. The maybeReconnectLocator function reconnects the locator if/when needed ( in case of network problem|)
  • Remove one heartbeat Ticket.
  • Fix an edge case during reconnection when the metadata fails
  • closes Reuse the locator connection #387
  • Fix a race condition for producer and consumer during the internal close. The internal close now has a cleanUp function

Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
add condition for the restart

Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
@Gsantomaggio Gsantomaggio requested a review from hiimjako April 7, 2025 07:26
Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
@Gsantomaggio Gsantomaggio marked this pull request as ready for review April 7, 2025 08:04
@Gsantomaggio Gsantomaggio changed the title resue the locator connection Reuse the locator connection Apr 7, 2025
hiimjako
hiimjako previously approved these changes Apr 8, 2025
Co-authored-by: Alberto Moretti <58828402+hiimjako@users.noreply.github.com>
Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
@Gsantomaggio Gsantomaggio merged commit 40d8931 into main Apr 8, 2025
4 checks passed
@Gsantomaggio Gsantomaggio deleted the reuse_locator branch April 8, 2025 12:21
hiimjako added a commit to hiimjako/rabbitmq-stream-go-client that referenced this pull request Jun 14, 2025
- Reuse the locator connection. In this PR, the locator connection is always open ( like most other clients ) and can be reused. It is useful when API like `storeOffset` or `queryOffest` are often called.  The `maybeReconnectLocator` function reconnects the locator if/when needed ( in case of network problem|)
- Remove one heartbeat Ticket. 
- Fix an edge case during reconnection when the [metadata fails](https://github.com/rabbitmq/rabbitmq-stream-go-client/pull/388/files#diff-329120e7df50ce65620d4fdf4ce9644909588f2369570cd94ff289b77f3aca2fR62-R66)
- closes rabbitmq#387   
- Fix a race condition for producer and consumer during the internal close. The internal close now has a [cleanUp function](https://github.com/rabbitmq/rabbitmq-stream-go-client/pull/388/files#diff-da66976f2cef8e369ba583aa16d59f1ea62f43c81eb4586e9d18badc4ed3a867L370-R373) 
---------

Signed-off-by: Gabriele Santomaggio <G.santomaggio@gmail.com>
Co-authored-by: Alberto Moretti <58828402+hiimjako@users.noreply.github.com>
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.

Reuse the locator connection

3 participants