From b8f22fe9bc13e060ac33334166fdf49291391bff Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Sat, 26 Jul 2025 12:55:46 +0530 Subject: [PATCH 1/7] non-pipeline-services-settings --- .../pages/rest-xdcr-adv-settings.adoc | 85 ++++++++++++++++++- 1 file changed, 83 insertions(+), 2 deletions(-) diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index 45e1c8fa3b..32fd8038d8 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -94,32 +94,57 @@ If successful, the call returns an object similar to the following: ---- { + "cLogConnPoolGCIntervalMs": 60000, + "cLogConnPoolLimit": 30, + "cLogConnPoolReapIntervalMs": 120000, + "cLogErrorTimeWindowMs": 120000, + "cLogMaxErrorCount": 10, + "cLogNetworkRetryCount": 5, + "cLogNetworkRetryIntervalMs": 2000, + "cLogPoolGetTimeoutMs": 5000, + "cLogQueueCapacity": 6000, + "cLogReattemptDurationMs": 600000, + "cLogSetTimeoutMs": 5000, + "cLogWorkerCount": 20, + "casDriftThresholdSecs": 3900, "checkpointInterval": 600, "ckptSvcCacheEnabled": true, + "collectionsOSOMode": true, "compressionType": "Auto", + "conflictLogging": {}, + "dcpEnablePurgeRollback": false, "desiredLatency": 50, + "disableHlvBasedShortCircuit": false, "docBatchSizeKb": 2048, "failureRestartInterval": 10, + "filterBinary": false, "filterBypassExpiry": false, "filterBypassUncommittedTxn": false, "filterDeletion": false, "filterExpiration": false, + "genericServicesLogLevel": { + < ... diagnostic items cut out due to length ... > + }, "goGC": 100, "goMaxProcs": 4, - "hlvPruningWindowSec": 259200, "jsFunctionTimeoutMs": 20000, "logLevel": "Info", "mergeFunctionMapping": {}, + "mobile": "Off", "networkUsageLimit": 0, "optimisticReplicationThreshold": 256, + "preCheckCasDriftThresholdHours": 8760, "preReplicateVBMasterCheck": true, "priority": "High", "replicateCkptIntervalMin": 20, + "retryOnErrExceptAuthErrMaxWaitSec": 360, "retryOnRemoteAuthErr": true, - "retryOnRemoteAuthErrMaxWaitSec": 3600, + "retryOnRemoteAuthErrMaxWaitSec": 360, + "skipReplSpecAutoGc": false, "sourceNozzlePerNode": 2, "statsInterval": 1000, "targetNozzlePerNode": 2, + "targetTopologyLogFrequency": 1800, "workerBatchSize": 500 } ---- @@ -295,6 +320,53 @@ If successful, the call returns an object containing all current settings for th } ---- +===== Change Settings for XDCR Generic Services Log Levels + + + +---- +curl -X POST -u Administrator:password http://localhost:8091/settings/replications -d 'genericServicesLogLevel={"RemoteClusterService":"Debug","ReplicationSpecService":"Error","BucketTopologyService":"Debug","CheckpointService":"Error"}' +---- + +If successful, the call returns an object containing all current Generic Services Log level settings for the replication, including what has been changed: + +---- +{ +... +"genericServicesLogLevel": { + "AdminPort": "Info", + "AuditService": "Info", + "BackfillManager": "Info", + "BackfillReplicationService": "Info", + "BucketTopologyService": "Debug", + "CapiService": "Info", + "CheckpointService": "Error", + "CollectionsManifestService": "Info", + "Default": "Info", + "GenericSupervisor": "Info", + "GlobalSettingsService": "Info", + "HttpServer": "Info", + "InternalSettingsService": "Info", + "ManifestService": "Info", + "MessageUtils": "Info", + "MetaKVMetadataService": "Info", + "MigrationService": "Info", + "P2PManagerService": "Info", + "PipelineManager": "Info", + "RemoteClusterService": "Debug", + "ReplicationSettingService": "Info", + "ReplicationSpecService": "Error", + "ResourceManager": "Info", + "SecurityService": "Info", + "ThroughputThrottlerService": "Info", + "TopologyService": "Info", + "UtilsService": "Info", + "XDCRFactory": "Info" + }, +... +} +---- + [#xdcr-advanced-settings-rest] == List of Advanced Settings @@ -409,6 +481,15 @@ For supported expressions, see xref:xdcr-reference:xdcr-filtering-reference-intr This setting can only be established for and retrieved from an individual replication: it cannot be established or retrieved as part of global settings. +| `genericServicesLogLevel` +| JSON Object +| The keys represent service names and the associated values represent log levels. +For example, the following object sets the log level for the `RemoteClusterService` to `Debug`, and for the `ReplicationSpecService` to `Error`. +By default, non-pipeline-specific services use the "Info" log level. You can also set the log level to `Error`, `Debug`, or `Trace`. + +The `Default` key sets the log level for shared utilities like connection pools and data pools, which are used by multiple services. +All these utilities use the same default logger, so changing the log level in 'Default' affects all logger dependent utilities. + | `goGC` | Integer (0 to 100) or String ("off") | Default: 100. From 59eeb1e0158fcbb0ab96e5a76a94e33df8cb124c Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Sat, 26 Jul 2025 13:01:09 +0530 Subject: [PATCH 2/7] minor-edit --- modules/rest-api/pages/rest-xdcr-adv-settings.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index 32fd8038d8..bcff6b10cb 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -322,7 +322,7 @@ If successful, the call returns an object containing all current settings for th ===== Change Settings for XDCR Generic Services Log Levels - +The following example modifies the log levels for XDCR Generic Services, for a specific replication. ---- curl -X POST -u Administrator:password http://localhost:8091/settings/replications -d 'genericServicesLogLevel={"RemoteClusterService":"Debug","ReplicationSpecService":"Error","BucketTopologyService":"Debug","CheckpointService":"Error"}' From c41f4d21c24bf4a92057056c93493418dcf6bd9b Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Sat, 26 Jul 2025 13:04:21 +0530 Subject: [PATCH 3/7] minor-edits --- modules/rest-api/pages/rest-xdcr-adv-settings.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index bcff6b10cb..7672a1c395 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -328,7 +328,7 @@ The following example modifies the log levels for XDCR Generic Services, for a s curl -X POST -u Administrator:password http://localhost:8091/settings/replications -d 'genericServicesLogLevel={"RemoteClusterService":"Debug","ReplicationSpecService":"Error","BucketTopologyService":"Debug","CheckpointService":"Error"}' ---- -If successful, the call returns an object containing all current Generic Services Log level settings for the replication, including what has been changed: +If successful, the call returns an object containing all current Generic Services related log level settings for the replication, including what's changed: ---- { From ca63c222782814c9efa51a16b1231c56f77c6fd2 Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Sat, 26 Jul 2025 13:29:11 +0530 Subject: [PATCH 4/7] minor edit --- modules/rest-api/pages/rest-xdcr-adv-settings.adoc | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index 7672a1c395..b920949607 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -483,12 +483,17 @@ This setting can only be established for and retrieved from an individual replic | `genericServicesLogLevel` | JSON Object -| The keys represent service names and the associated values represent log levels. -For example, the following object sets the log level for the `RemoteClusterService` to `Debug`, and for the `ReplicationSpecService` to `Error`. -By default, non-pipeline-specific services use the "Info" log level. You can also set the log level to `Error`, `Debug`, or `Trace`. +| This is Generic Services related log level settings for the replication. + +The keys represent service names and the associated values represent log levels. + +In the example, the log level for `RemoteClusterService` is set to `Debug`, and for `ReplicationSpecService` is set to `Error`. + +By default, non-pipeline specific services use the `Info` log level. +You can also set the log level to `Error`, `Debug`, or `Trace`. The `Default` key sets the log level for shared utilities like connection pools and data pools, which are used by multiple services. -All these utilities use the same default logger, so changing the log level in 'Default' affects all logger dependent utilities. +All these utilities use the same default logger, so changing the log level in `Default` affects all logger dependent utilities. | `goGC` | Integer (0 to 100) or String ("off") From 9f9a1f08da36edf236c450df2133468fb6e3e534 Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Sat, 26 Jul 2025 16:18:38 +0530 Subject: [PATCH 5/7] minor-edits --- modules/rest-api/pages/rest-xdcr-adv-settings.adoc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index b920949607..3632e29301 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -367,6 +367,12 @@ If successful, the call returns an object containing all current Generic Service } ---- +To view the current log levels for XDCR Generic Services anytime, use the following command: + +---- +curl -s -X GET -u Administrator:password http://localhost:8091/settings/replications | jq +---- + [#xdcr-advanced-settings-rest] == List of Advanced Settings From 2bc4578e9af76a43caabd5983a95f34911f22cbe Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Mon, 4 Aug 2025 13:04:05 +0530 Subject: [PATCH 6/7] whats-new-entry --- modules/introduction/partials/new-features-80.adoc | 4 ++++ modules/rest-api/pages/rest-xdcr-adv-settings.adoc | 1 + 2 files changed, 5 insertions(+) diff --git a/modules/introduction/partials/new-features-80.adoc b/modules/introduction/partials/new-features-80.adoc index 862dc329db..186786f64c 100644 --- a/modules/introduction/partials/new-features-80.adoc +++ b/modules/introduction/partials/new-features-80.adoc @@ -120,6 +120,10 @@ Additional information sent by clients at connection time can be found in the lo https://jira.issues.couchbase.com/browse/MB-61048[MB-61048]:: Once faulty remote cluster credentials are fixed, XDCR will now be able to more quickly restart replications that depend on the repaired references. +https://jira.issues.couchbase.com/browse/MB-62507[MB-62507]:: +XDCR supports Generic Services Log Level configuration using the REST API through the `genericServicesLogLevel` settings. +For more information, see xref:rest-api:rest-xdcr-adv-settings.adoc[XDCR Advanced Settings]. + [#section-new-feature-800-query-service] === Query Service diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index 3632e29301..5de04e2c24 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -323,6 +323,7 @@ If successful, the call returns an object containing all current settings for th ===== Change Settings for XDCR Generic Services Log Levels The following example modifies the log levels for XDCR Generic Services, for a specific replication. +Usually, you modify the log levels only when requested by Couchbase Support. ---- curl -X POST -u Administrator:password http://localhost:8091/settings/replications -d 'genericServicesLogLevel={"RemoteClusterService":"Debug","ReplicationSpecService":"Error","BucketTopologyService":"Debug","CheckpointService":"Error"}' From b1a44aa1e6b86aa520a0a125d1f2ef67751d285e Mon Sep 17 00:00:00 2001 From: Shwetha Rao Date: Mon, 4 Aug 2025 16:40:30 +0530 Subject: [PATCH 7/7] implemented-editorial-inputs --- modules/rest-api/pages/rest-xdcr-adv-settings.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc index 5de04e2c24..e9de8d2d64 100644 --- a/modules/rest-api/pages/rest-xdcr-adv-settings.adoc +++ b/modules/rest-api/pages/rest-xdcr-adv-settings.adoc @@ -490,11 +490,11 @@ This setting can only be established for and retrieved from an individual replic | `genericServicesLogLevel` | JSON Object -| This is Generic Services related log level settings for the replication. +| This is the Generic Services related log level settings for the replication. The keys represent service names and the associated values represent log levels. -In the example, the log level for `RemoteClusterService` is set to `Debug`, and for `ReplicationSpecService` is set to `Error`. +In the example, the log level for `RemoteClusterService` is set to `Debug`, and for `ReplicationSpecService`, it's set to `Error`. By default, non-pipeline specific services use the `Info` log level. You can also set the log level to `Error`, `Debug`, or `Trace`.