(improvement)(headless)Change several info-mode logs to debug-mode

This commit is contained in:
jerryjzhang
2024-05-25 00:40:00 +08:00
parent 044cf8f31e
commit 6745df5a2e
8 changed files with 11 additions and 13 deletions

View File

@@ -37,7 +37,7 @@ public abstract class BaseSemanticCorrector implements SemanticCorrector {
return;
}
doCorrect(queryContext, semanticParseInfo);
log.info("sqlCorrection:{} sql:{}", this.getClass().getSimpleName(), semanticParseInfo.getSqlInfo());
log.debug("sqlCorrection:{} sql:{}", this.getClass().getSimpleName(), semanticParseInfo.getSqlInfo());
} catch (Exception e) {
log.error(String.format("correct error,sqlInfo:%s", semanticParseInfo.getSqlInfo()), e);
}

View File

@@ -168,12 +168,12 @@ public class HanlpHelper {
}
public static boolean addToCustomDictionary(DictWord dictWord) {
log.info("dictWord:{}", dictWord);
log.debug("dictWord:{}", dictWord);
return getDynamicCustomDictionary().insert(dictWord.getWord(), dictWord.getNatureWithFrequency());
}
public static void removeFromCustomDictionary(DictWord dictWord) {
log.info("dictWord:{}", dictWord);
log.debug("dictWord:{}", dictWord);
CoreDictionary.Attribute attribute = getDynamicCustomDictionary().get(dictWord.getWord());
if (attribute == null) {
return;

View File

@@ -89,7 +89,7 @@ public class HanlpDictMatchStrategy extends BaseMatchStrategy<HanlpMapResult> {
.filter(term -> CollectionUtils.isNotEmpty(term.getNatures()))
.collect(Collectors.toCollection(LinkedHashSet::new));
log.info("detectSegment:{},after isSimilarity parseResults:{}", detectSegment, hanlpMapResults);
log.debug("detectSegment:{},after isSimilarity parseResults:{}", detectSegment, hanlpMapResults);
hanlpMapResults = hanlpMapResults.stream().map(parseResult -> {
parseResult.setOffset(offset);

View File

@@ -35,14 +35,14 @@ public class DefaultQueryParser implements QueryParser {
if (Objects.isNull(queryStatement.getMetricQueryParam())) {
queryStatement.setMetricQueryParam(new MetricQueryParam());
}
log.info("SemanticConverter before [{}]", queryParam);
log.debug("SemanticConverter before [{}]", queryParam);
for (HeadlessConverter headlessConverter : ComponentFactory.getSemanticConverters()) {
if (headlessConverter.accept(queryStatement)) {
log.info("SemanticConverter accept [{}]", headlessConverter.getClass().getName());
headlessConverter.convert(queryStatement);
}
}
log.info("SemanticConverter after {} {} {}", queryParam, queryStatement.getDataSetQueryParam(),
log.debug("SemanticConverter after {} {} {}", queryParam, queryStatement.getDataSetQueryParam(),
queryStatement.getMetricQueryParam());
if (!queryStatement.getDataSetQueryParam().getSql().isEmpty()) {
queryStatement = parser(queryStatement.getDataSetQueryParam(), queryStatement);