Skip to content

Commit fe2c593

Browse files
committed
make the log work in debug mode
1 parent fa39fd0 commit fe2c593

File tree

6 files changed

+2
-12
lines changed

6 files changed

+2
-12
lines changed

docs/en/setup/backend/configuration-vocabulary.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,6 @@ The global settings for the whole BanyanDB:
372372
| profileDataQueryScrollBatchSize | The batch size of query profiling data. | SW_STORAGE_BANYAND_QUERY_PROFILE_DATA_BATCH_SIZE | 100 |
373373
| sslTrustCAPath | If the BanyanDB server is configured with TLS, config the TLS cert file path and open tls connection. | SW_STORAGE_BANYANDB_SSL_TRUST_CA_PATH | - |
374374
| cleanupUnusedTopNRules | Cleanup TopN rules in BanyanDB server that are not configured in the bydb-topn.yml config. | SW_STORAGE_BANYANDB_CLEANUP_UNUSED_TOPN_RULES | true |
375-
| logEndpointDirectTopNQuery | Record the Endpoint direct TopN query info in the logs. | SW_STORAGE_BANYANDB_LOG_ENDPOINT_DIRECT_TOPN_QUERY | false |
376375

377376
### Group Configuration
378377
The settings for each group:

docs/en/setup/backend/storages/banyandb.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,6 @@ global:
6666
sslTrustCAPath: ${SW_STORAGE_BANYANDB_SSL_TRUST_CA_PATH:""}
6767
# Cleanup TopN rules in BanyanDB server that are not configured in the bydb-topn.yml config.
6868
cleanupUnusedTopNRules: ${SW_STORAGE_BANYANDB_CLEANUP_UNUSED_TOPN_RULES:true}
69-
# Record the Endpoint direct TopN query info in the OAP logs.
70-
logEndpointDirectTopNQuery: ${SW_STORAGE_BANYANDB_LOG_ENDPOINT_DIRECT_TOPN_QUERY:false}
7169

7270
groups:
7371
# The group settings of record.

oap-server/server-starter/src/main/resources/bydb.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,6 @@ global:
4747
sslTrustCAPath: ${SW_STORAGE_BANYANDB_SSL_TRUST_CA_PATH:""}
4848
# Cleanup TopN rules in BanyanDB server that are not configured in the bydb-topn.yml config.
4949
cleanupUnusedTopNRules: ${SW_STORAGE_BANYANDB_CLEANUP_UNUSED_TOPN_RULES:true}
50-
# Record the Endpoint direct TopN query info in the OAP logs.
51-
logEndpointDirectTopNQuery: ${SW_STORAGE_BANYANDB_LOG_ENDPOINT_DIRECT_TOPN_QUERY:false}
5250

5351
groups:
5452
# The group settings of record.

oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/BanyanDBAggregationQueryDAO.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,9 +142,9 @@ List<SelectedRecord> serverSideTopN(boolean isColdStage, TopNCondition condition
142142

143143
List<SelectedRecord> directMetricsTopN(boolean isColdStage, TopNCondition condition, MetadataRegistry.Schema schema, String valueColumnName, MetadataRegistry.ColumnSpec valueColumnSpec,
144144
TimestampRange timestampRange, List<KeyValue> additionalConditions) throws IOException {
145-
if (getClient().getConfig().getGlobal().isLogEndpointDirectTopNQuery()
145+
if (log.isDebugEnabled()
146146
&& condition.getScope().equals(Scope.Endpoint)) {
147-
log.info("Endpoint direct TopN query, TopNCondition: {}, AdditionalConditions: {}, TimestampRange: {}",
147+
log.debug("Endpoint direct TopN query, TopNCondition: {}, AdditionalConditions: {}, TimestampRange: {}",
148148
condition, additionalConditions, timestampRange);
149149
}
150150
MeasureQueryResponse resp = queryDebuggable(isColdStage, schema, TAGS, Collections.singleton(valueColumnName),

oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/BanyanDBStorageClient.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
import java.util.Collections;
2727
import java.util.List;
2828
import java.util.Properties;
29-
import lombok.Getter;
3029
import lombok.extern.slf4j.Slf4j;
3130
import org.apache.skywalking.banyandb.common.v1.BanyandbCommon;
3231
import org.apache.skywalking.banyandb.common.v1.BanyandbCommon.Group;
@@ -67,15 +66,12 @@ public class BanyanDBStorageClient implements Client, HealthCheckable {
6766
final BanyanDBClient client;
6867
private final DelegatedHealthChecker healthChecker = new DelegatedHealthChecker();
6968
private final int flushTimeout;
70-
@Getter
71-
private final BanyanDBStorageConfig config;
7269

7370
public BanyanDBStorageClient(BanyanDBStorageConfig config) {
7471
Options options = new Options();
7572
options.setSslTrustCAPath(config.getGlobal().getSslTrustCAPath());
7673
this.client = new BanyanDBClient(config.getTargetArray(), options);
7774
this.flushTimeout = config.getGlobal().getFlushTimeout();
78-
this.config = config;
7975
}
8076

8177
@Override

oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/BanyanDBStorageConfig.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,6 @@ public static class Global {
102102
private int segmentQueryMaxSize = 200;
103103
private int profileDataQueryBatchSize = 100;
104104
private boolean cleanupUnusedTopNRules = true;
105-
private boolean logEndpointDirectTopNQuery = false;
106105
}
107106

108107
// The configuration of the groups.

0 commit comments

Comments
 (0)