Couchbase Go SDK Release Notes
Release notes, installation instructions, and download archive for the Couchbase Go Client.
These pages cover the 2.x versions of the Couchbase Go SDK (3.x SDK API). For release notes, download links, and installation methods for 1.6 and earlier releases of the Couchbase Go Client, please see the 1.x Go Release Notes & Download Archive.
SDK Installation
$ go get github.com/couchbase/gocb/v2@v2.9.2
In line with the Golang project, we support both the current, and the previous, versions of Go. Older versions may work, but are not supported. |
API Documentation
The most current and up to date API Documentation is always available through the godoc website.
Go SDK 2.9 Releases
We always recommend using the latest version of the SDK — it contains all of the latest security patches and support for new and upcoming features. All patch releases for each dot minor release should be API compatible, and safe to upgrade; any changes to expected behavior are noted in the release notes that follow.
Version 2.9.2 (25 September 2024)
Version 2.9.2 is a maintenance release for the Go SDK 2.9.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1632: Added support for zone-aware replica reads, at API stability level uncommitted.
-
GOCBC-1657: Updated tracing when using the
couchbase2
scheme, to send traces to the server over gRPC.
Fixed Issues
-
GOCBC-1655: Fixed the error messages for some connection string parameter parsing errors, where the message was not referring to the correct parameter.
-
GOCBC-1660: Fixed a possible data race that occured because the value of a lock was being logged at debug-level.
Version 2.9.1 (18 July 2024)
Version 2.9.1 is a maintenance release for the Go SDK 2.9.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1640: Adjusted logging levels when logging about receiving cluster configs older than the SDK already has.
Fixed Issues
-
GOCBC-1625: Fixed issue where a data race could occur when requests were retried concurrently with being cancelled.
-
GOCBC-1643: Fixed issue where couchbase2 mode did not wait for operations to complete on close.
Version 2.9.0 (18 June 2024)
Version 2.9.0 is the first release in the Go SDK 2.9 series.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1626: Addressed an issue where performing operations after calling cluster.Close (or calling close twice) would lead to a panic. On close the SDK will now cancel all in flight operations and block waiting for them to complete/be cancelled. All operations will now fast fail if called after close.
-
GOCBC-1631: Added handling to treat memcached scope not found errors the same as collection not found errors.
-
GOCBC-1634: Added support for base64 encoded vector queries.
-
GOCBC-1642: Moved vector search API support level to committed.
Fixed Issues
-
GOCBC-1625: Fixed issue where SDK could not receive large (> 4MB) documents in
couchbase2
mode. -
GOCBC-1636: Fixed issue where a race accessing config watchers could occur on agent close.
Go SDK 2.8 Releases
Version 2.8.1 (18 April 2024)
Version 2.8.1 is a maintenance release for the Go SDK 2.8.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1520: Added
MaxConcurrency
toScanOptions
at API stability level uncommitted. -
GOCBC-1578: Made port optional in connection string for
couchbase2
mode, now defaults to 18908. -
GOCBC-1615: Updated SCRAM client to relax some validation checks, in line with SCRAM RFC 7677.
-
GOCBC-1623: Added support for
Scope
level eventing functions at API stability level uncommitted.
Fixed Issues
-
GOCBC-1617: Fixed issue where service not available errors were not always retried in
couchbase2
mode. -
GOCBC-1617: Fixed issue where the degraded cluster target state for
WaitUntilReady
would check all services by default, rather than only those available on the cluster.
Version 2.8.0 (12 March 2024)
Version 2.8.0 is the first release in the Go SDK 2.8 series.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1577: Added support for vector search.
-
GOCBC-1578: Updated connection parsing to default to port 18098 if not specified when
couchbase2
scheme is used. -
GOCBC-1608: Return
ErrFeatureNotAvailable
if requested search capabilities aren’t available. -
GOCBC-1614: Updated SDK API volatility levels:
-
Moved Collection range scan to committed,
-
Moved Query read from replica to committed,
-
Moved LookupIn read from replica to committed,
-
Move Bucket History Retention Settings to committed,
-
Moved UserManager Change Password to committed,
-
Moved Scope level Search and SearchIndexes to committed,
-
Moved Vector Search to uncommitted.
-
Fixed Issues
-
GOCBC-1582: Fixed issue where
math.MaxUint32
was causing an error when used withfmt.Errorf
.
Breaking Fixes
-
GOCBC-1482: Fixed issue where there was inconsistency in whether Couchbase error types were returned as pointers across services, now all Couchbase errors are returned as pointers. Improved the string output for
TimeoutError
. We expect this to have a minimal impact but may impact some users who are usingerrors.As
or directly type asserting errors. -
GOCBC-1575: Improved the interface for
BucketSetting
HistoryRetentionCollectionDefault
field to use a constant value rather than a bool pointer.
Go SDK 2.7 Releases
Version 2.7.2 (20 February 2024)
Version 2.7.2 is a maintenance release for the Go SDK 2.7.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1470: Added a V2 Collection management API, accessed via
Bucket.CollectionsV2()
, which has improved method signatures forCreateCollection
,UpdateCollection
, andDropCollection
. -
GOCBC-1580: Exposed constants for the
unit
setting ofSearchSortGeoDistance
. -
GOCBC-1584: Added support for compressing data between the SDK and server in
couchbase2
mode. -
GOCBC-1585: Exposed non-idempotent requests that fail because of the socket closing while they are in-flight to the retry orchestrator (
SocketCloseInFlightRetryReason
retry reason). -
GOCBC-1590: Added support for
FlushBucket
incouchbase2
mode. -
GOCBC-1591: Added support for
Scope.Search()
andScope.SearchIndexes()
for querying and managing scoped search indexes.
Fixed Issues
-
GOCBC-1367: Fixed issue where
ExpiryTime
inGetResult
had the epoch value instead of zero time (time.Time{}
) when the document has no expiry. -
GOCBC-1599: Fixed issue where the
DropIndex
search management operation was not converting server errors to any of the known error values (e.g.ErrIndexNotFound
) where applicable.
Version 2.7.1 (17 January 2024)
Version 2.7.1 is a maintenance release for the Go SDK 2.7.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1494: Improvements to Query error handling. Added handling for some additional Query error codes.
-
GOCBC-1549: Added the ability to specify both positional and named parameters in queries.
-
GOCBC-1558: Added the
ErrDocumentNotLocked
error which is returned when KV responds with aNOT_LOCKED
status. -
GOCBC-1561: The SDK now displays the error description from the KV error map when an unknown KV status is received.
-
GOCBC-1579: Added support for
MaxExpiry
value of -1 ('No Expiry') in collection management operations. -
GOCBC-1560: Added support in the
couchbase2
mode for history retention settings in the bucket management API. -
GOCBC-1562: Added support for
UpdateCollection
in thecouchbase2
mode.
Fixed Issues
-
GOCBC-1573: Fixed issue where the SDK’s prepared query cache was not differentiating between queries which have the same statement but are in a different query context.
-
GOCBC-1581: Fixed issue where the partition counts in
SearchMetrics
were not populated. -
GOCBC-1588: Fixed issue with the
couchbase2
mode where Conjunction, Disjunction, and Boolean search queries always failed with an 'invalid query' error.
Version 2.7.0 (21 November 2023)
Version 2.7.0 is the first release in the Go SDK 2.7 series.
Tracing and metrics with the couchbase2
scheme should be considered stability level volatile at this time.
New Features and Behavioral Changes
-
GOCBC-1322: Added RangeScan support as API stability volatile.
-
GOCBC-1391: Deprecated the use of
CollectionName
andScopeName
for query index options blocks, usecollection.QueryIndexes()
instead. -
GOCBC-1394: Updated requests against HTTP APIs to always encode URIs.
-
GOCBC-1397: Added support for the
couchbase2://
protocol. -
GOCBC-1414: The SDK no longer works with Go versions below 1.19, due to versions enforced by dependencies.
-
GOCBC-1434: Added
LookupInAnyReplica
andLookupInAllReplicas
support as API stability volatile. -
GOCBC-1436: Added
UseReplica
toQueryOptions
as API stability uncommitted. -
GOCBC-1439: Added support for Config Push Negotiation and faster failover.
-
GOCBC-1454: Added support for JSON marshalling/unmarshalling of search indexes.
-
GOCBC-1457: Reduced the default timeout for idle HTTP connections to 1 second. The previous default (4.5 seconds) was too close to the 5-second server-side timeout, and could lead to spurious request failures
-
GOCBC-1459: Added support for history retention settings to bucket and collections managers, at API stability uncommitted.
-
GOCBC-1461: Updated
ExistsSpec
response to handleContentAt
better:-
Assign true if the path does exists
-
Assign false if the path does not exist
-
Return an error for all other statuses
-
-
GOCBC-1540: Added support for
ErrDocumentTooDeep
which is only used incouchbase2
mode, equivalent toErrPathTooDeep
.
Fixed Issues
-
GOCBC-1471: Fixed issue where calling
.Bucket
immediately after.Connect
could lead to the config poller failing to stop. -
GOCBC-1479: Fixed issue where a cluster config fetched as a part of bootstrap would be applied even if select bucket failed.
-
GOCBC-1460: Fixed issue where a path mismatch status code was not converted to
ErrPathMismatch
.
Breaking Fixes
-
GOCBC-1530: Fixed issue where
Append
andPrepend
could directly return agocbcore.ErrNotStored
error, this is now translated to agocb.ErrDocumentNotFound
error. -
GOCBC-1545: Fixed issue where
Projections
as a part of aGet
operation would return any path level errors, these are now silently ignored.
Go SDK 2.6 Releases
Version 2.6.5 (18 October 2023)
Version 2.6.5 is a maintenance release for the Go SDK 2.6.
New Features and Behavioral Changes
-
GOCBC-1489: Exposed
ErrCircuitBreakOpen
as API stability uncommitted.
Fixed Issues
-
GOCBC-1485: Fixed issue where operations queue for collection id refresh would not be dequeued on refresh.
-
GOCBC-1493: Fixed issue where key value operation transcoding errors would be swallowed by the SDK.
Version 2.6.4 (26 September 2023)
Version 2.6.4 is a maintenance release for the Go SDK 2.6.
New Features and Behavioral Changes
-
GOCBC-1479: Cluster configs fetched during bootstrap are now only applied if select bucket succeeds.
Version 2.6.3 (18 April 2023)
Version 2.6.3 is a maintenance release for the Go SDK 2.6.
New Features and Behavioral Changes
-
GOCBC-1403: Updated CCCP polling to start running on startup rather than waiting for memcached connections to fetch a cluster config.
Fixed Issues
-
GOCBC-1400: Fixed issue where connection string parsing was missing some timeout values.
-
GOCBC-1402: Fixed issue where wan-development config profile was missing some timeout values.
Version 2.6.2 (23 March 2023)
Version 2.6.2 is a maintenance release for the Go SDK 2.6.
New Features and Behavioral Changes
-
GOCBC-1392: Added support for
NumReplicas
to create (primary) index options. -
GOCBC-1393: Updated behaviour for when queries are retried when enhanced prepared statements are used (i.e. prepared statements against server version >= 6.5.0). When an error is translated to a
QueryPreparedStatementFailureRetryReason
it will invalidate the prepared statement cache entry and attempt to reprepare the statement. -
GOCBC-1395: Improved timeout error handling for http based services - if we know that an operation has already timed out then we will now immediately return a timeout error. Retry reason context is now carried throughout the lifetime of an entire prepared statement request.
Version 2.6.1 (22 February 2023)
Version 2.6.1 is a maintenance release for the Go SDK 2.6.
New Features and Behavioral Changes
-
GOCBC-1322: Added volatile support for kv range scan.
-
-
Added uncommitted support for
CollectionQueryIndexManager
. -
Added support for sending
query_context
whenScope
is set onTransactionQueryyOptions
. -
Added support for handling query error code 1197 as feature not available.
-
Fixed Issues
-
GOCBC-1376: Fixed issue where lost cleanup would log an incorrectly formatted log line, leading to spamming the log.
-
GOCBC-1387: Fixed issue where an edge case could trigger a race between releasing connection buffers and reading on the connection — leading to a panic.
Version 2.6.0 (20 October 2022)
Version 2.6.0 is the first release in the Go SDK 2.6 series.
New Features and Behavioral Changes
-
GOCBC-1159: Added support for refreshing the DNS SRV record when cluster becomes uncontactable, if applicable.
-
GOCBC-1284, GOCBC-1328, GOCBC-1331: Significant refactoring work to kv bootstrap, including pipelining fetching a config from the cluster.
-
GOCBC-1316: Added support for transactions
ExtInsertExisting
- allowingErrDocumentExists
to be be ignored in transactional inserts. -
GOCBC-1341: Added volatile level API support for
ConfigProfile
. -
GOCBC-1352: Added support for trusting the system cert store when TLS is enabled with no
CertPool
registered andSkipVerify
not set. -
GOCBC-1356: Updated the behaviour when
MutateIn
orInsert
returnsNOT_STORED
from the server to return aErrDocumentExists
.
Fixed Issues
-
GOCBC-1347: Fixed issue where a nil agent value could cause logging
TransactionATRLocation
to log a panic. -
GOCBC-1348: Fixed issue where a race on creating a client record could lead to a panic.
Go SDK 2.5 Releases
Version 2.5.4 (27 October 2022)
Version 2.5.4 is a maintenance release for the Go SDK 2.5.
Fixed Issues
-
GOCBC-1347: Fixed issue where a nil agent value could cause logging
TransactionATRLocation
to log a panic. -
GOCBC-1348: Fixed issue where a race on creating a client record could lead to a panic.
Version 2.5.3 (21 September 2022)
Version 2.5.3 is a maintenance release for the Go SDK 2.5.
Fixed Issues
-
GOCBC-1338: Fixed issue where
lazyCircuitBreaker
was not using 64-bit aligned values.
Known Issues
-
GOCBC-1347: Known issue where a nil agent value could cause logging
TransactionATRLocation
to log a panic. -
GOCBC-1348: Known issue where a race on creating a client record can lead to a panic.
Version 2.5.2 (20 July 2022)
Version 2.5.2 is a maintenance release for the Go SDK 2.5.
New Features and Behavioral Changes
-
GOCBC-1246: Added uncomitted stability support for
TransactionLogger
toTransactionResult
. -
GOCBC-1314: Improved logging in the lost transactions process.
-
GOCBC-1318: Changed
WaitUntilReady
to always wait for any explicitly defined services to be online.
Fixed Issues
-
GOCBC-1320: Fixed issue where vbucket hashing function wasn’t masking out the 16th bit of the key.
Version 2.5.1 (22 June 2022)
Version 2.5.1 is a maintenance release for the Go SDK 2.5.
New Features and Behavioral Changes
-
GOCBC-1159: Improved support for serverless environments.
-
GOCBC-1250: Added support for single query transactions via
QueryOptions
AsTransaction
. -
GOCBC-1298: Masked the underlying error reason for
TransactionOperationFailedError
. -
GOCBC-1213: Added uncommitted API level support for
UserManager
ChangePassword
.
Fixed Issues
-
GOCBC-1300: Fixed issue where transactions lost cleanup would not remove deleted collections from the cleanup list.
-
GOCBC-1304: Fixed issue where transactions lost cleanup could temporarily block further responses being processed for a connection.
Version 2.5.0 (28 April 2022)
Version 2.5.0 is the first release in the Go SDK 2.5 series.
New Features and Behavioral Changes
-
GOCBC-1125: Deprecated
Cas
on Binary Append and Prepend as the server does not support this. Usage ofCas
on these operations will now return an error. -
GOCBC-1203: Added
CompressionOptions
toClusterOptions
, defaulting to compression being enabled. -
GOCBC-1255: Deprecated
AggregatingMeterOptions
andNewAggregatingMeter
. -
GOCBC-1265: Bundle Capella CA certificate with the SDK.
-
TXNG-1253: Removed
ServerDurationDisabled
fromThresholdLoggingOptions
.
Fixed Issues
-
GOCBC-1267: Fixed issue where
GetAllIndexes
could incorrectly omit the default collection.
Go SDK 2.4 Releases
Version 2.4.1 (16 March 2022)
Version 2.4.1 is a maintenance release for the Go SDK 2.4.0.
New Features and Behavioral Changes
-
GOCBC-1221: Added support for handling any
retry:true
field in a query error result by retrying it. -
GOCBC-1228: Updated the query used within
BuildDeferredIndexes
inQueryIndexManager
. -
GOCBC-1244: Updated SDK dependencies.
-
GOCBC-1254: Added
NewLoggingMeter
andLoggingMeterOptions
for creating theLoggingMeter
.AggregatingMeterOptions
andNewAggregatingMeter
will be deprecated in the next dot minor release.
Fixed Issues
-
GOCBC-1248: Fixed issue where a hard close of a memdclient during a graceful close could trigger a panic.
-
GOCBC-1251: Fixed issue where
SearchOptions
ConsistentWith
was using an incorrect key within the JSON payload. -
GOCBC-1256: Fixed issue where config polling could fallback to using the http poller, when no http addresses are registered for use.
-
GOCBC-1258: Fixed issue where log redaction tags were not closed correctly.
Version 2.4.0 (16 February 2022)
Version 2.4.0 is the first release in the Go SDK 2.4 series, adding multi-document distributed ACID transactions.
New Features and Behavioral Changes
-
GOCBC-1172: Added uncommitted API stability support for Query option
PreserveExpiry
. -
GOCBC-1176: Added uncommitted API stability support for collections to query index manager.
-
GOCBC-1239: Added
DurabilityLevelUnknown
as default durability level. -
TXNG-127: Integrated transactions into the SDK.
Fixed Issues
-
GOCBC-1240: Fixed issue where
MutateIn
was not setting durability level.
Go SDK 2.3 Releases
Version 2.3.5 (14 December 2021)
Version 2.3.5 is a maintenance release for the Go SDK 2.3.0.
New Features and Behavioral Changes
-
GOCBC-1152: Added uncommitted API stability support for custom conflict resolution to
BucketSettings
. -
GOCBC-1156; Added volatile API stability support for
includeLocations
toSearchOptions
andOperator
to searchMatchQuery
. -
GOCBC-1175: Added uncommitted API stability support for
storageBackend
toBucketSettings
. -
GOCBC-1196: Added the
ErrorText
of the response body field toAnalyticsError
,SearchError
,ManagementError
, andViewError
, to allow easier debugging and error handling. Renamed theResponseBody
of theQueryError
to beErrorText
and contain only the error text. Added theStatusCode
of the response toAnalyticsError
,QueryError
,ManagementError
, andViewError
. -
GOCBC-1200: Renamed
ErrRateLimiting
andErrQuotaLimiting
toErrRateLimited
andErrQuotaLimited
. Note: this is a breaking change, it not expected to impact any users.
Fixed Issues
-
GOCBC-1211: Fixed issues relating to rate limit error message parsing.
-
GOCBC-1210: Fixed issue where a quota limit error was returned rather than rate limit error for key value response status code 0x32.
Version 2.3.4 (16 November 2021)
Version 2.3.4 is a maintenance release for the Go SDK 2.3.0.
New Features and Behavioral Changes
-
GOCBC-1179: Added support to attempt graceful closing of connections.
-
GOCBC-1154; GOCBC-1184: Added RateLimitFailure and QuotaLimitFailure support for Couchbase Capella.
-
GOCBC-1193: Added the ResponseBody field to QueryError, to allow easier debugging and error handling.
Fixed Issues
-
GOCBC-1185: Fixed an issue with Queue and Set retrying during pop and remove operations.
-
GOCBC-1186: Fixed issue where logging meter could cause a deadlock on closing the cluster object.
-
GOCBC-1187: Fixed issue where logging meter could log a service/operation pair which has no operations.
-
GOCBC-1194: Changed ordering of route config bootstrapping, to check all seed nodes for the default network type first. This fixed an issue with stuck deployments using the Eventing service, after upgrade to server 7.0.2.
Version 2.3.3 (19 October 2021)
Version 2.3.3 is a maintenance release for the Go SDK 2.3.0.
New Features and Behavioral Changes
-
GOCBC-1178: We no longer remove poller controller watcher from cluster config updates.
Fixed Issues
-
GOCBC-1177: Fixed issue where a connection being closed by the server during bootstrap could cause the SDK to loop reconnect without backoff.
-
GOCBC-1183: Fixed issue where SSL certificates were be not verified when no root CAs were provided.
Version 2.3.2 (21 September 2021)
Version 2.3.2 is a maintenance release for the Go SDK 2.3.0.
New Features and Behavioral Changes
-
GOCBC-1009: Add support for Eventing function management.
-
GOCBC-1166: Check error codes and fallback to parsing messages in query index management.
Fixed Issues
-
GOCBC-1168: Fixed issue where cluster level HTTP operations could hang indefinitely.
-
GOCBC-1170: Fixed issue where Search
ScanConsistency
was sending an incorrect value forNotBounded
.
Version 2.3.1 (17 August 2021)
Version 2.3.1 is a maintenance release for the Go SDK 2.3.0.
Fixed Issues
-
GOCBC-1140: Fixed issue where
ViewOptions
would return an error when usinggroup_level
. -
GOCBC-1144: Added missing
min
function toDisjunction
search query. -
GOCBC-1147: Fixed issue where an error occuring whilst fetching the error map during bootstrap could cause an indefinite hang.
-
GOCBC-1149: Fixed issue where
GetAllScopes
would panic on HTTP request send failure.
Go SDK 2.2 Releases
Version 2.2.5 (17 August 2021)
Version 2.2.5 is a maintenance release for the Go SDK 2.2.0.
Fixed Issues
-
GOCBC-1147: Fixed issue where an error occuring whilst fetching the error map during bootstrap could cause an indefinite hang.
-
GOCBC-1149: Fixed issue where
GetAllScopes
would panic on HTTP request send failure.
Version 2.3.0 (15 July 2021)
Version 2.3.0 is the first release in the Go SDK 2.3 series.
New Features and Behavioral Changes
-
GOCBC-935: Added support for Analytics remote and external link management.
-
GOCBC-936: Added support for compound dataverse names to Analytics management.
-
GOCBC-1096: Updated the tracing interface, and made it API stability level committed.
-
GOCBC-1037: Added support for
PreserveExpiry
option to key value operations. -
GOCBC-1044: Added support for meter interface, and default
LoggingMeter
implementation. -
GOCBC-1063: Added uncommitted support for
context.Context
to options blocks. -
GOCBC-1077: Updated errors returned on Query error code return of 12009.
-
GOCBC-1130: Updated Query error handling to return an authentication error on error code 13104.
Fixed Issues
-
GOCBC-1095: Fixed issue where View error contents were being parsed incorrectly.
-
GOCBC-1100: Fixed issue where the Search metrics
took
field was being parsed incorrectly. -
GOCBC-1106: Fixed issue where a Search response containing a
hits
field but the field beingnull
would lead to an error. -
GOCBC-1111: Fixed issue where any errors returned from the Search service were not being propagated through the SDK.
-
GOCBC-1127: Fixed issue where Query errors were sometimes not being parsed correctly.
-
GOCBC-1132: Fixed issue where benchmarks would not compile.
Version 2.2.4 (15 June 2021)
Version 2.2.4 is a maintenance release for the Go SDK 2.2.0.
Fixed Issues
-
GOCBC-1095: Fixed issue where errors returned from views was parsed incorrectly.
-
GOCBC-1102: Fixed issue where
WaitUntilReady
would never recover if one of the HTTP based services returned an error. -
GOCBC-1106: Fixed issue where
hits
beingnull
in a search response would leave to an internal error. -
GOCBC-1111; GOCBC-1112: Fixed issue where parsing search errors was using the incorrect field.
-
GOCBC-1100: Fixed issue where the
took
field in search metrics was parsed incorrectly.
Version 2.2.3 (20 April 2021)
Version 2.2.3 is a maintenance release for the Go SDK 2.2.0.
New Features and Behavioral Changes
-
GOCBC-1071: Updated SDK to use new protocol level changes for get collection id.
-
GOCBC-1068: Dropped log level to warn for when applying a cluster config object is preempted.
-
GOCBC-1079: During bootstrap don’t retry authentication if the error is request cancelled.
-
GOCBC-1081: During CCCP polling don’t retry request if the error is request cancelled.
Fixed Issues
-
GOCBC-1074: Fixed issue where threshold log tracer was missing fields in log output.
-
GOCBC-1080: Fixed issue where SDK would always rebuild connections on first cluster config fetched against server 7.0.
-
GOCBC-1082: Fixed issue where bootstrapping a node during an SDK wide reconnect would cause a delay in connecting to that node.
-
GOCBC-1088: Fixed issue where the poller controller could deadlock if a node reported a bucket not found at the same time as CCCP successfully fetched a cluster config for the first time.
Version 2.2.2 (16 March 2021)
Version 2.2.2 is a maintenance release for the Go SDK 2.2.0.
New Features and Behavioral Changes
-
GOCBC-1010: Added uncommitted support for collections to
SearchOptions
. -
GOCBC-1024: Added partition information to
QueryIndex
. -
GOCBC-1056: Various performance enhancements to improve CPU usage.
-
GOCBC-1068: Dropped log level to warn for when applying a cluster config object is preempted.
Fixed Issues
-
GOCBC-1070: Fixed issue where
BucketManager
FlushBucket
didn’t returnErrBucketNotFound
when the bucket doesn’t exist. -
GOCBC-1066: Fixed issue where shutting down cluster config polling could lead to a panic.
Version 2.2.1 (16 February 2021)
Version 2.2.1 is a maintenance release for the Go SDK 2.2.0.
New Features and Behavioral Changes
-
GOCBC-1017: Updated server endpoints for collections manager.
-
GOCBC-1040: Updated json serialization of errors to include the underlying cause.
-
GOCBC-1054: Updated
MutateIn
to allow a blank path withRemoveSpec
.
Fixed Issues
-
GOCBC-1047: Fixed issue where
GetAllScopes
was not setting the max expiry value for any collections. -
GOCBC-1052: Fixed issue where
GetAllDesignDocuments
was ignoring the providednamespace
. -
GOCBC-1061: Fixed issue where an extra, empty, origin was added to user roles on fetching the user.
Version 2.2.0 (15 December 2020)
Version 2.2.0 is the first release in the Go SDK 2.2 series. It brings enhancements and bug fixes over 2.1.8, and improves compatibility with Server 6.6 and with 7.0β.
New Features and Behavioral Changes
-
GOCBC-869:
BucketSettings
MaxTTL
field deprecated in favour ofMaxExpiry
. -
GOCBC-934: Added support for bucket level durability settings in
BucketManager
. -
GOCBC-948: Changed document expiry durations so that expiry lengths of > 30 days sent as unix timestamps (now + expiry).
-
GOCBC-934: Added support for bucket level durability settings in
BucketManager
. -
GOCBC-963:
GetResult
Expiry
function deprecated in favour ofExpiryTime
. -
GOCBC-972: Added support for
Score
toSearchOptions
. -
GOCBC-1014: Updated search
GeoPolygon
support to API stability committed. -
GOCBC-1015: Updated
QueryOptions
FlexIndex
support to API stability committed. -
GOCBC-1026: Updated
BucketSettings
ephemeral eviction policies support to API stability committed.
Fixed Issues
-
GOCBC-1022: Fixed issue where having multiple buckets open could cause view requests to be sent to an incorrect bucket.
-
GOCBC-1021: Fixed issue where having multiple buckets open could cause view manager requests to be sent to an incorrect bucket.
-
GOCBC-1028: Fixed issue where bootstrapping against a non-kv node could never successfully fully connect.
Go SDK 2.1 Releases
Version 2.1.8 (17 November 2020)
Version 2.1.8 is a maintenance release for the Go SDK 2.1.0.
New Features and Behavioral Changes
-
GOCBC-937: Added uncommitted support for
GeoPolygon
search queries. -
GOCBC-1005: Added document id to key value errors.
-
GOCBC-1006: Changed the log level for retry strategy retries from info to debug.
Fixed Issues
-
GOCBC-1007: Fixed issue some operations were being incorrectly sent to the retry orchestrator on errors.
Version 2.1.7 (20 October 2020)
Version 2.1.7 is a maintenance release for the Go SDK 2.1.0.
New Features and Behavioral Changes
-
GOCBC-938: Added uncommitted support for
FlexIndex
toQueryOptions
. -
GOCBC-942: Added uncommitted support for
Scope
level queries. -
GOCBC-944: Added uncommitted support for
Scope
level analytics queries. -
GOCBC-944: Added uncommitted support for
User
collections level RBAC. -
GOCBC-994: Fixed issue where nil values used in subdoc
MutateIn
operations would be rejected by the server. These values are now coerced into JSONnull
values before sending. -
GOCBC-1001: Added missing
Terms
,DateRanges
, andNumericRanges
fields toSearchFacetResult
.
Fixed Issues
-
GOCBC-977: Fixed issue where analytics
GetPendingMutations
was looking for the incorrect data structure in the HTTP response body. -
GOCBC-990: Fixed issue where enhanced durability timeout adaptive algorithm was incorrect.
-
GOCBC-991: Fixed issue where authentication mechanisms were not correctly iterated on bootstrap.
-
GOCBC-996: Fixed issue where the
Map
datastructure was using invalid paths forAt
andExists
.
Version 2.1.6 (15 September 2020)
Version 2.1.6 is a maintenance release for the Go SDK 2.1.0.
New Features and Behavioral Changes
-
GOCBC-979: Add ExpiryTime to GetResult, providing the point in time at which a document will expire.
Fixed Issues
-
GOCBC-969: Fixed issue where the SDK would attempt to parse query metrics even if they weren’t present.
-
GOCBC-976: Fixed issue where custom transcoders were not supported for performing a get request with expiry.
-
GOCBC-978: Fixed issue where it was possible for more than one request to trigger switching from unknown to pending state for a given collection.
-
GOCBC-981: Fixed issue where setting the
network
connection string property todefault
would be discarded.
Version 2.1.5 (18 August 2020)
Version 2.1.5 is a maintenance release for the Go SDK 2.1.0.
New Features and Behavioral Changes
-
GOCBC-926: Added a new
Cluster
level option to set which authentication mechanisms to use. -
GOCBC-962: Exposed the
ThresholdLogTracer
and corresponding options so that threshold logging can be configured. The threshold logger can then be set on theCluster
level options asTracer
. Note: The threshold logger is the default tracer used by the SDK.
Fixed Issues
-
GOCBC-718: Fixed issue where errors would be silently swallwed when performing JSON unmarshalling of search and view queries. Unmarshalling errors will now be surfaced by the
result.Err()
function after iterating results. -
GOCBC-950: Fixed issue where the SDK was not performing HELLO with the JSON feature enabled, leading to some KV error message context being lost.
-
GOCBC-968: Fixed issue where n1ql indexes were being created using prepared statements.
Version 2.1.4 (21 July 2020)
Version 2.1.4 is a maintenance release for the Go SDK 2.1.0.
Fixed Issues
-
GOCBC-925: Fixed issue where errors could not be accessed for queries responding with a HTTP 200 status code but containing errors. Any errors that are included in the query response when the status code is 200 will now be surfaced through the result
Err
call. -
GOCBC-928: Fixed issue where enhanced durability could be incorrectly flagged as unsupported.
-
GOCBC-931: Fixed issue where enhanced durability timeouts were being sent as seconds rather than milliseconds.
-
GOCBC-945: Fixed issue where ephemeral buckets could not be created using the
BucketManager
. -
GOCBC-946: Fixed issue where
MaxTTL
was being sent as nanoseconds rather than seconds when creating buckets using theBucketManager
. -
GOCBC-955: Fixed issue where xattrs were being reordered when being moved to the front of the list in subdoc operations.
Version 2.1.3 (1 July 2020)
Version 2.1.3 is an off-cadence release for the Go SDK 2.1.0.
Fixed Issues
-
GOCBC-941: Fixed issue where
WaitUntilReady
at theCluster
level would always timeout.
Version 2.1.2 (16 June 2020)
Version 2.1.2 is a maintenance release for the Go SDK 2.1.0.
Fixed Issues
-
GOCBC-879, GOCBC-890: Fixed issue causing
Cluster
level operations to return errors when performed before underlying cluster or bucket connections are ready. These operations (query, search, analytics, views, management APIs) will now behave like key value operations - waiting for connections to be ready before they are sent. TheWaitUntilReady
call can still be used for verifying that connections are ready. -
GOCBC-891: Fixed issue where the
Name
property of aRole
was being sent as the incorrect json field name. -
GOCBC-897: Fixed issue where operations with incredible short timeouts (timing out before operation sent) could cause a data race.
-
GOCBC-900: Fixed issue where
IgnoreIfExists
option was being ignored for query index management. -
GOCBC-906: Fixed issue where enhanced durability could be incorrectly set as unsupported on early operations.
-
GOCBC-914: Fixed issue where operations using named collections could be sent with an incorrect collection ID in queued before the collection is known.
Known issues
-
GOCBC-941: Performing
Cluster
levelWaitUntilReady
never completes within the timeout. This issue was introduced whilst fixing the behaviour for operations at theCluster
level when theWaitUntilReady
call is not used. The workaround for this is to not use theCluster
levelWaitUntilReady
call,Cluster
level operations will now be queued until the SDK has connected and setup anyway.
Version 2.1.1 (19 May 2020)
Version 2.1.1 is a maintenance release for the Go SDK 2.1.0.
New Features and Behavioral Changes
-
GOCBC-778: Updated legacy durability polling to use a backoff rather than a fixed interval.
-
GOCBC-824: Enhanced timeout errors to contain more information and match up with the Response Time Observability RFC.
-
GOCBC-828: Added
MaxExpiry
to theCollectionSpec
. -
GOCBC-870: Updated
GetAllIndexes
to only fetch GSI indexes. -
GOCBC-884: Improved logging to always log the cluster config when fetched.
-
GOCBC-888: Re-enabled HTTP dispatch traces.
Fixed Issues
-
GOCBC-691: Fixed issue where operations on unknown collections (when using 6.5 developer preview) are not automatically retried.
-
GOCBC-757: Fixed issue where an array of arrays could cause a failure when using
Get
withProjections
. -
GOCBC-882: Fixed issue where an invalid cluster config would trigger a shutdown of the underlying core SDK causing operations to fail.
-
GOCBC-884: Fixed issue where
UpsertUser
sent an invalid request if a role was specified with no bucket.
Known issues
-
GOCBC-879, GOCBC-890: Performing
Cluster
level operations (query, search, management APIs) before underlying cluster or bucket connections are ready causes errors to be returned. To mitigate this theerr := WaitUntilReady(time.Duration, WaitUntilReadyOptions)
operation can be used on eitherCluster
orBucket
which will either:-
Return no error if connections are setup and ready for use
-
Return a
TimeoutError
if connections are not ready within the specified time limit.
-
Go SDK 2.0 Releases
Version 2.0.4 (21 April 2020)
Version 2.0.4 is a maintenance release for the Go SDK 2.0.0.
New Features and Behavioral Changes
-
GOCBC-844: Updated to the latest version of gocbconnstr.
Fixed Issues
-
GOCBC-838: Fixed issue where HTTP endpoints were being used when SSL is enabled.
-
GOCBC-851: Fixed issue where
ServerName
was not being set on thetls.Config
when SSL was use. -
GOCBC-853: Fixed issue where using
PasswordAuthenticator
with a root CA and SSL would cause a panic. -
GOCBC-831: Fixed issue where search consistency options were not being set in the request payload.
Version 2.0.3 (17 March 2020)
Version 2.0.3 is a maintenance release for the Go SDK 2.0.0.
New Features and Behavioral Changes
-
GOCBC-662: The server requires that any subdoc xattr ops are at the beginning of the ops list. If the user provides an ops list containing subdoc xattr ops out of order, the SDK will now reorder it for them and then reorder it back again when it gets the result. This ensures that
ContentAt
works as expected. -
GOCBC-700: Made improvements to errors returned from management operations. They now provide more contextual information.
-
GOCBC-716: SDK now returns a
FlushNotEnabled
error if bucket flush not enabled. -
GOCBC-719: SDK now consistently creates tracing spans for all HTTP requests.
-
GOCBC-728: Added cluster level Ping operation.
-
GOCBC-807: Updated best effort retry strategy to use an exponential backoff calculator.
-
GOCBC-820: Removed
context.Context
from search index manager operations. Note that whilst this is a breaking change it was deemed best to break it and make sure any users who are using it know that they are using unused functionality.
Version 2.0.2 (21 February 2020)
Version 2.0.2 is an off-cycle release for the Go SDK 2.0.0.
New Features and Behavioral Changes
-
GOCBC-805: Updated timeout behavior across the SDK to be consistent. If an operation level timeout is provided then it is used, otherwise the respective global timeout is used.
Fixed Issues
-
GOCBC-804: Fixed issue with timeouts not being respected for HTTP requests, leading to them never timing out.
Version 2.0.1 (19 February 2020)
Version 2.0.1 is a maintenance release for the Go SDK 2.0.0.
Fixed Issues
-
GOCBC-701: Fixed issue with enhanced prepared statements not being used.
-
GOCBC-702: Fixed issue with CA root certificates not being able to be provided.
-
GOCBC-759: Fixed issue with streaming results for HTTP based services timing out unexpectedly.
-
GOCBC-772: Fixed issue with many of the management API functions timing out immediately.
-
GOCBC-773: Fixed issue with queries that do not return rows (e.g. mutations) causing errors.
-
GOCBC-777: Fixed issue with failing operations causing nil pointers.
-
GOCBC-783: Fixed issue with Exists returning incorrectly if the document was recently deleted.
-
GOCBC-784: Fixed issue with Unlock returning a doc not found error instead of cas mismatch.
-
GOCBC-787: Fixed issue with some (xattr related) subdoc operations sending invalid packets.
-
GOCBC-789: Fixed issue with search index manager FreezePlan function using an invalid HTTP method.
-
GOCBC-790: Fixed issue with user manager sometimes parsing user role origins incorrectly.
-
GOCBC-796: Fixed issue with cccp poller hanging if the get cluster config op timed out.
Version 2.0.0 (18 January 2020)
Version 2.0.0 is the first release for the Go SDK 2.0.0.
New Features and Behavioral Changes
-
GOCBC-510: Dropped support for connecting using the http scheme.
-
GOCBC-534: Added support for retry handling.
-
GOCBC-652: Added support for circuit breakers.
-
GOCBC-655: Added support for enhanced timeout errors providing more information about operations which timeout.
-
GOCBC-656: Added support for threshold logging tracer.
-
GOCBC-680: Updated how we expose and handle errors.
-
GOCBC-694: A large number of updates including: How query and analytics results are iterated. Minor renaming of various types. Moving search facets, sorting, and queries to a search subpackage. Removing serializers.
-
GOCBC-740: Updated expiry options to be
time.Duration
. -
GOCBC-760: Moved authenticator to ClusterOptions.
Pre-releases
Numerous Alpha and Beta releases were made in the run-up to the 2.0 release, and although unsupported, the release notes and download links are retained for archive purposes here.
Older Releases
Although no longer supported, documentation for older releases continues to be available in our docs archive.