build(deps): bump github.com/nats-io/nats.go from 1.42.0 to 1.43.0

Bumps [github.com/nats-io/nats.go](https://github.com/nats-io/nats.go) from 1.42.0 to 1.43.0.
- [Release notes](https://github.com/nats-io/nats.go/releases)
- [Commits](https://github.com/nats-io/nats.go/compare/v1.42.0...v1.43.0)

---
updated-dependencies:
- dependency-name: github.com/nats-io/nats.go
  dependency-version: 1.43.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
dependabot[bot]
2025-06-03 14:27:49 +00:00
committed by GitHub
parent 1c1e1a2d4e
commit 6864970e3f
6 changed files with 25 additions and 7 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ A [Go](http://golang.org) client for the [NATS messaging system](https://nats.io
go get github.com/nats-io/nats.go@latest
# To get a specific version:
go get github.com/nats-io/nats.go@v1.42.0
go get github.com/nats-io/nats.go@v1.43.0
# Note that the latest major version for NATS Server is v2:
go get github.com/nats-io/nats-server/v2@latest
+4 -1
View File
@@ -1051,7 +1051,10 @@ func (kv *kvs) WatchFiltered(keys []string, opts ...WatchOpt) (KeyWatcher, error
w.initPending = delta
}
if w.received > w.initPending || delta == 0 {
w.initDoneTimer.Stop()
// Avoid possible race setting up timer.
if w.initDoneTimer != nil {
w.initDoneTimer.Stop()
}
w.initDone = true
w.updates <- nil
} else if w.initDoneTimer != nil {
+16 -1
View File
@@ -47,7 +47,7 @@ import (
// Default Constants
const (
Version = "1.42.0"
Version = "1.43.0"
DefaultURL = "nats://127.0.0.1:4222"
DefaultPort = 4222
DefaultMaxReconnect = 60
@@ -2292,6 +2292,21 @@ func (nc *Conn) ConnectedAddr() string {
return nc.conn.RemoteAddr().String()
}
// LocalAddr returns the local network address of the connection
func (nc *Conn) LocalAddr() string {
if nc == nil {
return _EMPTY_
}
nc.mu.RLock()
defer nc.mu.RUnlock()
if nc.status != CONNECTED {
return _EMPTY_
}
return nc.conn.LocalAddr().String()
}
// ConnectedServerId reports the connected server's Id
func (nc *Conn) ConnectedServerId() string {
if nc == nil {