Commit 4a2d390e authored by H2T's avatar H2T

tzs监管模块

parent cae4b490
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>amos-boot-module-jg</artifactId>
<groupId>com.amosframework.boot</groupId>
<version>1.0.0</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<version>1.0.0</version>
<artifactId>amos-boot-module-jg-api</artifactId>
<dependencies>
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-elasticsearch</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.amosframework.boot</groupId>
<artifactId>amos-boot-module-common-api</artifactId>
<version>${amos-biz-boot.version}</version>
</dependency>
<dependency>
<groupId>net.javacrumbs.shedlock</groupId>
<artifactId>shedlock-spring</artifactId>
</dependency>
<dependency>
<groupId>net.javacrumbs.shedlock</groupId>
<artifactId>shedlock-provider-redis-spring</artifactId>
</dependency>
<dependency>
<artifactId>amos-component-rule</artifactId>
<groupId>com.yeejoin</groupId>
</dependency>
</dependencies>
</project>
\ No newline at end of file
package com.yeejoin.amos.boot.module.jg.api.common;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
import java.io.Serializable;
import java.util.Date;
/**
* @description: 公共实体
* @author: duanwei
**/
@Data
public class BaseEntity implements Serializable {
private static final long serialVersionUID = -5464322936854328207L;
@TableId(type = IdType.ID_WORKER)
private Long id;
/**
* 创建时间
*/
@TableField(value = "create_date", fill = FieldFill.INSERT)
private Date createDate;
/**
* 更新时间
*/
@TableField(value = "update_time", fill = FieldFill.UPDATE)
private Date updateTime;
}
package com.yeejoin.amos.boot.module.jg.api.common;
import com.yeejoin.amos.boot.module.jg.api.enums.BaseExceptionEnum;
/**
* @Author cpp
* @Description基础异常类
* @Date 2023/4/23
*/
public class BaseException extends RuntimeException {
private static final long serialVersionUID = 194906846739586857L;
/**
* 错误码
*/
private int code;
/**
* 错误内容
*/
private String msg;
public BaseException(String msg) {
super(msg);
}
public BaseException(int code, String msg) {
super(msg);
this.code = code;
this.msg = msg;
}
public BaseException(BaseExceptionEnum baseExceptionEnum) {
super(baseExceptionEnum.getMsg());
this.msg = baseExceptionEnum.getMsg();
this.code = baseExceptionEnum.getCode();
}
public int getCode() {
return code;
}
public void setCode(int code) {
this.code = code;
}
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
}
package com.yeejoin.amos.boot.module.jg.api.common;
/**
* @Description: 通用常量类
* @Author: DELL
* @Date: 2021/5/26
*/
public interface BizCommonConstant {
/**
* 所有平台企业数据redisKey
*/
String COMPANY_TREE_REDIS_KEY = "REGULATOR_UNIT_TREE";
}
package com.yeejoin.amos.boot.module.jg.api.common;
import com.yeejoin.amos.boot.module.jg.api.enums.CommonErrorEnum;
/**
* @description: 共同异常类
* @author: duanwei
* @create: 2019-08-28 20:07
**/
public class CommonException extends BaseException {
private static final long serialVersionUID = 194906846739586857L;
/**
* 错误码
*/
private int code;
/**
* 错误内容
*/
private String msg;
public CommonException(int code, String msg) {
super(msg);
this.code = code;
this.msg = msg;
}
public CommonException(CommonErrorEnum menuExceptionEnum) {
super(menuExceptionEnum.getMsg());
this.msg = menuExceptionEnum.getMsg();
this.code = menuExceptionEnum.getCode();
}
@Override
public int getCode() {
return code;
}
@Override
public void setCode(int code) {
this.code = code;
}
@Override
public String getMsg() {
return msg;
}
@Override
public void setMsg(String msg) {
this.msg = msg;
}
}
package com.yeejoin.amos.boot.module.jg.api.common;
import org.springframework.util.Assert;
import java.io.Closeable;
import java.io.Flushable;
import java.io.IOException;
/**
* IO流拓展工具类,补充IOUtils新版本中废弃的closeQuietly
*
* @author King
* @since 2018/12/27 17:56
*/
public class ExtendedIOUtils {
public static void flush(Flushable... resources) throws IOException {
Assert.noNullElements(resources, "resources invalid");
int length = resources.length;
for (int i = 0; i < length; ++i) {
Flushable resource = resources[i];
if (resource != null) {
resource.flush();
}
}
}
public static void closeQuietly(Closeable... resources) {
int length = resources.length;
for (int i = 0; i < length; ++i) {
Closeable resource = resources[i];
if (resource != null) {
try {
resource.close();
} catch (IOException e) {
//ignore exception
}
}
}
}
}
package com.yeejoin.amos.boot.module.jg.api.common;
import java.util.HashMap;
import java.util.Map;
/**
* @Description: 全局单机缓存
* @Author: duanwei
* @Date: 2020/6/30
*/
public class GlobalCache {
/**
* 全局请求头
*/
public static Map<String, String> header = new HashMap<>();
/**
* 依赖参数容器
*/
public static Map<String, String> paramMap = new HashMap<>(1000);
}
package com.yeejoin.amos.boot.module.jg.api.common;
import lombok.Data;
/**
* @Author cpp
* @Description
* @Date 2023/4/23
*/
@Data
public class MobileLoginParam {
/**
* 注册类型:1-微信授权快捷登录;2-手机验证登录
*/
private int registerType;
/**
* 是否需要需要短信验证: true-验证; false-不验证
*/
private Boolean isNeedVerify;
/**
* 注册类型为1时使用:微信用户数据字段1,根据1、2进行数据解密,计算出手机号
*/
private String encryptedData;
/**
* 注册类型为1时使用:微信用户数据字段2,根据1、2进行数据解密,计算出手机号
*/
private String iv;
/**
*注册类型为1时使用:微信用户数据字段3,根据1、2、3进行数据解密,计算出手机号
*/
private String code;
/**
* 账号或手机号
*/
private String phoneNo;
/**
* 密码
*/
private String verifyCode;
}
\ No newline at end of file
package com.yeejoin.amos.boot.module.jg.api.common;
import java.math.BigDecimal;
import java.util.Collection;
import java.util.Map;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
* 字符串工具类
*
* @author as-youjun
*/
public class StringUtil {
private static Pattern NOT_ZERO_AT_THE_END = Pattern.compile("[1-9](\\d*[1-9])?");
private static Pattern numericPattern = Pattern.compile("-?[0-9]+\\.?[0-9]*");
private static Pattern NUMBER_PATTERN = Pattern.compile("-?[0-9]+(\\.[0-9]+)?");
/**
* 判断对象是否为空
*
* @param str
* @return
*/
public static boolean isNotEmpty(Object str) {
boolean flag = true;
if (str != null && !"".equals(str)) {
if (str.toString().length() > 0) {
flag = true;
}
} else {
flag = false;
}
return flag;
}
/***************************************************************************
* repeat - 通过源字符串重复生成N次组成新的字符串。
*
* @param src
* - 源字符串 例如: 空格(" "), 星号("*"), "浙江" 等等...
* @param num
* - 重复生成次数
* @return 返回已生成的重复字符串
* @version 1.0 (2006.10.10) Wilson Lin
**************************************************************************/
public static String repeat(String src, int num) {
StringBuffer s = new StringBuffer();
for (int i = 0; i < num; i++) {
s.append(src);
}
return s.toString();
}
/**
* 判断是否数字表示
*
* @param str 源字符串
* @return 是否数字的标志
*/
public static boolean isNumeric(String str) {
// 该正则表达式可以匹配所有的数字 包括负数
String bigStr;
try {
bigStr = new BigDecimal(str).toString();
} catch (Exception e) {
return false;//异常 说明包含非数字。
}
Matcher isNum = NUMBER_PATTERN.matcher(bigStr); // matcher是全匹配
if (!isNum.matches()) {
return false;
}
return true;
}
public static int toInt(String s) {
if (s != null && !"".equals(s.trim())) {
try {
return Integer.parseInt(s);
} catch (Exception e) {
return 0;
}
}
return 0;
}
public static boolean isEmpty(Collection collection) {
return collection == null || collection.isEmpty();
}
public static boolean isNotEmpty(Collection collection) {
return collection != null && collection.size() > 0;
}
public static boolean isEmpty(Map map) {
return map == null || map.isEmpty();
}
/**
* 截取前后都不是0的数字字符串
* <p>
* 12010102 => 12010102 12010100 => 120101 ab1201100b => 12011
*
* @param str
* @return
*/
public static String delEndZero(String str) {
Matcher mat = NOT_ZERO_AT_THE_END.matcher(str);
boolean rs = mat.find();
if (rs) {
return mat.group(0);
}
return null;
}
/**
* <pre>
* 移除字符串后面的0
* </pre>
*
* @param s
* @return
*/
public static String removeSufixZero(String s) {
if (s == null) {
return "";
}
while (s.endsWith("0")) {
if ("0".equals(s)) {
s = "";
break;
}
s = s.substring(0, s.length() - 1);
}
return s;
}
public static String transforCode(String code) {
if (code.endsWith("0000000")) {
code = code.substring(0, 1);
} else if (code.endsWith("000000")) {
code = code.substring(0, 2);
} else if (code.endsWith("0000")) {
code = code.substring(0, 4);
} else if (code.endsWith("00")) {
code = code.substring(0, 6);
}
return code;
}
}
package com.yeejoin.amos.boot.module.jg.api.enums;
/**
* @description: 基础枚举类
**/
public enum BaseExceptionEnum {
/**
* 请求成功
*/
SUCCESS(0, "请求成功"),
/**
* 系统繁忙
*/
SYSTEM_BUSY(100, "系统繁忙"),
/**
* 请求超时
*/
REQUEST_TIME_OUT(300, "请求超时"),
/**
* 参数错误
*/
PARAMETER_ERROR(400, "参数错误"),
/**
* 网络异常
*/
NETWORK_ERROR(404, "网络异常"),
/**
* 数据不存在
*/
DATA_NOT_EXISTS(600, "数据不存在"),
/**
* 无权访问
*/
ACCESSDENIED_ERROR(501, "无权访问"),
/**
* 请求已经过期
*/
REQUEST_EXPIRATION(406, "请求已经过期"),
/**
* 请求失败
*/
REQUEST_ERROR(407, "请求失败"),
/**
* 未知错误
*/
FAILURE(999, "未知错误");
private Integer code;
private String msg;
BaseExceptionEnum(Integer code, String msg) {
this.code = code;
this.msg = msg;
}
public Integer getCode() {
return code;
}
public void setCode(Integer code) {
this.code = code;
}
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
}
package com.yeejoin.amos.boot.module.jg.api.enums;
/**
* 通用错误码,code编码:10000000-10000999
*
* @author King
* @since 2018/12/14 10:30
*/
public enum CommonErrorEnum {
/**
* 服务器核心数据丢失
*/
SERVER_KEY_DATA_MISSING(10000000, "服务器核心数据丢失"),
/**
* 服务器数据查询错误
*/
SERVER_DATA_QUERY_ERROR(10000001, "服务器数据查询错误"),
/**
* 主键查询主键无效
*/
QUERY_PRIMARY_INVALID(10000002, "主键查询主键无效"),
/**
* 主键查询主键无效
*/
QUERY_ONE_PARAM_INVALID(10000003, "唯一性查询参数无效"),
/**
* 序列化异常
*/
SERIALIZATION_EXCEPTION(10000004, "序列化异常"),
/**
* 反序列化异常
*/
DESERIALIZATION_EXCEPTION(10000005, "反序列化异常"),
/**
* 入参无效
*/
PARAM_INVALID(10000006, "入参无效"),
/**
* 核心字段无效
*/
CRUCIAL_FIELD_INVALID(10000007, "核心字段无效"),
/**
* 解压缩异常
*/
DECOMPRESS_EXCEPTION(10000008, "解压缩异常"),
/**
* 缓存查询key值无效
*/
CACHE_QUERY_KEY_INVALID(10000009, "缓存查询key值无效"),
/**
* 缓存失效
*/
CACHE_LOSE_EFFICACY(10000010, "缓存失效"),
/**
* 未知错误
*/
UNKNOWN(10000999, "未知错误");
private Integer code;
private String msg;
CommonErrorEnum(Integer code, String msg) {
this.code = code;
this.msg = msg;
}
public Integer getCode() {
return code;
}
public void setCode(Integer code) {
this.code = code;
}
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
}
package com.yeejoin.amos.boot.module.jg.api.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import lombok.Data;
@Data
public class EquipExportVo {
@ExcelProperty(value = "管辖机构", index = 0)
String orgBranchName;
@ExcelProperty(value = "使用单位", index = 1)
String useUnitName;
@ExcelProperty(value = "设备种类", index = 2)
String equList;
@ExcelProperty(value = "设备类别", index = 3)
String equCategory;
@ExcelProperty(value = "使用登记证编号", index = 4)
String useOrgCode;
@ExcelProperty(value = "96333识别码", index = 5)
String code96333;
@ExcelProperty(value = "监管码", index = 6)
String supervisoryCode;
@ExcelProperty(value = "所属区域", index = 7)
String usePlace;
@ExcelProperty(value = "设备状态", index = 8)
String equState;
}
package com.yeejoin.amos.boot.module.jg.api.vo;
import lombok.Data;
import org.apache.http.client.methods.CloseableHttpResponse;
import java.io.InputStream;
/**
* @description: http封装响应对象
* @author: duanwei
* @create: 2019-08-08 13:30
**/
@Data
public class ResponeVo {
int code;
CloseableHttpResponse response;
String content;
byte[] inStream;
InputStream inputStream;
}
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>amos-boot-module-jg</artifactId>
<groupId>com.amosframework.boot</groupId>
<version>1.0.0</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>amos-boot-module-jg-biz</artifactId>
<dependencies>
<dependency>
<groupId>com.amosframework.boot</groupId>
<artifactId>amos-boot-module-app-api</artifactId>
<version>1.0.0</version>
</dependency>
<dependency>
<groupId>com.amosframework.boot</groupId>
<artifactId>amos-boot-module-common-biz</artifactId>
<version>${amos-biz-boot.version}</version>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpmime</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>2.7.8</version>
</plugin>
</plugins>
</build>
</project>
\ No newline at end of file
package com.yeejoin.amos;
import com.yeejoin.amos.boot.biz.common.utils.oConvertUtils;
import net.javacrumbs.shedlock.spring.annotation.EnableSchedulerLock;
import org.mybatis.spring.annotation.MapperScan;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.core.env.Environment;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.transaction.annotation.EnableTransactionManagement;
import springfox.documentation.swagger2.annotations.EnableSwagger2WebMvc;
import java.net.InetAddress;
import java.net.UnknownHostException;
/**
* <pre>
* 特种设备服务启动类
* </pre>
*
* @author DELL
*/
@SpringBootApplication
@EnableTransactionManagement
@EnableConfigurationProperties
@ServletComponentScan
@EnableDiscoveryClient
@EnableFeignClients
@EnableAsync
@EnableSwagger2WebMvc
@EnableEurekaClient
@EnableSchedulerLock(defaultLockAtMostFor = "10m")
@MapperScan({"org.typroject.tyboot.demo.face.orm.dao*", "org.typroject.tyboot.face.*.orm.dao*",
"org.typroject.tyboot.core.auth.face.orm.dao*", "org.typroject.tyboot.component.*.face.orm.dao*",
"com.yeejoin.amos.boot.module.**.api.mapper", "com.yeejoin.amos.boot.biz.common.dao.mapper"})
@ComponentScan(basePackages = {"org.typroject", "com.yeejoin.amos"})
public class AmosJGApplication {
private static final Logger logger = LoggerFactory.getLogger(AmosJGApplication.class);
public static void main(String[] args) throws UnknownHostException {
ConfigurableApplicationContext context = SpringApplication.run(AmosJGApplication.class, args);
Environment env = context.getEnvironment();
String ip = InetAddress.getLocalHost().getHostAddress();
String port = env.getProperty("server.port");
String path = oConvertUtils.getString(env.getProperty("server.servlet.context-path"));
logger.info("\n----------------------------------------------------------\n\t"
+ "Application Amos-JG is running! Access URLs:\n\t" + "Swagger文档: \thttp://" + ip + ":" + port
+ path + "/doc.html\n" + "----------------------------------------------------------");
}
}
package com.yeejoin.amos.boot.module.jg.biz.config;
import org.apache.http.HttpHost;
import org.apache.http.auth.AuthScope;
import org.apache.http.auth.UsernamePasswordCredentials;
import org.apache.http.client.CredentialsProvider;
import org.apache.http.impl.client.BasicCredentialsProvider;
import org.elasticsearch.client.RestClient;
import org.elasticsearch.client.RestClientBuilder;
import org.elasticsearch.client.RestHighLevelClient;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import java.util.Arrays;
@Configuration
public class ElasticSearchClientConfig {
@Value("${spring.elasticsearch.rest.uris}")
private String uris;
@Value("${elasticsearch.username}")
private String username;
@Value("${elasticsearch.password}")
private String password;
@Bean(destroyMethod = "close")
public RestHighLevelClient restHighLevelClient() {
final CredentialsProvider credentialsProvider = new BasicCredentialsProvider();
credentialsProvider.setCredentials(AuthScope.ANY,
new UsernamePasswordCredentials(username, password));
try {
HttpHost[] httpHosts = Arrays.stream(uris.split(",")).map(HttpHost::create).toArray(HttpHost[]::new);
RestClientBuilder builder = RestClient.builder(httpHosts);
builder.setHttpClientConfigCallback(httpClientBuilder -> {
httpClientBuilder.disableAuthCaching();
return httpClientBuilder.setDefaultCredentialsProvider(credentialsProvider);
});
// 该方法接收一个RequestConfig.Builder对象,对该对象进行修改后然后返回。
builder.setRequestConfigCallback(requestConfigBuilder -> {
// 连接超时(默认为1秒)
return requestConfigBuilder.setConnectTimeout(5000 * 1000)
// 套接字超时(默认为30秒)//更改客户端的超时限制默认30秒现在改为100*1000分钟
.setSocketTimeout(6000 * 1000);
});
return new RestHighLevelClient(builder);
} catch (Exception e) {
throw new IllegalStateException("Invalid ES nodes " + "property '" + uris + "'", e);
}
}
}
package com.yeejoin.amos.boot.module.jg.biz.config;
import com.baomidou.mybatisplus.annotation.DbType;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
@Configuration(value="MybatisPlusConfigs")
public class MybatisPlusConfigs {
@Bean
public PaginationInterceptor paginationInterceptors()
{
PaginationInterceptor paginationInterceptor = new PaginationInterceptor();
paginationInterceptor.setLimit(50000);
paginationInterceptor.setDialectType(DbType.POSTGRE_SQL.getDb());
return paginationInterceptor;
}
}
package com.yeejoin.amos.boot.module.jg.biz.config;
import net.javacrumbs.shedlock.core.LockProvider;
import net.javacrumbs.shedlock.provider.redis.spring.RedisLockProvider;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.redis.connection.RedisConnectionFactory;
/**
* @author Administrator
*/
@Configuration
public class ShedLockConfig {
@Bean
public LockProvider lockProvider(RedisConnectionFactory connectionFactory) {
return new RedisLockProvider(connectionFactory);
}
}
package com.yeejoin.amos.boot.module.jg.biz.core.async;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import java.util.concurrent.Executor;
@Configuration
public class TaskExecutorPoolConfig {
@Bean("asyncTaskExecutor")
public Executor taskExecutor() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
executor.setCorePoolSize(10);//线程池维护线程的最少数量
executor.setMaxPoolSize(100); //线程池维护线程的最大数量
executor.setQueueCapacity(100);
executor.setKeepAliveSeconds(30);//线程池维护线程所允许的空闲时间,TimeUnit.SECONDS
executor.setThreadNamePrefix("asyncTaskExecutor-");
// 线程池对拒绝任务的处理策略: CallerRunsPolicy策略,当线程池没有处理能力的时候,该策略会直接在 execute 方法的调用线程中运行被拒绝的任务;如果执行程序已关闭,则会丢弃该任务
// executor.setRejectedExecutionHandler(ThreadPoolExecutor.CallerRunsPolicy());
return executor;
}
}
package com.yeejoin.amos.boot.module.jg.biz.core.threadpool;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
/**
* 线程池
*/
public class AmosThreadPool {
/**
* 日志记录器
*/
private static final Logger log = LoggerFactory.getLogger(AmosThreadPool.class);
/**
* 单例
*/
private static AmosThreadPool instance;
/**
* 执行服务
*/
private static ExecutorService executorService;
/**
* 获取单例
*
* @return
*/
public static AmosThreadPool getInstance() {
if (instance == null) {
synchronized (AmosThreadPool.class) {
if (instance == null) {
instance = new AmosThreadPool();
}
}
}
return instance;
}
static {
executorService = Executors
.newFixedThreadPool(20);
}
/**
* 执行线程
*
* @param task
*/
public void execute(Runnable task) {
executorService.execute(task);
}
}
package com.yeejoin.amos.boot.module.jg.biz.utils;
import com.alibaba.fastjson.JSONObject;
import org.apache.commons.io.IOUtils;
import org.springframework.core.io.Resource;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.util.Map;
public class JsonUtils {
//将json文件转化为Map<list<Map<>>>
public static Map getResourceJson(Resource resource) {
String json = null;
try {
json = IOUtils.toString(resource.getInputStream(), String.valueOf(StandardCharsets.UTF_8));
} catch (IOException e) {
throw new RuntimeException(resource + "json文件转化失败");
}
return JSONObject.parseObject(json, Map.class);
}
}
package com.yeejoin.amos.boot.module.jg.biz.utils;
import java.util.Map;
import java.util.StringJoiner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
* @Author: xl
* @Description:
* @Date: 2022/8/4 9:08
*/
public class StringUtils {
public static StringJoiner getWhereSql(String operator, Map<String, String> map){
StringJoiner stringJoiner = new StringJoiner(" " + operator +" ");
for (Map.Entry entry :map.entrySet()) {
stringJoiner.add(entry.getKey() + "=" + str2sqlValue(entry.getValue().toString()));
}
return stringJoiner;
}
public static String str2sqlValue(String str){
return "'" + str + "'";
}
public static String getStrByPattern(String str, Pattern reg){
Matcher mat = reg.matcher(str);
while (mat.find()) {
return mat.group(0);
}
return "";
}
}
spring.datasource.url=jdbc:vastbase://${POSTGRESQL_IP_port}/${POSTGRESQL_NAME}?currentSchema=${TZS_IDX_BIZ_DATABASE}&serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&autoReconnect=true&useSSL=false&noAccessToProcedureBodies=true&allowMultiQueries=true
spring.datasource.username=${POSTGRESQL_USER}
spring.datasource.password=${POSTGRESQL_PASSWORD}
#注册中心地址
eureka.client.service-url.defaultZone =http://admin:a1234560@192.168.249.13:10001/eureka/,http://admin:a1234560@192.168.249.139:10001/eureka/
eureka.instance.prefer-ip-address=true
eureka.instance.ip-address = 192.168.249.139
management.endpoint.health.show-details=always
management.endpoints.web.exposure.include=*
eureka.instance.health-check-url=http://elevator:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.metadata-map.management.context-path=${server.servlet.context-path}/actuator
eureka.instance.status-page-url=http://elevator:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.metadata-map.management.api-docs=http://elevator:${server.port}${server.servlet.context-path}/doc.html
## ES properties:
spring.elasticsearch.rest.uris=${ELASTICSEARCH_REST_URIS}
elasticsearch.username=${ELASTICSEARCH_USERNAME}
elasticsearch.password= ${ELASTICSEARCH_PASSWORD}
## unit(h)
alertcall.es.synchrony.time=48
#redis properties:
spring.redis.cluster.nodes=${REDIS_CLUSTER_NODES}
spring.redis.password=${REDIS_PASSWORD}
spring.redis.cluster.max-redirects=3
spring.redis.timeout=10000
spring.redis.lettuce.cluster.refresh.adaptive=true
spring.redis.lettuce.cluster.refresh.period=2000
spring.redis.mode=cluster
#springboot指标显示器不使用默认的,使用自定义的MyRedisHealthIndicator
management.health.redis.enabled=false
##emqx
emqx.clean-session=true
emqx.client-id=${spring.application.name}-${random.int[1024,65536]}
emqx.broker=${EMQX_BROKER}
emqx.client-user-name=${EMQX_USER}
emqx.client-password=${EMQX_PASSWORD}
tzs.cti.appkey=0a1b1cf1-a55b-447a-d275-02931f13b2fa
tzs.cti.secretkey=cae7c0f8-a7b8-9876-d69b-3eba8262898a
tzs.cti.url=http://192.168.249.178:8000
##wechatToken
tzs.wechat.token=yeejoin_2021
##wechatTicketUrl
tzs.wechat.ticketurl=https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=
#tzs.wechat.tempId.kr=rjW8x9rRitIpa21Jekyx2nzBzpJy7tycssCXSN4YhWw
tzs.wechat.tempId.kr=bxchKYhYW7aHbGKM2pVyR_yY2-bG4sRMNU3ZRQbMKYM
tzs.wechat.url.kr=tzs.yeeamos.com/persondetail.html
#tzs.wechat.tempId.wx=ofBIZS8Bup9s0zKbrGa8BfhVhS18H_hyC_OYXuBN6hI
tzs.wechat.tempId.wx=rags-expfNSBB-h2WenuBI2c6pCEndH4uwTtOqlHqDM
tzs.wechat.url.wx=tzs.yeeamos.com/repairPersondetail.html
#tzs.wechat.tempId.ts=Kr7lcV8g4g_lgyW_RpwnNgw_HDxxRuVx759EoFWrIfU
tzs.wechat.tempId.ts=VWqgY-lXFt4dg2EL4pLjfDCBAU49Z0mRxVaQhAMMW8Q
tzs.wechat.url.ts=tzs.yeeamos.com/taskComplaintDetail.html
mqtt.topic.task.newtask=tzs-task-newtask
mqtt.topic.task.personinfo=tzs-task-personinfo
mqtt.topic.elevator.push=/tzs/tcb_elevator
mqtt.topic.alertInfo.push=/tzs/tcb_alertInfo
mqtt.topic.alertReport.push=/tzs/tcb_alertReport
mqtt.topic.alertHeart.push=/tzs/tcb_alertHeart
mqtt.topic.alertMatrix.push=/tzs/tcb_alertMatrix
mqtt.topic.cti.push=/cti/record
cti.user.name=tzs_cti
cti.user.pwd=a1234567
flc.sms.tempCode=SMS_TZS_0001
## 预警通知模板id
tzs.wechat.tempId.warning=-pHsHLIjW8j-_AemoZycf6Dmu6iYc-YWWaJ0cAPGeUY
##督查整改通知
tzs.wechat.tempId.supervise=P5XGbszS2Pc6kynvGjzPpZ--ikAwDZo6O7WdJ2EUxtE
## 公众号测试用户id(平台userId)
tzs.wechat.test.userId=3413513
fileserver.domain=https://rpm.yeeamos.com:8888/
org.filter.group.seq=1564150103147573249
duty.seats.role.ids=1585956200472674305,1585956257590706177
## 规则配置 properties:
rule.definition.load=false
##rule.definition.model-package=com.yeejoin.amos.boot.module.jcs.api.dto
rule.definition.default-agency=tzs
rule.definition.local-ip=192.168.249.139
tzs.auth.user.photo=/public/common/userPic.png
minio.url.path=${MINIO_FILESERVER_DOMAIN}/
#### 管理员变更机器人账号
tzs.admin.name=tzs_robot
tzs.admin.pwd=a1234567
##小程序appid
tzs.WxApp.appId=wx48a1b1915b10d14b
tzs.WxApp.secret=ac4f4a9d3c97676badb70c19a2f37b16
tzs.WxApp.grant-type=authorization_code
#气瓶充装信息定时同步至es
tzs.cylinder.fill.cron=0 0 12 * * ?
#气瓶基本信息定时同步至es
tzs.cylinder.info.cron=0 0 1 * * ?
outSystem.user.password=a1234560
amos.system.user.app-key=AMOS_STUDIO
amos.system.user.product=STUDIO_APP_WEB
##生成监管码前缀域名
regulatory_code_prefix=https://nav.sspai.top/tzs?code=
#DB properties:
spring.datasource.url=jdbc:vastbase://36.46.137.116:5432/tzs_amos_tzs_biz_init?currentSchema=amos_tzs_biz&allowMultiQueries=true
spring.datasource.username=admin
spring.datasource.password=Yeejoin@2023
eureka.client.service-url.defaultZone=http://172.16.10.210:10001/eureka/
eureka.instance.prefer-ip-address=true
management.endpoint.health.show-details=always
management.endpoints.web.exposure.include=*
eureka.instance.health-check-url=http://172.16.3.68:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.metadata-map.management.context-path=${server.servlet.context-path}/actuator
eureka.instance.status-page-url=http://172.16.3.68:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.metadata-map.management.api-docs=http://172.16.3.68:${server.port}${server.servlet.context-path}/doc.html
eureka.instance.ip-address=172.16.3.68
## ES properties:
elasticsearch.username=elastic
elasticsearch.password=a123456
spring.elasticsearch.rest.uris=http://172.16.10.210:9200
## unit(h)
alertcall.es.synchrony.time=48
#redis properties:
spring.redis.database=1
spring.redis.host=172.16.10.210
spring.redis.port=16379
spring.redis.password=yeejoin@2020
spring.redis.lettuce.pool.max-active=200
spring.redis.lettuce.pool.max-wait=-1
spring.redis.lettuce.pool.max-idle=10
spring.redis.lettuce.pool.min-idle=0
## emqx properties:
emqx.clean-session=false
emqx.client-id=${spring.application.name}-${random.int[1024,65536]}
emqx.broker=tcp://36.46.151.113:1883
emqx.client-user-name=super
emqx.client-password=123456
emqx.keepAliveInterval=1000
tzs.cti.appkey=4e805006-3fef-ae43-3915-a153731007c4
tzs.cti.secretkey=7bd29115-99ee-4f7d-1fb1-7c4719d5f43a
tzs.cti.url=http://36.41.172.83:8000
##wechatToken
tzs.wechat.token=yeejoin_2021
##wechatTicketUrl
tzs.wechat.ticketurl=https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=
#tzs.wechat.tempId.kr=rjW8x9rRitIpa21Jekyx2nzBzpJy7tycssCXSN4YhWw
tzs.wechat.tempId.kr=bxchKYhYW7aHbGKM2pVyR_yY2-bG4sRMNU3ZRQbMKYM
tzs.wechat.url.kr=tzs.yeeamos.com/persondetail.html
#tzs.wechat.tempId.wx=ofBIZS8Bup9s0zKbrGa8BfhVhS18H_hyC_OYXuBN6hI
tzs.wechat.tempId.wx=rags-expfNSBB-h2WenuBI2c6pCEndH4uwTtOqlHqDM
tzs.wechat.url.wx=tzs.yeeamos.com/repairPersondetail.html
#tzs.wechat.tempId.ts=Kr7lcV8g4g_lgyW_RpwnNgw_HDxxRuVx759EoFWrIfU
tzs.wechat.tempId.ts=VWqgY-lXFt4dg2EL4pLjfDCBAU49Z0mRxVaQhAMMW8Q
tzs.wechat.url.ts=tzs.yeeamos.com/taskComplaintDetail.html
mqtt.topic.task.newtask=tzs-task-newtask
mqtt.topic.task.personinfo=tzs-task-personinfo
mqtt.topic.elevator.push=/tzs/tcb_elevator
mqtt.topic.alertInfo.push=/tzs/tcb_alertInfo
mqtt.topic.alertReport.push=/tzs/tcb_alertReport
mqtt.topic.alertHeart.push=/tzs/tcb_alertHeart
mqtt.topic.alertMatrix.push=/tzs/tcb_alertMatrix
mqtt.topic.cti.push=/cti/record
cti.user.name=tzs_cti
cti.user.pwd=a1234567
flc.sms.tempCode=SMS_TZS_0001
## ??????id
tzs.wechat.tempId.warning=-pHsHLIjW8j-_AemoZycf6Dmu6iYc-YWWaJ0cAPGeUY
##??????
tzs.wechat.tempId.supervise=P5XGbszS2Pc6kynvGjzPpZ--ikAwDZo6O7WdJ2EUxtE
## ???????id???userId?
tzs.wechat.test.userId=3413513
##new properties
org.filter.group.seq=1564150103147573249
fileserver.domain=http://172.16.10.210:19000/
log.level=INFO
duty.seats.role.ids=1585956200472674305,1585956257590706177
## ???? properties:
rule.definition.load=false
##rule.definition.model-package=com.yeejoin.amos.boot.module.jcs.api.dto
rule.definition.default-agency=tzs
rule.definition.local-ip=172.16.10.210
# ??????????
minio.url.path=http://172.16.10.210:9000/
## \uFFFD\uFFFD\uFFFD\u027C\uFFFD\uFFFD\uFFFD\uFFFD\u01F0\u05FA\uFFFD\uFFFD\uFFFD\uFFFD
regulatory_code_prefix=https://sxtzsb.sxsei.com:19435/tzs?code=
outSystem.user.password=a1234560
amos.system.user.app-key=AMOS_STUDIO
amos.system.user.product=STUDIO_APP_WEB
\ No newline at end of file
spring.application.name=TZS-JG
server.servlet.context-path=/jg
server.port=11007
spring.profiles.active=dev
spring.jackson.time-zone=GMT+8
spring.jackson.date-format=yyyy-MM-dd HH:mm:ss
logging.config=classpath:logback-${spring.profiles.active}.xml
mybatis-plus.configuration.log-impl=org.apache.ibatis.logging.stdout.StdOutImpl
logging.level.net.javacrumbs.shedlock=DEBUG
##liquibase
spring.liquibase.change-log = classpath:/db/changelog/changelog-master.xml
spring.liquibase.enabled= false
feign.client.config.default.connect-timeout=30000
feign.client.config.default.read-timeout=30000
## eureka properties:
eureka.client.registry-fetch-interval-seconds=5
eureka.instance.prefer-ip-address=true
management.endpoint.health.show-details=always
management.endpoints.web.exposure.include=*
eureka.instance.health-check-url-path=/actuator/health
eureka.instance.lease-expiration-duration-in-seconds=10
eureka.instance.lease-renewal-interval-in-seconds=5
eureka.instance.metadata-map.management.context-path=${server.servlet.context-path}/actuator
eureka.instance.status-page-url-path=/actuator/info
eureka.instance.metadata-map.management.api-docs=http://localhost:${server.port}${server.servlet.context-path}/doc.html
#DB properties:
spring.datasource.driver-class-name=cn.com.vastbase.Driver
spring.datasource.type=com.zaxxer.hikari.HikariDataSource
spring.datasource.hikari.minimum-idle=10
spring.datasource.hikari.maximum-pool-size=25
spring.datasource.hikari.auto-commit=true
spring.datasource.hikari.idle-timeout=30000
spring.datasource.hikari.pool-name=DatebookHikariCP
spring.datasource.hikari.max-lifetime=120000
spring.datasource.hikari.connection-timeout=30000
spring.datasource.hikari.connection-test-query=SELECT 1
spring.main.allow-bean-definition-overriding=true
iot.fegin.name=AMOS-API-IOT
equip.fegin.name=AMOS-EQUIPMANAGE
supervision.feign.name = AMOS-SUPERVISION-API
security.systemctl.name=AMOS-API-SYSTEMCTL
jcs.company.topic.add=jcs/company/topic/add
jcs.company.topic.delete=jcs/company/topic/delete
## \uFFFD\u8C78\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uD94E\uDE33\uFFFD\uFFFD\uFFFD\uFFFD\u0161\uFFFD\uFFFD\u3CA5\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\u58E9
control.fegin.name=JCS-API-CONTROL
## redis\uFFFD\uFFFD\u02B1\u02B1\uFFFD\uFFFD
redis.cache.failure.time=10800
failure.work.flow.processDefinitionKey=malfunction_repair
video.fegin.name=video
latentDanger.feign.name=AMOS-LATENT-DANGER
Knowledgebase.fegin.name=AMOS-API-KNOWLEDGEBASE
## \uFFFD\u8C78\uFFFD\uFFFD\u05AA\uFFFD\uFFFD\uFFFD\uFFFDv1
inform.work.flow.processDefinitionKey=equipment_inform_process_v1
## \uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\u052E\uFFFD\uFFFD\uFFFD\u03F2\uFFFDID
fire-rescue=1432549862557130753
tzs.cti.appkey=4e805006-3fef-ae43-3915-a153731007c4
tzs.cti.secretkey=7bd29115-99ee-4f7d-1fb1-7c4719d5f43a
tzs.wechat.url=https://api.weixin.qq.com
tzs.wechat.appid=wx79aca5bb1cb4af92
tzs.wechat.secret=f3a12323ba731d282c3d4698c27c3e97
##wechatToken
tzs.wechat.token=yeejoin_2021
##wechatTicketUrl
tzs.wechat.ticketurl=https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=
#tzs.wechat.tempId.kr=rjW8x9rRitIpa21Jekyx2nzBzpJy7tycssCXSN4YhWw
tzs.wechat.tempId.kr=bxchKYhYW7aHbGKM2pVyR_yY2-bG4sRMNU3ZRQbMKYM
tzs.wechat.url.kr=tzs.yeeamos.com/persondetail.html
#tzs.wechat.tempId.wx=ofBIZS8Bup9s0zKbrGa8BfhVhS18H_hyC_OYXuBN6hI
tzs.wechat.tempId.wx=rags-expfNSBB-h2WenuBI2c6pCEndH4uwTtOqlHqDM
tzs.wechat.url.wx=tzs.yeeamos.com/repairPersondetail.html
#tzs.wechat.tempId.ts=Kr7lcV8g4g_lgyW_RpwnNgw_HDxxRuVx759EoFWrIfU
tzs.wechat.tempId.ts=VWqgY-lXFt4dg2EL4pLjfDCBAU49Z0mRxVaQhAMMW8Q
tzs.wechat.url.ts=tzs.yeeamos.com/taskComplaintDetail.html
mqtt.topic.task.newtask=tzs-task-newtask
mqtt.topic.task.personinfo=tzs-task-personinfo
mqtt.topic.elevator.push=/tzs/tcb_elevator
mqtt.topic.alertInfo.push=/tzs/tcb_alertInfo
mqtt.topic.alertReport.push=/tzs/tcb_alertReport
mqtt.topic.alertHeart.push=/tzs/tcb_alertHeart
mqtt.topic.alertMatrix.push=/tzs/tcb_alertMatrix
mqtt.topic.cti.push=/cti/record
mqtt.topic.cyl.warning.push=/tzs/cyl_cyl_warning
cti.user.name=tzs_cti
cti.user.pwd=a1234567
flc.sms.tempCode=SMS_TZS_0001
### \u7BA1\u7406\u5458\u53D8\u66F4\u673A\u5668\u4EBA\u8D26\u53F7
#tzs.admin.name=tzs_admin
## \u0524\uFFFD\uFFFD\u0368\u05AA\u0123\uFFFD\uFFFDid
tzs.wechat.tempId.warning=-pHsHLIjW8j-_AemoZycf6Dmu6iYc-YWWaJ0cAPGeUY
##\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\u0368\u05AA
tzs.wechat.tempId.supervise=P5XGbszS2Pc6kynvGjzPpZ--ikAwDZo6O7WdJ2EUxtE
## \uFFFD\uFFFD\uFFFD\u06BA\u0172\uFFFD\uFFFD\uFFFD\uFFFD\u00FB\uFFFDid\uFFFD\uFFFD\u01BD\u0328userId\uFFFD\uFFFD
tzs.wechat.test.userId=3393279
amos.secret.key=qazknife4j.production=false
knife4j.production=false
knife4j.enable=true
knife4j.basic.enable=true
knife4j.basic.username=admin
knife4j.basic.password=a1234560
spring.security.user.name=admin
spring.security.user.password=a1234560
spring.security.user.roles=SBA_ADMIN
## \u540E\u53F0\u6267\u884C\u673A\u5668\u4EBA\u8D26\u53F7\u914D\u7F6E
amos.system.user.user-name=robot_admin
amos.system.user.password=a1234567
amos.system.user.app-key=AMOS_STUDIO
amos.system.user.product=AMOS_STUDIO_WEB
## ??????????????topic
amos.operation.log=$share/${spring.application.name}//amos/operation/log
amos.agency.code=tzs
## ?????orgCode
regulator.unit.code=50
# \u82E5tzs\u548Cugp\u4E00\u8D77\uFF0C\u5219true
is.ugp=false
#\u5DE5\u4F5C\u53F0\u7528\u6237\u7EDF\u4E00\u663E\u793A\u5934\u50CF
tzs.auth.user.photo=/public/common/userPic.png
tzs.WxApp.appId=wx48a1b1915b10d14b
tzs.WxApp.secret=ac4f4a9d3c97676badb70c19a2f37b16
tzs.WxApp.grant-type=authorization_code
amos.wechat.robot.user=we_robot
amos.wechat.robot.password=a1234567
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<configuration debug="false">
<!--定义日志文件的存储地址 勿在 LogBack 的配置中使用相对路径-->
<property name="LOG_HOME" value="log" />
<!--格式化输出:%d表示日期,%thread表示线程名,%-5level:级别从左显示5个字符宽度%msg:日志消息,%n是换行符-->
<property name="LOG_PATTERN" value="%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %-50.50logger{50} - %msg [%file:%line] %n" />
<!-- 按照每天生成日志文件 -->
<appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<!--日志文件输出的文件名-->
<FileNamePattern>${LOG_HOME}/Tcm.log.%d{yyyy-MM-dd}.%i.log</FileNamePattern>
<!--日志文件保留天数-->
<MaxHistory>30</MaxHistory>
<!--日志文件大小-->
<MaxFileSize>30mb</MaxFileSize>
</rollingPolicy>
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>${LOG_PATTERN}</pattern>
</encoder>
</appender>
<!-- 控制台输出 -->
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>${LOG_PATTERN}</pattern>
</encoder>
</appender>
<!-- &lt;!&ndash; ELK管理 &ndash;&gt;-->
<!-- <appender name="ELK" class="net.logstash.logback.appender.LogstashTcpSocketAppender">-->
<!-- <destination>172.16.10.210:4560</destination>-->
<!-- <encoder charset="UTF-8" class="net.logstash.logback.encoder.LogstashEncoder"/>-->
<!-- </appender>-->
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
<logger name="org.hibernate.SQL" level="DEBUG" />
<logger name="org.hibernate.engine.QueryParameters" level="DEBUG" />
<logger name="org.hibernate.engine.query.HQLQueryPlan" level="DEBUG" />
-->
<!--myibatis log configure-->
<logger name="com.apache.ibatis" level="debug"/>
<logger name="org.mybatis" level="debug" />
<logger name="java.sql.Connection" level="debug"/>
<logger name="java.sql.Statement" level="debug"/>
<logger name="java.sql.PreparedStatement" level="debug"/>
<logger name="org.springframework" level="debug"/>
<logger name="com.baomidou.mybatisplus" level="debug"/>
<logger name="org.apache.activemq" level="debug"/>
<logger name="org.typroject" level="debug"/>
<logger name="com.yeejoin" level="debug"/>
<!-- 日志输出级别 -->
<root level="error">
<!-- <appender-ref ref="FILE" /> -->
<appender-ref ref="STDOUT" />
<!-- <appender-ref ref="ELK" />-->
</root>
</configuration>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<configuration debug="false">
<!--定义日志文件的存储地址 勿在 LogBack 的配置中使用相对路径-->
<property name="LOG_HOME" value="log" />
<!--格式化输出:%d表示日期,%thread表示线程名,%-5level:级别从左显示5个字符宽度%msg:日志消息,%n是换行符-->
<property name="LOG_PATTERN" value="%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %-50.50logger{50} - %msg [%file:%line] %n" />
<!-- 按照每天生成日志文件 -->
<appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<!--日志文件输出的文件名-->
<FileNamePattern>${LOG_HOME}/96333.log.%d{yyyy-MM-dd}.%i.log</FileNamePattern>
<!--日志文件保留天数-->
<MaxHistory>30</MaxHistory>
<!--日志文件大小-->
<MaxFileSize>30mb</MaxFileSize>
</rollingPolicy>
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>${LOG_PATTERN}</pattern>
</encoder>
</appender>
<!-- 控制台输出 -->
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>${LOG_PATTERN}</pattern>
</encoder>
</appender>
<!-- &lt;!&ndash; ELK管理 &ndash;&gt;-->
<!-- <appender name="ELK" class="net.logstash.logback.appender.LogstashTcpSocketAppender">-->
<!-- <destination>172.16.10.210:4560</destination>-->
<!-- <encoder charset="UTF-8" class="net.logstash.logback.encoder.LogstashEncoder"/>-->
<!-- </appender>-->
<!-- show parameters for hibernate sql 专为 Hibernate 定制
<logger name="org.hibernate.type.descriptor.sql.BasicBinder" level="TRACE" />
<logger name="org.hibernate.type.descriptor.sql.BasicExtractor" level="DEBUG" />
<logger name="org.hibernate.SQL" level="DEBUG" />
<logger name="org.hibernate.engine.QueryParameters" level="DEBUG" />
<logger name="org.hibernate.engine.query.HQLQueryPlan" level="DEBUG" />
-->
<!--myibatis log configure-->
<logger name="com.apache.ibatis" level="INFO"/>
<logger name="org.mybatis" level="INFO" />
<logger name="java.sql.Connection" level="INFO"/>
<logger name="java.sql.Statement" level="INFO"/>
<logger name="java.sql.PreparedStatement" level="INFO"/>
<logger name="org.springframework" level="INFO"/>
<logger name="com.baomidou.mybatisplus" level="INFO"/>
<logger name="org.apache.activemq" level="INFO"/>
<logger name="org.typroject" level="INFO"/>
<logger name="com.yeejoin" level="INFO"/>
<!-- 日志输出级别 -->
<root level="DEBUG">
<!-- <appender-ref ref="FILE" /> -->
<appender-ref ref="STDOUT" />
<!-- <appender-ref ref="ELK" />-->
</root>
</configuration>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>amos-boot-system-tzs</artifactId>
<groupId>com.amosframework.boot</groupId>
<version>1.0.0</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>amos-boot-module-jg</artifactId>
<description>监管模块</description>
<packaging>pom</packaging>
<version>1.0.0</version>
<modules>
<module>amos-boot-module-jg-api</module>
<module>amos-boot-module-jg-biz</module>
</modules>
</project>
\ No newline at end of file
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
<module>amos-boot-module-tcm</module> <module>amos-boot-module-tcm</module>
<module>amos-boot-module-app</module> <module>amos-boot-module-app</module>
<module>amos-boot-module-tzspatrol</module> <module>amos-boot-module-tzspatrol</module>
<module>amos-boot-module-jg</module>
</modules> </modules>
<properties> <properties>
<amos.version.tzs>1.8.5</amos.version.tzs> <amos.version.tzs>1.8.5</amos.version.tzs>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment