Uploaded image for project: 'Couchbase .NET client library'
  1. Couchbase .NET client library
  2. NCBC-3772

Cluster config maps are reaching BucketBase.CurrentConfig, affecting scope/collection capabilities

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 3.5.2
    • 3.5.1
    • library
    • None
    • 0

    Description

      Since upgrading from SDK 3.4.15 to 3.5.1 we are noticing intermittent failures in our integration tests that use scopes/collections. Research indicates that BucketBase.CurrentConfig contains an incorrect configuration with an empty list of bucket capabilities. It seems to get configuration for incorrect bucket. This, in turn, causes the SDK to believe that scopes/collections are not supported and all ops against a non-default collection fail with CollectionNotFound and eventually timeout.

      Note that operations against the default scope/collection appear to be unaffected.

      This log shows that the name of the config on BucketBase.CurrentConfig for the "primary" bucket just before the failures is "CLUSTER":

      {"@t":"2024-04-25T16:04:01.1200243Z","@mt":"Bucket {bucket} config: {config}","@l":"Warning","@tr":"13a0f86236a12e43590151e518fe5edb","@sp":"83ee4fa66a2794dd","bucket":"primary","config":"{\"ConfigVersion\":{\"Epoch\":1,\"Revision\":92},\"NetworkResolution\":\"default\",\"rev\":92,\"revEpoch\":1,\"name\":\"CLUSTER\",\"uri\":null,\"streamingUri\":null,\"nodes\":[],\"nodesExt\":[{\"thisNode\":true,\"services\":{\"mgmt\":8091,\"mgmtSSL\":18091,\"indexAdmin\":9100,\"indexScan\":9101,\"indexHttp\":9102,\"indexStreamInit\":9103,\"indexStreamCatchup\":9104,\"indexStreamMaint\":9105,\"indexHttps\":19102,\"kv\":11210,\"kvSSL\":11207,\"capi\":8092,\"capiSSL\":18092,\"projector\":9999,\"n1ql\":8093,\"n1qlSSL\":18093,\"cbas\":0,\"cbasSSL\":0,\"fts\":8094,\"ftsSSL\":18094,\"moxi\":0,\"eventingAdminPort\":0,\"eventingSSL\":0},\"hostname\":\"couchbase\",\"alternateAddresses\":null,\"HasAlternateAddress\":false}],\"nodeLocator\":null,\"uuid\":null,\"ddocs\":null,\"vBucketServerMap\":{\"hashAlgorithm\":\"\",\"numReplicas\":0,\"serverList\":[],\"vBucketMap\":[],\"vBucketMapForward\":[]},\"bucketCapabilitiesVer\":null,\"bucketCapabilities\":[],\"clusterCapabilitiesVer\":[1,0],\"clusterCapabilities\":{\"n1ql\":[\"enhancedPreparedStatements\"]},\"UseAlternateAddresses\":false}","SourceContext":"Phoenix.Service.Payments.Controllers.DefaultMerchantAccountsController","ActionId":"c864f6aa-7cf3-426b-845c-349880cc08bd","ActionName":"Phoenix.Service.Payments.Controllers.DefaultMerchantAccountsController.UpdateDefaultMerchantAccounts (Phoenix.Service.Payments)","RequestId":"0HN35828A2QQ8:00000001","RequestPath":"/businessEntities/866/merchantAccounts/defaults","ConnectionId":"0HN35828A2QQ8","cid":"0HN35828A2QQ8:00000001"}

      In other cases the tests don't fail, but we've seen it appear to show the config for the incorrect bucket ("cache") in BucketBase.CurrentConfig. In this case we do show scope/collection support so things work, but I'm not sure what other side effects this could have (especially on a multi-node cluster):

      {"@t":"2024-04-25T15:10:24.9904358Z","@mt":"Bucket config: {config}","@l":"Warning","@tr":"0d27dc2b24ebdf41cefb65eee04ac347","@sp":"82bab26f5991e113","config":"{\"ConfigVersion\":{\"Epoch\":1,\"Revision\":92},\"NetworkResolution\":\"default\",\"rev\":92,\"revEpoch\":1,\"name\":\"cache\",\"uri\":\"/pools/default/buckets/cache?bucket_uuid=2e1877d2ed636d4e56812c60c91089ec\",\"streamingUri\":\"/pools/default/bucketsStreaming/cache?bucket_uuid=2e1877d2ed636d4e56812c60c91089ec\",\"nodes\":[{\"couchApiBase\":\"http://$HOST:8092/cache%2B2e1877d2ed636d4e56812c60c91089ec\",\"couchApiBaseHttps\":\"https://$HOST:18092/default\",\"hostname\":\"couchbase:8091\",\"ports\":{\"direct\":11210,\"proxy\":0,\"sslDirect\":0,\"httpsCAPI\":0,\"httpsMgmt\":0},\"services\":null,\"version\":null}],\"nodesExt\":[{\"thisNode\":true,\"services\":{\"mgmt\":8091,\"mgmtSSL\":18091,\"indexAdmin\":9100,\"indexScan\":9101,\"indexHttp\":9102,\"indexStreamInit\":9103,\"indexStreamCatchup\":9104,\"indexStreamMaint\":9105,\"indexHttps\":19102,\"kv\":11210,\"kvSSL\":11207,\"capi\":8092,\"capiSSL\":18092,\"projector\":9999,\"n1ql\":8093,\"n1qlSSL\":18093,\"cbas\":0,\"cbasSSL\":0,\"fts\":8094,\"ftsSSL\":18094,\"moxi\":0,\"eventingAdminPort\":0,\"eventingSSL\":0},\"hostname\":\"couchbase\",\"alternateAddresses\":null,\"HasAlternateAddress\":false}],\"nodeLocator\":\"vbucket\",\"uuid\":\"2e1877d2ed636d4e56812c60c91089ec\",\"ddocs\":null,\"vBucketServerMap\":{\"hashAlgorithm\":\"CRC\",\"numReplicas\":0,\"serverList\":[\"couchbase:11210\"],\"vBucketMap\":[[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0],[0]],\"vBucketMapForward\":[]},\"bucketCapabilitiesVer\":\"\",\"bucketCapabilities\":[\"collections\",\"durableWrite\",\"tombstonedUserXAttrs\",\"subdoc.ReplaceBodyWithXattr\",\"subdoc.DocumentMacroSupport\",\"subdoc.ReviveDocument\",\"dcp.IgnorePurgedTombstones\",\"dcp\",\"cbhello\",\"touch\",\"cccp\",\"xdcrCheckpointing\",\"nodesExt\",\"xattr\"],\"clusterCapabilitiesVer\":[1,0],\"clusterCapabilities\":{\"n1ql\":[\"enhancedPreparedStatements\"]},\"UseAlternateAddresses\":false}","SourceContext":"Phoenix.Service.Payments.Controllers.DefaultMerchantAccountsController","ActionId":"e59a4a28-d7fe-43a9-9a9a-bace6cab1930","ActionName":"Phoenix.Service.Payments.Controllers.DefaultMerchantAccountsController.UpdateDefaultMerchantAccounts (Phoenix.Service.Payments)","RequestId":"0HN35748CJUGP:00000001","RequestPath":"/businessEntities/866/merchantAccounts/defaults","ConnectionId":"0HN35748CJUGP","cid":"0HN35748CJUGP:00000001"}

      I've attached more complete logs as well. You can search in the logs for "Supports:" to help find the relevant area, but this way full bootstrap logging is included.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              richard.ponton Richard Ponton
              btburnett3 Brant Burnett
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty