提交 8745bf08 作者: 925993793@qq.com

Merge remote-tracking branch 'origin/test' into test

......@@ -25,7 +25,6 @@ target/
/dist/
/nbdist/
/.nb-gradle/
build/
!**/src/main/**/build/
!**/src/test/**/build/
......
FROM swr.cn-southwest-2.myhuaweicloud.com/wd/maven:3.6.1-jdk-8-alpine AS builder
USER root
WORKDIR /workspace
COPY . .
RUN mvn clean install -DskipTests
FROM swr.cn-southwest-2.myhuaweicloud.com/wd/openjdk:8-jdk-alpine3.9
MAINTAINER lixingyu
USER root
WORKDIR /workspace
COPY --from=builder /workspace/target/*.jar /workspace/app.jar
ARG ENV_NAME
ARG PORT
ENV APP_OPTS1="-Dspring.profiles.active=${ENV_NAME}"
ENV APP_OPTS2="-Djasypt.encryptor.password=1@wdLkj90#chMsdzxA%2024"
ENV APP_OPTS3="-Dfile.encoding=utf-8"
ENV APP_OPTS4="-Duser.timezone=Asia/Shanghai"
ENV JVM_OPTS="-Xmx2024M -Xms256M"
EXPOSE ${PORT}
ENTRYPOINT ["sh","-c","java $APP_OPTS1 $APP_OPTS2 $APP_OPTS3 $APP_OPTS4 -jar $JVM_OPTS /workspace/app.jar"]
\ No newline at end of file
#!/bin/bash
# build.sh - 功能包括:镜像构建,推送镜像,处理none镜像。
# author: lixingyu
# 使用方法:
# $ ./build.sh <env_name> <build_timestamp>
# 参数:
# env_name:环境变量 build_timestamp:构建时间戳
set -eu
# 获取脚本的绝对路径(包括文件名)
script_path=$(readlink -f "$0")
# 获取脚本所在的目录的绝对路径
script_dir=$(dirname "$script_path")
# 函数定义
function print_usage {
# 打印使用说明
sed -n '2,7p' "$0"
}
function handle {
local env_name=$1
local build_timestamp=$2
echo "执行的环境变量: ${env_name}"
echo "执行的构建时间戳: ${build_timestamp}"
if [ ! -f "$script_dir/env/env.${env_name}" ]; then
echo "错误: 文件 'env.${env_name}' 不存在." >&2
exit 1
fi
. $script_dir/env/env.${env_name}
local username="${repo_username}"
local passwd="${repo_passwd}"
local dir="${root_dir}/${svc_name}/${svc_env}"
local name="${svc_name}-${svc_env}"
local version=${version}-${build_timestamp}
echo "构建名称: ${name}"
echo "构建端口: ${svc_port}"
echo "构建版本: ${version}"
echo "推送仓库: ${domain}/${namespace}"
echo "完整镜像: ${domain}/${namespace}/${name}:${version}"
echo "---构建镜像---"
docker build --build-arg ENV_NAME=${svc_env} --build-arg PORT=${svc_port} -f ./build/Dockerfile -t ${domain}/${namespace}/${name}:${version} .
echo "---推送镜像---"
docker login -u=$username -p=${passwd} ${domain}
docker push ${domain}/${namespace}/${name}:${version}
echo "---清理none镜像---"
docker image prune -af
}
# 主程序入口点
function main {
if [ "$#" -ne 2 ]; then
print_usage
echo "错误: 需要提供两个个参数 <env_name> <build_timestamp>" >&2
exit 1
fi
local env_name=$1
local build_timestamp=$2
handle "${env_name}" "${build_timestamp}"
}
# 错误处理
trap 'echo 发生了错误,脚本中断.' ERR
# 调用主函数
main "$@"
# 镜像仓库
# 版本 T1.0.0: T为测试版,R为稳定版
version="T1.0.0" # 可自定义
# 镜像仓库地址
domain="swr.cn-southwest-2.myhuaweicloud.com"
# 镜像分组,按部门区分
namespace="wd"
# 服务配置
# 数据挂载根目录
root_dir="/zzsn"
# 需根据日志配置填写,比如:logback-spring.xml
svc_logs="/workspace/logs"
# 环境变量 test or prod
svc_env="pro"
# 服务名
svc_name="event-analysis"
# 服务端口
svc_port="1688"
# 镜像仓库
# 版本 T1.0.0: T为测试版,R为稳定版
version="T1.0.0" # 可自定义
# 镜像仓库地址
domain="swr.cn-southwest-2.myhuaweicloud.com"
# 镜像分组,按部门区分
namespace="wd"
# 服务配置
# 数据挂载根目录
root_dir="/zzsn"
# 需根据日志配置填写,比如:logback-spring.xml
svc_logs="/workspace/logs"
# 环境变量 test or prod
svc_env="test"
# 服务名
svc_name="event-analysis"
# 服务端口
svc_port="1688"
#!/bin/bash
# run.sh - 功能包括:运行容器,处理none镜像。
# author: lixingyu
# 使用方法:
# $ ./run.sh <env_name> <build_timestamp>
# 参数:
# env_name:环境变量 build_timestamp:构建时间戳
set -eu
# 获取脚本的绝对路径(包括文件名)
script_path=$(readlink -f "$0")
# 获取脚本所在的目录的绝对路径
script_dir=$(dirname "$script_path")
# 函数定义
function print_usage {
# 打印使用说明
sed -n '2,7p' "$0"
}
function handle {
local env_name=$1
local build_timestamp=$2
echo "执行的环境变量: ${env_name}"
echo "执行的构建时间戳: ${build_timestamp}"
if [ ! -f "$script_dir/env/env.${env_name}" ]; then
echo "错误: 文件 'env.${env_name}' 不存在." >&2
exit 1
fi
. $script_dir/env/env.${env_name}
local dir="${root_dir}/${svc_name}/${svc_env}"
local name="${svc_name}-${svc_env}"
local version=${version}-${build_timestamp}
echo "---运行容器: ${name}:${version}---"
docker pull ${domain}/${namespace}/${name}:${version}
if [ "$(docker ps -aqf "name=^${name}")" ]; then
# 如果存在,则停止并删除容器
echo "停止并删除容器: ${name}"
docker rm -f "${name}"
else
echo "容器不存在直接运行: ${name}"
fi
docker run --restart always -d -p ${svc_port}:${svc_port} --name ${name} \
-v /etc/localtime:/etc/localtime:ro \
-v ${dir}/logs:${svc_logs} \
-v /zzsn/data/win/Fonts:/zzsn/data/win/Fonts \
-v /zzsn/enterprise-service:/zzsn/enterprise-service \
${domain}/${namespace}/${name}:${version}
echo "---清理none镜像---"
docker image prune -af
}
# 主程序入口点
function main {
if [ "$#" -ne 2 ]; then
print_usage
echo "错误: 需要提供两个个参数 <env_name> <build_timestamp>" >&2
exit 1
fi
local env_name=$1
local build_timestamp=$2
handle "${env_name}" "${build_timestamp}"
}
# 错误处理
trap 'echo 发生了错误,脚本中断.' ERR
# 调用主函数
main "$@"
......@@ -17,10 +17,12 @@ public class WebConfigure implements WebMvcConfigurer {
@Value("${jeecg.shiro,excludeUrls:}")
private String ALLOW_URL;
//服务部署环境 clb:克虏宝 yjzx:研究中心
@Value("${server.profiles:clb}")
private String profiles;
@Bean
public LoginInterceptor loginInterceptor() {
return new LoginInterceptor();
return new LoginInterceptor(profiles);
}
@Override
......
......@@ -3,6 +3,7 @@ package com.zzsn.event.config.interceptor;
import cn.hutool.core.net.URLDecoder;
import com.alibaba.fastjson2.JSON;
import com.zzsn.event.constant.Result;
import com.zzsn.event.util.RequestUtil;
import com.zzsn.event.util.user.UserUtil;
import com.zzsn.event.util.user.UserVo;
import lombok.extern.slf4j.Slf4j;
......@@ -27,6 +28,12 @@ public class LoginInterceptor implements HandlerInterceptor {
public final static String LOGIN_USER_HEADER = "loginUser";
private final String profiles;
public LoginInterceptor(String profiles) {
this.profiles = profiles;
}
@Override
public boolean preHandle(HttpServletRequest request, @NotNull HttpServletResponse response, @NotNull Object handler) {
String userInfo = URLDecoder.decode(request.getHeader(LOGIN_USER_HEADER), StandardCharsets.UTF_8);
......@@ -36,6 +43,9 @@ public class LoginInterceptor implements HandlerInterceptor {
return false;
}
UserVo userVo = JSON.parseObject(userInfo, UserVo.class);
if("yjzx".equals(profiles)){
userVo.setTenant(RequestUtil.getTenantByRequest(request));
}
UserUtil.setLoginUser(userVo);
return true;
}
......
......@@ -59,6 +59,8 @@ public class Constants {
/*数据权限类型*/
public final static String PERMISSION_SUBJECT = "subject";
public static final Integer SUCCESS_CODE = 200;
//事件默认绑定模型集合
public static final Map<String, String> DEFAULT_MODEL = new HashMap<String, String>() {{
put("1706918153597943809","3");
......
......@@ -12,6 +12,7 @@ import com.zzsn.event.vo.EventExcelVO;
import com.zzsn.event.vo.EventRegionVO;
import com.zzsn.event.vo.EventTopVO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
......@@ -63,14 +64,19 @@ public class EventHomeController {
Map<String, Integer> map = new HashMap<>();
List<EventExcelVO> eventList = eventService.frontAllList(projectId, username, null, null,null,null,null,null);
map.put("eventCount", eventList.size());
List<String> eventIdList = eventList.stream().map(EventExcelVO::getId).collect(Collectors.toList());
long total = esStatisticsService.totalCount(eventIdList, null, null);
map.put("total", (int) total);
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
LocalDateTime now = LocalDateTime.now();
LocalDateTime previousHour = now.minus(1, ChronoUnit.DAYS);
long totalAdd = esStatisticsService.totalCount(eventIdList, previousHour.format(formatter), now.format(formatter));
map.put("totalAdd", (int) totalAdd);
if (!CollectionUtils.isEmpty(eventList)) {
List<String> eventIdList = eventList.stream().map(EventExcelVO::getId).collect(Collectors.toList());
long total = esStatisticsService.totalCount(eventIdList, null, null);
map.put("total", (int) total);
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
LocalDateTime now = LocalDateTime.now();
LocalDateTime previousHour = now.minus(1, ChronoUnit.DAYS);
long totalAdd = esStatisticsService.totalCount(eventIdList, previousHour.format(formatter), now.format(formatter));
map.put("totalAdd", (int) totalAdd);
} else {
map.put("total", 0);
map.put("totalAdd", 0);
}
return Result.OK(map);
}
......
......@@ -221,7 +221,10 @@ public class Event {
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date firstOpenTime;
/**
* 访问环境,prod:正式环境 test:测试环境
*/
private String tenant;
/**
* 关键词信息
*/
......
package com.zzsn.event.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
import java.util.List;
/** 克虏宝事件表
* @Description: 事件
* @Author: jeecg-boot
* @Date: 2024-03-14
* @Version: V1.0
*/
@Data
@TableName("event")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="event对象", description="事件")
public class EventClb {
/**ID*/
//@TableId(type = IdType.ASSIGN_ID)
@TableId(type = IdType.INPUT)
@ApiModelProperty(value = "ID")
private String id;
/**编码*/
@Excel(name = "编码", width = 15)
@ApiModelProperty(value = "编码")
private String eventCode;
/**名称*/
@Excel(name = "名称", width = 15)
@ApiModelProperty(value = "名称")
private String eventName;
/**图标*/
@Excel(name = "图标", width = 15)
@ApiModelProperty(value = "图标")
private String eventIcon;
/**事件类型*/
@Excel(name = "事件类型", width = 15)
@ApiModelProperty(value = "事件类型")
private String eventType;
/**开始时间*/
@Excel(name = "开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "开始时间")
private Date startTime;
/**结束时间*/
@Excel(name = "结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "结束时间")
private Date endTime;
/**标签*/
@Excel(name = "标签", width = 15)
@ApiModelProperty(value = "标签")
private String eventLabel;
/**是否公开*/
@Excel(name = "是否公开", width = 15)
@ApiModelProperty(value = "是否公开")
private Integer facePublic;
/**事件描述*/
@Excel(name = "事件描述", width = 15)
@ApiModelProperty(value = "事件描述")
private String eventDescribe;
/**创建人id*/
@Excel(name = "创建人id", width = 15)
@ApiModelProperty(value = "创建人id")
private String createBy;
/**创建时间*/
@Excel(name = "创建时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建时间")
private Date createTime;
/**修改时间*/
@Excel(name = "修改时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "修改时间")
private Date updateTime;
/**修改人id*/
@Excel(name = "修改人id", width = 15)
@ApiModelProperty(value = "修改人id")
private String updateBy;
/**状态(0-禁用;1-启用)*/
private Integer status=1;
/**
* 专题最近一次分析时间
*/
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date analysisTime;
/**
* 分析事件脉络-最新资讯的时间
*/
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date eventTime;
/**划分专题库*/
@ApiModelProperty(value = "划分专题库")
private String library;
/**定时单位(1分;2小时;3日;4月)*/
@ApiModelProperty(value = "定时单位")
private String unit;
/**定时数值*/
@ApiModelProperty(value = "定时数值")
private Integer space;
/**cron表达式*/
@ApiModelProperty(value = "cron表达式")
private String cron;
/**是否提取热词*/
@ApiModelProperty(value = "是否提取热词")
private String ynExtractHotWords;
/**事件专题增量分析规则*/
@ApiModelProperty(value = "事件专题增量分析规则")
private Integer increAnaRule;
/**事件专题总量分析规则*/
@ApiModelProperty(value = "事件专题总量分析规则")
private Integer totalAnaRule;
/**事件专题时间间隔分析规则(天)*/
@ApiModelProperty(value = "事件专题时间间隔分析规则(天)")
private Integer timeAnaRule;
/**总热度*/
private Integer totalHot;
/**媒体热度*/
private Integer mediaHot;
/**微信热度*/
private Integer wechatHot;
/**其他热度*/
private Integer otherHot;
/**发布状态(0-未发布;1-已发布)*/
private Integer publishStatus;
/**发布状态(0-未发布;1-已发布)*/
private String relationEvents;
/**发布时间*/
private String publishDate;
/**排序号*/
private Integer sortOrder;
/**事件创建方式(1-用户直接创建;2-基于挖掘的事件创建)*/
private Integer category;
@TableField(exist = false)
private String typeName;
@TableField(exist = false)
private String startDate;
@TableField(exist = false)
private String endDate;
@TableField(exist = false)
private List<EventClb> relatedEventList;
@TableField(exist = false)
private EventTag eventTag;
@TableField(exist = false)
private String extractIndustryTag;
@TableField(exist = false)
private String extractCompanyTag;
@TableField(exist = false)
private String extractPersonTag;
@TableField(exist = false)
private String extractSentimentTag;
@TableField(exist = false)
private String extractKeywordsTag;
@TableField(exist = false)
private String extractLocationTag;
@TableField(exist = false)
private String extractTimeTag;
}
package com.zzsn.event.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
/**
* 克虏宝中的事件标签数据库,因为python目前只更新克虏宝事件标签库,所以这里直接取克虏宝的事件标签库
* @Description: EventTag
* @Author: jeecg-boot
* @Date: 2024-03-14
* @Version: V1.0
*/
@Data
@TableName("event_tag")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@Builder
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value="EventTag对象", description="事件")
public class EventTagClb {
/**ID*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "ID")
private String id;
private String eventId;
private String extractIndustryTag;
private String extractCompanyTag;
private String extractPersonTag;
private String extractSentimentTag;
private String extractKeywordsTag;
private String extractLocationTag;
private String extractTimeTag;
}
......@@ -87,7 +87,7 @@ public interface EventMapper extends BaseMapper<Event> {
@Param("eventTypes") List<String> eventTypes, @Param("labelField") String labelField,
@Param("labelName") String labelName, @Param("type") Integer type,
@Param("order") String order, @Param("orderType") String orderType,
@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);
@Param("offset") Integer offset, @Param("pageSize") Integer pageSize, @Param("tenant")String tenant);
/**
* 总数量-门户(全部)
......@@ -106,7 +106,7 @@ public interface EventMapper extends BaseMapper<Event> {
Integer frontAllCount(@Param("projectId") String projectId, @Param("createBy") String createBy,
@Param("eventId") String eventId, @Param("eventName") String eventName,
@Param("eventTypes") List<String> eventTypes, @Param("labelField") String labelField,
@Param("labelName") String labelName, @Param("type") Integer type);
@Param("labelName") String labelName, @Param("type") Integer type, @Param("tenant")String tenant);
/**
......@@ -130,7 +130,7 @@ public interface EventMapper extends BaseMapper<Event> {
@Param("eventTypes") List<String> eventTypes, @Param("labelField") String labelField,
@Param("labelName") String labelName, @Param("type") Integer type,
@Param("order") String order, @Param("orderType") String orderType,
@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);
@Param("offset") Integer offset, @Param("pageSize") Integer pageSize, @Param("tenant")String tenant);
/**
* 总数量-门户(我的)
......@@ -147,7 +147,7 @@ public interface EventMapper extends BaseMapper<Event> {
*/
Integer frontOwnerCount(@Param("projectId") String projectId, @Param("createBy") String createBy, @Param("eventName") String eventName,
@Param("eventTypes") List<String> eventTypes, @Param("labelField") String labelField,
@Param("labelName") String labelName, @Param("type") Integer type);
@Param("labelName") String labelName, @Param("type") Integer type, @Param("tenant")String tenant);
/**
......@@ -206,7 +206,7 @@ public interface EventMapper extends BaseMapper<Event> {
List<EventTopVO> topEventList(@Param("projectId") String projectId, @Param("createBy") String createBy,
@Param("startTime") String startTime, @Param("endTime") String endTime,
@Param("type") Integer type,
@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);
@Param("offset") Integer offset, @Param("pageSize") Integer pageSize, @Param("tenant")String tenant);
List<SubjectKafkaVo> processList(@Param("disableDate") Date disableDate);
......@@ -217,7 +217,7 @@ public interface EventMapper extends BaseMapper<Event> {
* @author lkg
* @date 2024/4/10
*/
List<EventRegionVO> listByRegion(@Param("projectId") String projectId, @Param("createBy") String createBy, @Param("type") Integer type, @Param("name") String name);
List<EventRegionVO> listByRegion(@Param("projectId") String projectId, @Param("createBy") String createBy, @Param("type") Integer type, @Param("name") String name, @Param("tenant")String tenant);
/**
* 公开且发布的事件信息集合
......@@ -226,12 +226,13 @@ public interface EventMapper extends BaseMapper<Event> {
* @param createBy 创建人
* @param eventIdList 事件id集合
* @param size 数量
* @param tenant
* @author lkg
* @date 2024/4/10
*/
List<EventExcelVO> frontAllList(@Param("projectId") String projectId, @Param("createBy") String createBy, @Param("eventIdList") List<String> eventIdList,
@Param("eventName") String eventName,@Param("eventTypes") List<String> eventTypes, @Param("labelField") String labelField,
@Param("labelName") String labelName, @Param("type") Integer type,@Param("size") Integer size);
@Param("eventName") String eventName, @Param("eventTypes") List<String> eventTypes, @Param("labelField") String labelField,
@Param("labelName") String labelName, @Param("type") Integer type, @Param("size") Integer size, @Param("tenant")String tenant);
/**
* 默认创建的,公开且发布的事件信息集合
......@@ -262,7 +263,7 @@ public interface EventMapper extends BaseMapper<Event> {
* @author lkg
* @date 2024/4/12
*/
List<EventVO> eventList(@Param("eventIdList") List<String> eventIdList);
List<EventVO> eventList(@Param("eventIdList") List<String> eventIdList, @Param("tenant")String tenant);
/**
* 专题绑定关键词数量
......
package com.zzsn.event.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zzsn.event.entity.EventTagClb;
import org.apache.ibatis.annotations.Mapper;
/**
* 克虏宝中事件标签库
* @Author: jeecg-boot
* @Date: 2024-03-14
* @Version: V1.0
*/
@Mapper
public interface EventTagClbMapper extends BaseMapper<EventTagClb> {
}
......@@ -114,6 +114,9 @@
from event t1 inner join event_category t2 on t1.event_type =t2.id
left join event_tag t3 on t1.id=t3.event_id
where t1.publish_status = 1 and t1.face_public = 1
<if test="tenant!=null and tenant != ''">
and t1.tenant = #{tenant}
</if>
union
select
t1.id,t1.event_name,t1.event_icon,t1.event_type,t1.start_time,t1.end_time,t1.publish_date,t1.event_describe,t1.event_label,
......@@ -124,6 +127,9 @@
from event t1 inner join event_category t2 on t1.event_type =t2.id
left join event_tag t3 on t1.id=t3.event_id
where t1.publish_status = 1 and t1.create_by = #{createBy}
<if test="tenant!=null and tenant != ''">
and t1.tenant = #{tenant}
</if>
) a inner join project_subject_map m on a.id = m.subject_id
where m.project_id = #{projectId}
<if test="eventId!=null and eventId != ''">
......@@ -174,6 +180,9 @@
from event t1 inner join event_category t2 on t1.event_type =t2.id
left join event_tag t3 on t1.id=t3.event_id
where t1.publish_status = 1 and t1.face_public = 1
<if test="tenant!=null and tenant != ''">
and t1.tenant = #{tenant}
</if>
union
select
t1.id,t1.event_name,t1.event_icon,t1.event_type,t1.start_time,t1.end_time,t1.publish_date,t1.event_describe,t1.event_label,
......@@ -183,7 +192,10 @@
t3.extract_keywords_tag,t3.extract_time_tag,t3.extract_location_tag
from event t1 inner join event_category t2 on t1.event_type =t2.id
left join event_tag t3 on t1.id=t3.event_id
where t1.publish_status = 1 and t1.create_by = #{createBy}) a
where t1.publish_status = 1 and t1.create_by = #{createBy}
<if test="tenant!=null and tenant != ''">
and t1.tenant = #{tenant}
</if>) a
inner join project_subject_map m on a.id = m.subject_id
) b
where b.project_id = #{projectId}
......@@ -224,6 +236,9 @@
inner join project_subject_map m on t1.id = m.subject_id
left join event_tag t3 on t1.id=t3.event_id
where t1.publish_status = 1 and t1.create_by = #{createBy} and m.project_id = #{projectId}
<if test="tenant != null and tenant != ''">
and t1.tenant = #{tenant}
</if>
<if test="eventName!=null and eventName != ''">
and t1.event_name like CONCAT('%',#{eventName},'%')
</if>
......@@ -264,6 +279,9 @@
inner join project_subject_map m on t1.id = m.subject_id
left join event_tag t3 on t1.id=t3.event_id
where t1.publish_status = 1 and t1.create_by = #{createBy} and m.project_id = #{projectId}
<if test="tenant != null and tenant != ''">
and t1.tenant = #{tenant}
</if>
<if test="eventName!=null and eventName != ''">
and t1.event_name like CONCAT('%',#{eventName},'%')
</if>
......@@ -485,10 +503,16 @@
select t.id,t.event_name,t.start_time,t.end_time,t.publish_date,t.total_hot,ec.type_name
from event t inner join event_category ec on t.event_type = ec.id
where t.publish_status = 1 and t.face_public = 1
<if test="tenant != null and tenant != ''">
and t.tenant = #{tenant}
</if>
union
select e.id,e.event_name,e.start_time,e.end_time,e.publish_date,e.total_hot,ec.type_name
from event e inner join event_category ec on e.event_type = ec.id
where e.publish_status = 1 and e.create_by = #{createBy}
<if test="tenant != null and tenant != ''">
and e.tenant = #{tenant}
</if>
) a inner join project_subject_map m on a.id = m.subject_id
where m.project_id = #{projectId}
<if test="startTime!=null and startTime != ''">
......@@ -532,9 +556,15 @@
(
select distinct a.* from(
select t.id,t.event_name,t.start_time,t.end_time from event t where t.publish_status = 1 and t.face_public = 1
<if test="tenant != null and tenant != ''">
and t.tenant = #{tenant}
</if>
union
select e.id,e.event_name,e.start_time,e.end_time from event e where e.publish_status = 1 and e.create_by =
#{createBy}
<if test="tenant != null and tenant != ''">
and e.tenant = #{tenant}
</if>
) a inner join project_subject_map m on a.id = m.subject_id
where m.project_id = #{projectId}
) b
......@@ -550,9 +580,15 @@
select distinct a.* from (
select e.id,e.event_name,e.event_type,e.event_describe,e.publish_date,e.total_hot from event e
where e.publish_status = 1 and e.face_public = 1
<if test="tenant != null and tenant != ''">
and e.tenant = #{tenant}
</if>
union
select e.id,e.event_name,e.event_type,e.event_describe,e.publish_date,e.total_hot from event e
where e.publish_status = 1 and e.create_by = #{createBy}
<if test="tenant != null and tenant != ''">
and e.tenant = #{tenant}
</if>
) a inner join project_subject_map m on a.id = m.subject_id
left join event_tag t3 on a.id=t3.event_id
where m.project_id = #{projectId}
......@@ -636,6 +672,9 @@
<select id="eventList" resultType="com.zzsn.event.vo.EventVO">
select t.id,t.event_name from event t where 1=1
<if test="tenant != null and tenant != ''">
and t.tenant = #{tenant}
</if>
<if test="eventIdList != null and eventIdList.size()>0">
and t.id in
<foreach collection="eventIdList" open="(" separator="," close=")" item="item">
......
......@@ -166,8 +166,8 @@ public interface IEventService extends IService<Event> {
* @author lkg
* @date 2024/4/10
*/
List<EventExcelVO> frontAllList(String projectId, String createBy, List<String> eventIdList,String searchWord,
String eventType, String labelField,String labelName, Integer size);
List<EventExcelVO> frontAllList(String projectId, String createBy, List<String> eventIdList, String searchWord,
String eventType, String labelField, String labelName, Integer size);
/**
* 默认创建的,公开且发布的事件信息集合
......@@ -179,8 +179,8 @@ public interface IEventService extends IService<Event> {
* @author lkg
* @date 2024/4/10
*/
List<EventExcelVO> frontOwnerList(String projectId, String createBy, List<String> eventIdList,String searchWord,
String eventType, String labelField,String labelName, Integer size);
List<EventExcelVO> frontOwnerList(String projectId, String createBy, List<String> eventIdList, String searchWord,
String eventType, String labelField, String labelName, Integer size);
/**
* 模型信息列表
......
package com.zzsn.event.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zzsn.event.entity.EventTagClb;
/**
* 克虏宝中事件标签
* @author wangFeng
* @date 2024/10/15 10:07
*/
public interface IEventTagClbService extends IService<EventTagClb> {
}
......@@ -55,6 +55,7 @@ public interface IKeyWordsService extends IService<KeyWords> {
*/
KeyWords saveKeyword(Event event, String keyword, String exclusionWord);
KeyWords saveKeyword(String subjectId, KeyWords keyWords);
/**
* 事件绑定关键词信息
*
......
package com.zzsn.event.service.impl;
import cn.hutool.core.map.MapUtil;
import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
......@@ -171,7 +170,7 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
}
//获取当前登录人信息
UserVo currentUser = UserUtil.getLoginUser();
List<EventFrontVO> pageList = baseMapper.frontAllPageList(projectId, currentUser.getUsername(), eventId,eventName, eventTypes, labelField, labelName, type, order, orderType, offset, pageSize);
List<EventFrontVO> pageList = baseMapper.frontAllPageList(projectId, currentUser.getUsername(), eventId,eventName, eventTypes, labelField, labelName, type, order, orderType, offset, pageSize,UserUtil.getLoginUser().getTenant());
if (CollectionUtils.isNotEmpty(pageList)) {
Map<String, String> map = getFirstMap(pageList);
if (MapUtil.isNotEmpty(map)) {
......@@ -187,7 +186,7 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
}
}
//获取总条数
Integer count = baseMapper.frontAllCount(projectId, currentUser.getUsername(), eventId,eventName, eventTypes, labelField, labelName, type);
Integer count = baseMapper.frontAllCount(projectId, currentUser.getUsername(), eventId,eventName, eventTypes, labelField, labelName, type,UserUtil.getLoginUser().getTenant());
IPage<EventFrontVO> pageData = new Page<>(pageNo, pageSize, count);
pageData.setRecords(pageList);
return pageData;
......@@ -207,7 +206,7 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
}
//获取当前登录人信息
UserVo currentUser = UserUtil.getLoginUser();
List<EventFrontVO> pageList = baseMapper.frontOwnerPageList(projectId, currentUser.getUsername(), eventName, eventTypes, labelField, labelName, type, order, orderType, offset, pageSize);
List<EventFrontVO> pageList = baseMapper.frontOwnerPageList(projectId, currentUser.getUsername(), eventName, eventTypes, labelField, labelName, type, order, orderType, offset, pageSize,currentUser.getTenant());
if (CollectionUtils.isNotEmpty(pageList)) {
Map<String, String> map = getFirstMap(pageList);
if (MapUtil.isNotEmpty(map)) {
......@@ -219,7 +218,7 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
}
}
//获取总条数
Integer count = baseMapper.frontOwnerCount(projectId, currentUser.getUsername(), eventName, eventTypes, labelField, labelName, type);
Integer count = baseMapper.frontOwnerCount(projectId, currentUser.getUsername(), eventName, eventTypes, labelField, labelName, type,UserUtil.getLoginUser().getTenant());
IPage<EventFrontVO> pageData = new Page<>(pageNo, pageSize, count);
pageData.setRecords(pageList);
return pageData;
......@@ -260,12 +259,12 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
@Override
public List<EventTopVO> topEventList(String projectId, String createBy,String startTime, String endTime, Integer type, Integer pageSize) {
return baseMapper.topEventList(projectId,createBy,startTime, endTime, type, 0, pageSize);
return baseMapper.topEventList(projectId,createBy,startTime, endTime, type, 0, pageSize,UserUtil.getLoginUser().getTenant());
}
@Override
public List<EventRegionVO> listByRegion(String projectId, String createBy,Integer type, String name) {
return baseMapper.listByRegion(projectId,createBy,type, name);
return baseMapper.listByRegion(projectId,createBy,type, name,UserUtil.getLoginUser().getTenant());
}
private Map<String, String> getFirstMap(List<EventFrontVO> pageList) {
......@@ -478,7 +477,7 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
@Override
public List<EventVO> eventList(List<String> eventIdList) {
return baseMapper.eventList(eventIdList);
return baseMapper.eventList(eventIdList,UserUtil.getLoginUser().getTenant());
}
@Override
......@@ -512,8 +511,8 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
}
@Override
public List<EventExcelVO> frontAllList(String projectId, String createBy, List<String> eventIdList,String eventName,
String eventType, String labelField,String labelName, Integer size) {
public List<EventExcelVO> frontAllList(String projectId, String createBy, List<String> eventIdList, String eventName,
String eventType, String labelField, String labelName, Integer size) {
Integer type = null;
if (StringUtils.isNotEmpty(labelField) && labelField.equals("event_label")) {
type = 1;
......@@ -523,7 +522,7 @@ public class EventServiceImpl extends ServiceImpl<EventMapper, Event> implements
List<Node> nodes = eventCategoryService.categoryList();
eventTypes = TreeUtil.belowList(nodes, eventType, true);
}
return baseMapper.frontAllList(projectId,createBy,eventIdList,eventName,eventTypes,labelField,labelName,type, size);
return baseMapper.frontAllList(projectId,createBy,eventIdList,eventName,eventTypes,labelField,labelName,type, size,UserUtil.getLoginUser().getTenant());
}
@Override
......
package com.zzsn.event.service.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zzsn.event.entity.EventTagClb;
import com.zzsn.event.mapper.EventTagClbMapper;
import com.zzsn.event.service.IEventTagClbService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
/**
* 克虏宝事件标签
* @Description: 事件
* @Author: jeecg-boot
* @Date: 2024-03-14
* @Version: V1.0
*/
@Service
@Slf4j
@DS("multi-datasource-clb")
public class EventTagClbServiceImpl extends ServiceImpl<EventTagClbMapper, EventTagClb> implements IEventTagClbService {
}
......@@ -244,6 +244,20 @@ public class KeyWordsServiceImpl extends ServiceImpl<KeyWordsMapper, KeyWords> i
}
@Override
public KeyWords saveKeyword(String subjectId, KeyWords keyWords) {
if (keyWords != null){
save(keyWords);
String keyWordsId = keyWords.getId();
//专题和关键词关系
SubjectKeywordsMap subjectKeywordsMap = new SubjectKeywordsMap();
subjectKeywordsMap.setKeywordsId(keyWordsId);
subjectKeywordsMap.setSubjectId(subjectId);
subjectKeywordsMapService.save(subjectKeywordsMap);
}
return keyWords;
}
@Override
public KeywordsVO keywordInfoByEventId(String eventId) {
return baseMapper.keywordInfoByEventId(eventId);
}
......
......@@ -21,6 +21,7 @@ import org.apache.commons.collections4.ListUtils;
import org.apache.commons.lang3.ObjectUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.kafka.core.KafkaTemplate;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
......@@ -51,13 +52,18 @@ public class AnalysisTask {
@Autowired
private SubjectAnalysisService subjectAnalysisService;
@Value("${scheduling.yjzxEnable:false}")
Boolean yjzxEnable;
/**
* 每天凌晨0点20分执行一次
* 发送 伪事件脉络 所需信息到kafka对应的topic
*/
@Scheduled(cron = "0 20 0 * * ?")
public void eventContext_fake() {
if(yjzxEnable){
//研究中心不需要此任务
return;
}
Date today = new Date();
Date disableDate = DateUtil.addDate(today, -1);
List<SubjectKafkaVo> fakeEventIdList = new ArrayList<>();
......
package com.zzsn.event.task;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.zzsn.event.entity.Event;
import com.zzsn.event.entity.EventTag;
import com.zzsn.event.entity.EventTagClb;
import com.zzsn.event.mapper.EventClbMapper;
import com.zzsn.event.service.IEventService;
import com.zzsn.event.service.IEventTagClbService;
import com.zzsn.event.service.IEventTagService;
import com.zzsn.event.vo.EventVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.util.List;
/**
* 同步克虏宝事件相关信息,因为查询事件时候关联的有其它相关表,并且相关表的字段也参与过滤条件
* @author wangFeng
* @date 2024/10/15 13:51
*/
@Slf4j
@Component
public class SynClbEventDataTask {
@Resource
private IEventService eventService;
@Resource
private IEventTagService eventTagService;
@Resource
private EventClbMapper eventClbMapper;
@Resource
private IEventTagClbService eventTagClbService;
@Value("${scheduling.yjzxEnable:false}")
Boolean yjzxEnable;
/**
* 同步克虏宝中事件信息到研究中心数据库
*/
@Scheduled(cron = "0 15 0/1 * * ?")
public void synEventData () {
if(!yjzxEnable){
return;
}
log.info("同步克虏宝中事件信息到研究中心数据库开始");
LambdaQueryWrapper<Event> queryWrapper = Wrappers.lambdaQuery();
queryWrapper.eq(Event::getFacePublic,1).eq(Event::getPublishStatus,1);
List<Event> list = eventService.list(queryWrapper);
for (Event event : list) {
try{
// 克虏宝事件表
String eventId = event.getId();
EventVO eventVOClb = eventClbMapper.queryInfo(eventId);
if (eventVOClb != null) {
LambdaUpdateWrapper<Event> lambdaUpdateWrapper = Wrappers.lambdaUpdate(Event.class).eq(Event::getId, eventId)
.set(Event::getRelationEvents, eventVOClb.getRelationEvents()) // 事件关联事件
.set(Event::getEventLabel, eventVOClb.getEventLabel()) // 事件表中打的标签
// total_hot根据所有事件定时统计,这个使用研究中心自己的
;
eventService.update(lambdaUpdateWrapper);
// 事件标签表
EventTagClb eventTagClb = eventTagClbService.getOne(new LambdaQueryWrapper<EventTagClb>()
.eq(EventTagClb::getEventId, eventId)
.last(" limit 1"));
LambdaUpdateWrapper<EventTag> tagUpdateWrapper = Wrappers.lambdaUpdate(EventTag.class)
.eq(EventTag::getEventId, eventId)
.set(EventTag::getExtractIndustryTag, eventTagClb.getExtractIndustryTag()) // 事件关联事件
.set(EventTag::getExtractCompanyTag, eventTagClb.getExtractCompanyTag())
.set(EventTag::getExtractPersonTag, eventTagClb.getExtractPersonTag())
.set(EventTag::getExtractSentimentTag, eventTagClb.getExtractSentimentTag())
.set(EventTag::getExtractKeywordsTag, eventTagClb.getExtractKeywordsTag())
.set(EventTag::getExtractLocationTag, eventTagClb.getExtractLocationTag())
.set(EventTag::getExtractTimeTag, eventTagClb.getExtractTimeTag());
eventTagService.update(tagUpdateWrapper);
}
}catch (Exception e){
log.error("同步克虏宝中事件信息到研究中心数据库失败:{}", e);
}
}
log.info("同步克虏宝中事件信息到研究中心数据库结束");
}
}
package com.zzsn.event.util;
import org.apache.commons.lang3.StringUtils;
import javax.servlet.http.HttpServletRequest;
public class RequestUtil {
public static final String env_prod = "prod";
public static String getTenantByRequest(HttpServletRequest request) {
// TODO 待定 看如何取值判断前端环境
String env = request.getHeader("Env");
if (StringUtils.isEmpty(env)) {
// 空的默认生产环境
return env_prod;
}
if(!StringUtils.equals(env, "test")) {
return env_prod;
}
return env;
}
}
......@@ -13,7 +13,8 @@ public abstract class UserUtil {
private static final ThreadLocal<UserVo> USER_THREAD_LOCAL = new ThreadLocal<>();
public static UserVo getLoginUser() {
return USER_THREAD_LOCAL.get();
UserVo userVo = USER_THREAD_LOCAL.get();
return userVo==null?new UserVo():userVo;
}
public static void setLoginUser(UserVo userVo) {
......
......@@ -123,4 +123,8 @@ public class UserVo implements Serializable {
private String userId;
private String customerId;
/**
* 访问环境,prod:正式环境 test:测试环境
*/
private String tenant;
}
......@@ -51,4 +51,12 @@ public class AddEventVO {
/**伪事件id*/
private String fakeEventId;
/**事件编码,这里研究中心部署调用克虏宝,直接使用clb中的事件编码*/
private String eventCode;
/**
* 访问环境,prod:正式环境 test:测试环境
*/
private String tenant;
}
server:
#服务部署环境 clb:克虏宝 yjzx:研究中心
profiles: yjzx
spring:
servlet:
multipart:
......@@ -42,22 +45,27 @@ spring:
connectionProperties: druid.stat.mergeSql\=true;druid.stat.slowSqlMillis\=5000
datasource:
master:
url: jdbc:mysql://1.95.14.228:3306/clb_project?useUnicode=true&characterEncoding=utf-8&AllowPublicKeyRetrieval=True&serverTimezone=Asia/Shanghai&autoReconnect=true&rewriteBatchedStatements=true
url: jdbc:mysql://1.95.78.131:3306/clb_project_yjzx?useUnicode=true&characterEncoding=utf-8&AllowPublicKeyRetrieval=True&serverTimezone=Asia/Shanghai&autoReconnect=true&rewriteBatchedStatements=true
username: ciglobal
password: _PSuWVQ4CLpX
password: qwer@9988&zzsn
driver-class-name: com.mysql.cj.jdbc.Driver
multi-datasource1:
url: jdbc:mysql://1.95.78.131:3306/clb_xxl_job?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
url: jdbc:mysql://1.95.78.131:3306/clb_xxl_job_yjzx?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
username: ciglobal
password: qwer@9988&zzsn
driver-class-name: com.mysql.cj.jdbc.Driver
multi-datasource2:
url: jdbc:mysql://1.95.14.228:3306/clb_system?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
url: jdbc:mysql://1.95.78.131:3306/clb_system_yjzx?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
username: ciglobal
password: _PSuWVQ4CLpX
password: qwer@9988&zzsn
driver-class-name: com.mysql.cj.jdbc.Driver
multi-datasource-clb:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://1.95.14.228:3306/clb_project?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai&rewriteBatchedStatements=true
username: ciglobal
password: _PSuWVQ4CLpX
elasticsearch:
uris: ["192.168.0.24:9700","192.168.0.150:9200","192.168.0.81:9700"]
uris: ["1.95.38.69:9700","1.95.3.121:9200","1.95.87.177:9700"] # ["192.168.0.24:9700","192.168.0.150:9200","192.168.0.81:9700"]
username: elastic
password: zzsn9988
connection-timeout: 300000
......@@ -66,12 +74,12 @@ spring:
stream:
kafka:
binder:
brokers: 192.168.0.180:7092
zkNodes: 192.168.0.180:12181
brokers: 1.95.78.131:9092
zkNodes: 1.95.78.131:2181
requiredAcks: 1
redis:
database: 0
host: 114.116.90.53
database: 11
host: 1.95.69.2
lettuce:
pool:
max-active: 8 #最大连接数据库连接数,设 0 为没有限制
......@@ -82,7 +90,7 @@ spring:
port: 6380
password: RPHZgkDQ4zGJ
kafka:
bootstrap-servers: 192.168.0.180:7092
bootstrap-servers: 1.95.78.131:9092
producer: # 生产者
retries: 3 # 设置大于0的值,则客户端会将发送失败的记录重新发送
batch-size: 16384
......@@ -94,15 +102,9 @@ spring:
value-serializer: org.apache.kafka.common.serialization.StringSerializer
properties:
max.request.size: 335544324 #32M
security:
protocol: SASL_PLAINTEXT
sasl:
mechanism: PLAIN
jaas:
config: org.apache.kafka.common.security.plain.PlainLoginModule required username="admin" password="admin-zzsn9988";
consumer:
#用于标识此使用者所属的使用者组的唯一字符串
group-id: event-analysis-group
group-id: event-analysis-group-yjzx
#当Kafka中没有初始偏移量或者服务器上不再存在当前偏移量时该怎么办,默认值为latest,表示自动将偏移重置为最新的偏移量
#可选的值为latest, earliest, none
auto-offset-reset: latest
......@@ -114,13 +116,6 @@ spring:
key-deserializer: org.apache.kafka.common.serialization.StringDeserializer
#值的反序列化器类,实现类实现了接口org.apache.kafka.common.serialization.Deserializer
value-deserializer: org.apache.kafka.common.serialization.StringDeserializer
properties:
security:
protocol: SASL_PLAINTEXT
sasl:
mechanism: PLAIN
jaas:
config: org.apache.kafka.common.security.plain.PlainLoginModule required username="admin" password="admin-zzsn9988";
main:
allow-circular-references: true
mybatis-plus:
......@@ -132,18 +127,17 @@ obs:
sk: heR353lvSWVPNU8pe2QxDtd8GDsO5L6PGH5eUoQY
endPoint: https://obs.cn-north-1.myhuaweicloud.com
scheduling:
enable: true
enable: false
yjzxEnable: false
serviceProject:
url: https://clb.ciglobal.cn/clb-api/datapull/
checkToken:
url: https://clb.ciglobal.cn/clb-api/sys/checkToken
scoreRule:
weekScore: 10
monthScore: 5
yearScore: 3
beforeYearScore: 1
translate:
url: http://114.116.116.241:8018/translate/getTranslateInfoWithTag
url: http://1.95.51.144:8018/translate/getTranslateInfoWithTag
python:
#python打分接口-弃用
scoreModelUrl: http://114.116.36.231:8080/score
......@@ -162,7 +156,12 @@ kafka:
topic:
subject:
run: subjectModelTest
event:
run: eventSubjectModelTest
clb:
eventAdd: http://1.95.72.34:1688/event/third/api/saveEvent
eventEdit: http://1.95.72.34:1688/event/third/api/editEvent
eventDelete: http://1.95.72.34:1688/event/third/api/deleteEvent
subject:
default:
processing:
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论