Authored by Gino Zhang

修改SQL问题 增加日志

... ... @@ -9,7 +9,7 @@
<result column="update_time" property="updateTime" jdbcType="INTEGER" />
</resultMap>
<sql id="Base_Column_List">
id, source, dest, create_time, updateTime
id, source, dest, create_time, update_time
</sql>
<select id="selectTotalCount" resultType="java.lang.Integer" timeout="20000">
... ... @@ -27,7 +27,7 @@
</select>
<insert id="insertBatch" parameterType="java.util.List" timeout="20000">
insert ignore into suggest_conversion (source, dest, create_time, updateTime)
insert ignore into suggest_conversion (source, dest, create_time, update_time)
values
<foreach collection="list" item="item" index="index"
separator=",">
... ...
... ... @@ -62,6 +62,7 @@ public class SuggestConversionFlow implements RetryBusinessFlow {
@Override
public void init() {
existSourceSet = suggestConversionService.getAllSources();
logger.info("[func=SuggestConversionFlow.init][existSourceSetSize={}]", existSourceSet.size());
initAllYohoKeywords();
}
... ... @@ -71,6 +72,7 @@ public class SuggestConversionFlow implements RetryBusinessFlow {
resultSet.addAll(brandList.stream().map(Brand::getBrandName).filter(name -> StringUtils.isNotBlank(name)).collect(Collectors.toSet()));
resultSet.addAll(brandList.stream().map(Brand::getBrandNameEn).filter(name -> StringUtils.isNotBlank(name)).collect(Collectors.toSet()));
resultSet.addAll(brandList.stream().map(Brand::getBrandNameCn).filter(name -> StringUtils.isNotBlank(name)).collect(Collectors.toSet()));
logger.info("[func=SuggestConversionFlow.init][resultSetAfterLoadBrand={}]", resultSet.size());
List<ProductSort> productSortList = productSortService.getPageLists(1, Integer.MAX_VALUE);
resultSet.addAll(productSortList.stream().map(ProductSort::getSortName).filter(name -> StringUtils.isNotBlank(name)).collect(Collectors.toSet()));
... ... @@ -82,11 +84,14 @@ public class SuggestConversionFlow implements RetryBusinessFlow {
}
}
logger.info("[func=SuggestConversionFlow.init][resultSetAfterLoadSort={}]", resultSet.size());
List<Style> styleList = styleService.getStylePageLists(1, Integer.MAX_VALUE);
resultSet.addAll(styleList.stream().map(Style::getStyleName).filter(name -> StringUtils.isNotBlank(name)).collect(Collectors.toSet()));
logger.info("[func=SuggestConversionFlow.init][resultSetAfterLoadStyle={}]", resultSet.size());
List<ParameterMake> parameterMakeList = parameterMakeService.getAll();
resultSet.addAll(parameterMakeList.stream().map(ParameterMake::getParameterValue).filter(name -> StringUtils.isNotBlank(name)).collect(Collectors.toSet()));
logger.info("[func=SuggestConversionFlow.init][resultSetAfterLoadMake={}]", resultSet.size());
Set<String> tokens;
for (String keyword : resultSet) {
... ...