MCPcopy
hub / github.com/nats-io/nats.go / serverMinVersion

Method serverMinVersion

nats.go:2614–2620  ·  view source on GitHub ↗

Check for minimum server requirement.

(major, minor, patch int)

Source from the content-addressed store, hash-verified

2612
2613// Check for minimum server requirement.
2614func (nc *Conn) serverMinVersion(major, minor, patch int) bool {
2615 smajor, sminor, spatch, _ := versionComponents(nc.ConnectedServerVersion())
2616 if smajor < major || (smajor == major && sminor < minor) || (smajor == major && sminor == minor && spatch < patch) {
2617 return false
2618 }
2619 return true
2620}
2621
2622// ConnectedServerVersion reports the connected server's version as a string
2623func (nc *Conn) ConnectedServerVersion() string {

Callers 5

KeyValueMethod · 0.80
CreateKeyValueMethod · 0.80
CreateObjectStoreMethod · 0.80
ObjectStoreMethod · 0.80
upsertConsumerMethod · 0.80

Calls 2

versionComponentsFunction · 0.85

Tested by

no test coverage detected