Commit 615903e1 authored by 黄福新's avatar 黄福新

[add] 增加databus

[update]  traffic-signal-platform增加nacos配置
parent 4b6762eb
......@@ -79,6 +79,29 @@
<version>${mybatis-plus-version}</version>
</dependency>
<!-- MP相关 end -->
<dependency>
<groupId>com.alibaba.cloud</groupId>
<artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
<version>2.2.1.RELEASE</version>
<exclusions>
<exclusion>
<groupId>com.alibaba.nacos</groupId>
<artifactId>nacos-client</artifactId>
</exclusion>
</exclusions>
</dependency>
<!--nacos客户端依赖-->
<dependency>
<groupId>com.xkcoding.nacos</groupId>
<artifactId>nacos-client</artifactId>
<version>1.1.4</version>
</dependency>
<!--spring boot 集成 nacos 配置中心-->
<dependency>
<groupId>com.alibaba.boot</groupId>
<artifactId>nacos-config-spring-boot-starter</artifactId>
<version>0.2.1</version>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-validator</artifactId>
......
......@@ -7,7 +7,7 @@ import java.util.List;
/**
* EnvConstants.java
*
* @author mapabc
* @author wanji
*/
public final class Constants {
/*记录当前用户*/
......@@ -356,7 +356,7 @@ public final class Constants {
/**
* @Description: 网关表,类型相关参数
* @return
* @Author mapabc8
* @Author wanji
* @Date 2020/2/14 10:10
**/
public static class ServiceType {
......@@ -530,7 +530,7 @@ public final class Constants {
/**
* @Description: sqlserver 的字段类型
* @return
* @Author mapabc8
* @Author wanji
* @Date 2020/3/12 17:47
**/
public final static class SqlServerColumn {
......
......@@ -15,7 +15,7 @@ import java.util.Properties;
/**
* 资源文件帮助类,加载配置信息
*
* @author mapabc
* @author wanji
* @date 2016/10/27
*/
@Slf4j
......
......@@ -7,7 +7,7 @@ import java.util.List;
import java.util.Properties;
/**
* @author mapabc
* @author wanji
* @date 2016/10/27
*/
public class SafeProperties extends Properties {
......
......@@ -19,7 +19,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
* <p>
* 执行Sql:使用apache common的 DbUtils工具类进行操作。
*
* @Author mapabc6
* @Author wanji
* @Date 2020/3/11 16:10
*/
public interface DbInterface {
......
......@@ -19,7 +19,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* Mysql数据库的基础操作接口实现
*
* @author mapabc
* @author wanji
*/
@Slf4j
public class MysqlDBImpl implements DbInterface {
......
......@@ -20,7 +20,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* Oracle数据库的基础操作接口实现
*
* @author mapabc
* @author wanji
*/
@Slf4j
public class OracleDBImpl implements DbInterface {
......
......@@ -22,7 +22,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* Mysql数据库的基础操作接口实现
*
* @author mapabc
* @author wanji
*/
@Slf4j
public class PostgresqlDBImpl implements DbInterface {
......
......@@ -21,7 +21,7 @@ import static net.wanji.common.framework.Constants.SqlServerColumn.DATETIME2;
/**
* SQLServer 数据库的基础操作接口实现
*
* @author mapabc
* @author wanji
*/
@Slf4j
public class SQLServerDBImpl implements DbInterface {
......
......@@ -7,7 +7,7 @@ import java.lang.annotation.Target;
/**
* @Description:
* @Author mapabc4
* @Author wanji
* @Date 2019/12/16 15:13
*/
@Retention(RetentionPolicy.RUNTIME)
......
......@@ -10,7 +10,7 @@ import java.util.Date;
/**
* 业务表模块操作日志实体类。
*
* @Author guoliang.dong@mapabc.com
* @Author guoliang.dong@wanji.com
* @Date 2021/12/22 17:30
*/
@Data
......
......@@ -7,7 +7,7 @@ import lombok.Data;
/**
* 导入表
*
* @author mapabc6
* @author wanji
* @date 2020/3/18
*/
@Data
......
......@@ -16,7 +16,7 @@ import java.util.Map;
/**
* 继承自该类的entity表示是可被跟踪的,可以查询对应实体
*
* @author mapabc5
* @author wanji
*/
@Getter
@Setter
......
......@@ -10,7 +10,7 @@ import lombok.Data;
* 包括sql语句,查询参数和sql查询运行结果。
* 其中,前两者为了方便aop日志记录。
*
* @Author mapabc6
* @Author wanji
* @Date 2020/4/7 14:07
*/
@Data
......
......@@ -12,7 +12,7 @@ import java.util.Map;
* dubbo抽象接口, 所有dubbo的接口都需要继承
*
* @param <Entity>
* @author mapabc
* @author wanji
*/
public interface BaseDubboInterface<Entity extends TrackableEntity> {
......
......@@ -25,7 +25,7 @@ import java.util.*;
import static net.wanji.common.framework.Constants.LogType.OPERATION_LOG;
/**
* @author mapabc
* @author wanji
*/
@Transactional(rollbackFor = Exception.class)
@Slf4j
......
......@@ -21,7 +21,7 @@ import java.util.Queue;
import java.util.concurrent.ArrayBlockingQueue;
/**
* @author mapabc
* @author wanji
*/
@Slf4j
public abstract class BaseLogInterfaceImpl implements BaseLogInterface {
......
......@@ -4,7 +4,7 @@ import org.springframework.context.ApplicationEvent;
/**
* @Description: spring 事件驱动模型,定义事件源
* @Author mapabc
* @Author wanji
* @Date 2020/3/22 16:49
*/
public abstract class BaseEvent<T> extends ApplicationEvent {
......
package net.wanji.common.framework.exception;
/**
* @author mapabc
* @author wanji
* @date 2016/10/27
*/
public class DubboProviderException extends Exception {
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.exception;
/**
* 类描述: bpmn20.xml写入异常
*
* @Author mapabc
* @Author wanji
* @Date 2019/8/5 19:25
*/
public class Json2BpmnXmlException extends Exception {
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.exception;
/**
* 节点异常处理
*
* @author mapabc4
* @author wanji
*/
public class NodeException extends Exception {
public NodeException(Exception e) {
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.exception;
/**
* 类描述: 流程服务异常
*
* @Author mapabc
* @Author wanji
* @Date 2019/8/5 19:25
*/
public class ProcessServiceException extends Exception {
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.exception;
/**
* l流程异常处理
*
* @author mapabc4
* @author wanji
*/
public class WorkFlowException extends Exception {
public WorkFlowException(Exception e) {
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.i18n;
/**
* @Description:国际化中,中文定义的词条
* @return
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 11:19
**/
public final class Constants {
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.i18n;
/**
* @Description:国际化中,英文定义的词条
* @return
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 11:19
**/
public final class Constants_en {
......
......@@ -5,7 +5,7 @@ import java.lang.reflect.Field;
/**
* @Description: 国际化词条自动处理工具类
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 11:20
**/
public final class I18nResourceBundle {
......@@ -15,7 +15,7 @@ public final class I18nResourceBundle {
* 例:I18nResourceBundle.language = "en"
* 修改后在通过I18nResourceBundle.getConstants("key")获取的值即可动态改变
* @return
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 11:20
**/
public static volatile String language = "zh";
......@@ -23,7 +23,7 @@ public final class I18nResourceBundle {
/**
* @Description: 当前支持的国际化语言,后续补充直接扩充枚举常量即可
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 11:21
**/
public enum LANGUAGE {
......@@ -38,7 +38,7 @@ public final class I18nResourceBundle {
/**
* @Description: 工具类私有化构造函数,安全性考虑,禁止通过外部实例化
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 11:22
**/
private I18nResourceBundle() {
......@@ -52,7 +52,7 @@ public final class I18nResourceBundle {
*
* @param key 词条键值
* @return java.lang.String 返回字符串,当前仅支持字符串定义
* @Author mapabc
* @Author wanji
* @Date 2019/11/29 22:12
**/
public static String getConstants(String key) {
......@@ -85,7 +85,7 @@ public final class I18nResourceBundle {
* @param args Todo 测试 性能对比,直接访问成员变量 vs 通过反射获取 vs Spring boot自带resourceBundle
* Todo 测试 线程安全
* @return void
* @Author mapabc
* @Author wanji
* @Date 2019/11/30 13:43
**/
public static void main(String[] args) {
......
......@@ -10,7 +10,7 @@ import java.util.Map;
* 持久化接口
*
* @param <Entity>
* @author mapabc
* @author wanji
*/
public interface BaseInterfaceMapper<Entity extends TrackableEntity> {
......
......@@ -8,7 +8,7 @@ import java.util.Map;
/**
* @ClassName ExportImportMapper
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/7/6 11:59
* @Version 1.0
*/
......
......@@ -10,7 +10,7 @@ import javax.ws.rs.QueryParam;
import javax.ws.rs.core.MediaType;
/**
* @author mapabc
* @author wanji
* 修改:新增请求参数校验内容
*/
@Api(value = "RESTful服务基础接口", description = "RESTful服务基础接口")
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.rest;
/**
* bean验证分组
*
* @author mapabc
* @author wanji
* @date 2017/6/28
*/
public class BeanValidationGroups {
......
......@@ -6,7 +6,7 @@ import java.util.*;
/**
* @Description: servlet请求修改包装类
* @Author mapabc
* @Author wanji
* @Date 2020/6/23 15:05
*/
public class HeaderMapRequestWrapper extends HttpServletRequestWrapper {
......
......@@ -10,7 +10,7 @@ import javax.ws.rs.core.MediaType;
import java.util.Map;
/**
* @author mapabc7
* @author wanji
*/
@Api(value = "log服务基础接口", description = "log服务基础接口")
public interface LogAbstractRestServer {
......
......@@ -6,7 +6,7 @@ package net.wanji.common.framework.rest;
//import java.util.Set;
/**
* @author mapabc
* @author wanji
* @date 2017/7/3
*/
......
......@@ -13,7 +13,7 @@ import java.util.List;
/**
* {'total':64,'pageNum':1,'maxSize':10,'pageSize':10,'condition':''};
*
* @author mapabc
* @author wanji
*/
@Getter
@Setter
......
......@@ -6,7 +6,7 @@ import javax.validation.groups.Default;
/**
* @Description: restful参数校验通用定义
* @Author mapabc
* @Author wanji
* @Date 2020/8/26 13:10
*/
public class ValidationGroups {
......@@ -15,7 +15,7 @@ public class ValidationGroups {
* @Description: 通用保存接口校验组,继承Default,否则每个属性都得加上分组属性
*
* @see AbstractRestServer#save
* @Author mapabc
* @Author wanji
* @Date 2020/8/26 13:27
**/
public interface Create extends Default {}
......@@ -24,7 +24,7 @@ public class ValidationGroups {
* @Description: 通用更新接口校验组,继承Default,否则每个属性都得加上分组属性
*
* @see AbstractRestServer#update
* @Author mapabc
* @Author wanji
* @Date 2020/8/26 13:27
**/
public interface Update extends Default {}
......@@ -33,7 +33,7 @@ public class ValidationGroups {
* @Description: 通用查询接口校验组,继承Default,否则每个属性都得加上分组属性
*
* @see AbstractRestServer#getByWhere(TrackableEntity)
* @Author mapabc
* @Author wanji
* @Date 2020/8/26 13:27
**/
public interface Query extends Default {}
......
......@@ -32,7 +32,7 @@ import java.util.Objects;
import static net.wanji.common.framework.Constants.LogType.OPERATION_LOG;
/**
* @author mapabc
* @author wanji
*/
//@RequiresAuthentication
@Slf4j
......
......@@ -3,7 +3,7 @@ package net.wanji.common.framework.spring;
import org.springframework.context.ApplicationContext;
/**
* @author mapabc5
* @author wanji
*/
public class ServiceBeanContext {
......
......@@ -9,7 +9,7 @@ import java.util.concurrent.atomic.AtomicInteger;
/**
* 使用线程池时,根据业务名称来给池中线程命名。
*
* @Author mapabc6
* @Author wanji
* @Date 2019/12/26 15:23
*/
public class NamedThreadFactory implements ThreadFactory {
......
......@@ -21,7 +21,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* 数据库相关处理帮助类
*
* @author guoliang.dong@mapabc.com
* @author guoliang.dong@wanji.com
*
*/
public class DBUtils {
......@@ -62,7 +62,7 @@ public class DBUtils {
/**
* @return void
* @throws
* @Author mapabc7
* @Author wanji
* @Description 删除无参字段
* @Date 11:53 2020/6/9
* @Param [typesAndValues, condColumns, operations]
......
......@@ -8,7 +8,7 @@ import java.util.Map;
import java.util.Properties;
/**
* @author mapabc
* @author wanji
*/
@Slf4j
public class DSPool {
......
......@@ -34,7 +34,7 @@ import static net.wanji.common.framework.Constants.ServiceGateWayConstants.D2ADa
import static net.wanji.common.framework.Constants.TableInfo.*;
/**
* @author mapabc
* @author wanji
*/
@Slf4j
public class DSUtils {
......@@ -250,7 +250,7 @@ public class DSUtils {
String type = rs.getString(TYPE_NAME);
String isNull = rs.getString(NULLABLE);
//因JDBC里面强制转换了类型,故特殊处理,by guoliang.dong@mapabc.com
//因JDBC里面强制转换了类型,故特殊处理,by guoliang.dong@wanji.com
map.put(Constants.TableInfo.COLUMN_NAME, rs.getString(Constants.TableInfo.COLUMN_NAME));
if("serial".equals(type)){
map.put(TYPE_NAME, "int4");
......
......@@ -8,7 +8,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* MySQL sql构造器。
*
* @Author mapabc6
* @Author wanji
* @Date 2020/3/11 21:57
*/
public class MySQL {
......
......@@ -8,7 +8,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* Oracle sql 构造器。
*
* @Author mapabc6
* @Author wanji
* @Date 2020/3/13 11:48
*/
public class Oracle {
......
......@@ -8,7 +8,7 @@ import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlCo
/**
* MySQL sql构造器。
*
* @Author mapabc6
* @Author wanji
* @Date 2020/3/11 21:57
*/
public class PostgreSQL {
......
......@@ -6,7 +6,7 @@ import java.util.Map;
import static net.wanji.common.framework.Constants.ServicePublishConstants.SqlConstants.*;
/**
* @Author mapabc6
* @Author wanji
* @Date 2020/3/13 16:22
*/
public class SQLServer {
......
......@@ -10,7 +10,7 @@ import java.util.Map;
/**
* @ClassName AddFunction
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/8/6 15:10
* @Version 1.0
*/
......
......@@ -13,7 +13,7 @@ import java.util.Map;
/**
* @Description: es client bean管理
* @Author mapabc
* @Author wanji
* @Date 2019/12/10 10:01
*/
@Configuration
......@@ -32,7 +32,7 @@ public class EsConfiguration {
/**
* @Description: es获取配置文件中的name和url
* @Author mapabc9
* @Author wanji
* @Date 2019/12/13 11:02
*/
private static TransportClient getEsClient() {
......
......@@ -9,7 +9,7 @@ import org.springframework.stereotype.Component;
/**
* @Description:
* @Author mapabc9
* @Author wanji
* @Date 2019/12/12 17:07
*/
@Getter
......
......@@ -32,7 +32,7 @@ import static org.elasticsearch.common.xcontent.XContentFactory.jsonBuilder;
/**
* 对ES操作的工具类
*
* @author mapabc
* @author wanji
* @date 2016/11/23
*/
@Slf4j
......@@ -448,7 +448,7 @@ public class EsUtil {
* @param fileds 需要返回的字段
* @return java.util.List<java.util.Map < java.lang.String , java.lang.Object>>
* @Description: 分页查询,并返回指定字段
* @Author mapabc
* @Author wanji
* @Date 2019/12/16 16:34
**/
public List<Map<String, Object>> searchDatas(TransportClient client, String indexName, String typeName, QueryBuilder qb, int startRow, int pageSize, Set<String> fileds) {
......
......@@ -22,7 +22,7 @@ import java.security.KeyStore;
/**
*
* HTTPS 双向认证 - direct into cacerts
* Created by mapabc4 on 2019/7/10.
* Created by wanji on 2019/7/10.
*/
@Slf4j
public class HttpsClient {
......
......@@ -8,7 +8,7 @@ import java.util.concurrent.ExecutorService;
/**
* @ClassName RetryTemplate
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/7/13 10:00
* @Version 1.0
*/
......
......@@ -12,7 +12,7 @@ import java.util.Enumeration;
import java.util.Properties;
/**
* @Author mapabc8
* @Author wanji
* @Date 2020/2/11 15:47
**/
@Slf4j
......@@ -22,7 +22,7 @@ public class OperationMonitorUtil {
* @param ipAddress
* @return boolean
* @Description: 测试指定的ip是否能ping通
* @Author mapabc8
* @Author wanji
* @Date 2020/2/12 9:23
**/
public static boolean ping(String ipAddress) throws Exception {
......@@ -36,7 +36,7 @@ public class OperationMonitorUtil {
* @param processName
* @return boolean
* @Description:
* @Author mapabc8
* @Author wanji
* @Date 2020/2/11 18:28
**/
static boolean findProcess(String processName) {
......@@ -77,7 +77,7 @@ public class OperationMonitorUtil {
* @param
* @return java.lang.String
* @Description:
* @Author mapabc8
* @Author wanji
* @Date 2020/2/11 18:29
**/
public static String getSystemLocalIp() throws Exception {
......@@ -105,7 +105,7 @@ public class OperationMonitorUtil {
* @param
* @return java.net.InetAddress
* @Description: 获取Linux系统下本机ip地址
* @Author mapabc8
* @Author wanji
* @Date 2020/2/11 18:08
**/
private static String getUnixLocalIp() throws SocketException {
......
......@@ -10,7 +10,7 @@ import java.net.URI;
/**
* @ClassName HttpComponentsClientRestfulHttpRequestFactory
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/8/14 13:53
* @Version 1.0
*/
......
......@@ -19,7 +19,7 @@ import java.nio.charset.StandardCharsets;
import java.util.List;
/**
* @author mapabc4
* @author wanji
* @date 2019-04-11
*/
@Configuration
......
......@@ -11,7 +11,7 @@ import java.util.Map;
import static org.apache.http.HttpStatus.SC_OK;
/**
* @author mapabc4
* @author wanji
* todo spring框架默认处理MimeType方式过于严格,存在兼容性问题,需要使用原生重新封装
* todo 不支持的接口示例: @RequestMapping(value = "/zmove_material")
* public void save(@QueryParam("sap-client") String sap_client, @RequestBody User entity, HttpServletResponse response) {
......
......@@ -23,7 +23,7 @@ import java.nio.charset.Charset;
/**
* @ClassName DoSoapTool
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/7/28 10:30
* @Version 1.0
*/
......
......@@ -359,7 +359,7 @@ public class EHCacheUtil {
/**
* @return void
* @throws
* @Author mapabc7
* @Author wanji
* @Description 更新缓存
* @Date 16:41 2020/7/3
* @Param [id, obj]
......
......@@ -25,7 +25,7 @@ import static net.wanji.common.framework.Constants.igniteCacheName.BP_DESIGN_CAC
/**
* @ClassName IgniteClientCacheUtil
* @Description ignite 缓存 工具类
* @Author mapabc7
* @Author wanji
* @Date 2020/7/9 15:15
* @Version 1.0
*/
......
......@@ -6,7 +6,7 @@ import javax.servlet.http.HttpServletResponse;
/**
* @Description:
* @Author mapabc
* @Author wanji
* @Date 2020/6/23 14:35
*/
public class CookieUtil {
......
......@@ -87,7 +87,7 @@ public class FastDfsUtils {
/**
* @return boolean
* @throws
* @Author mapabc7
* @Author wanji
* @Description 删除本地文件
* @Date 9:26 2020/6/1
* @Param [fullRemoteFileName]
......
......@@ -19,7 +19,7 @@ import static org.toilelibre.libe.curl.Curl.$;
/**
* GeoWebCache帮助类
* @author guoliang.dong@mapabc.com
* @author guoliang.dong@wanji.com
*/
@Slf4j
public class GeoWebCacheUtils {
......
......@@ -21,7 +21,7 @@ public class HardWareUtils {
* @Description: 获取当前操作系统名称
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 17:45
**/
public static String getOSName() {
......@@ -32,7 +32,7 @@ public class HardWareUtils {
* @Description: 判断当前操作系统
*
* @return boolean,true-unix系统,false,其他,本工具类内其他会按照windows系统处理
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 17:47
**/
public static boolean isUnixOs() {
......@@ -44,7 +44,7 @@ public class HardWareUtils {
* @Description: 获取主板序列号,windows实现
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 17:53
**/
public static String getDosMotherboardSN() throws IOException {
......@@ -68,7 +68,7 @@ public class HardWareUtils {
* @Description: 获取unix系统 主板序列号
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 20:26
**/
public static String getUnixMotherboardSN() throws IOException {
......@@ -86,7 +86,7 @@ public class HardWareUtils {
* @Description: 获取unix系统 cpu序列号
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 19:41
**/
public static String getUnixCPUSerial() throws IOException {
......@@ -106,7 +106,7 @@ public class HardWareUtils {
*
* @param cmd 命令
* @return java.util.List<java.lang.Object>
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 20:30
**/
private static List<Object> exeShellCmd(String cmd) throws IOException {
......@@ -124,7 +124,7 @@ public class HardWareUtils {
*
* @param cmd 命令
* @return java.util.List<java.lang.Object>
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 20:25
**/
private static List<Object> exeDosCmd(String cmd) throws IOException {
......@@ -146,7 +146,7 @@ public class HardWareUtils {
* @Description: 获取CPU序列号
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 17:53
**/
public static String getDosCPUSerial() throws IOException {
......@@ -170,7 +170,7 @@ public class HardWareUtils {
* @Description: 获取MAC地址,多网卡环境存在计算不准的问题
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 19:46
**/
public static String getMac() {
......@@ -196,7 +196,7 @@ public class HardWareUtils {
* @Description: 获取主板序列号,支持unix和dos系统
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 20:25
**/
public static String getMotherboardSN() throws IOException {
......@@ -207,7 +207,7 @@ public class HardWareUtils {
* @Description: 获取cpu序列号,支持unix和dos系统
*
* @return java.lang.String
* @Author mapabc
* @Author wanji
* @Date 2020/7/28 20:24
**/
public static String getCPUSerial() throws IOException {
......@@ -226,7 +226,7 @@ public class HardWareUtils {
}
/**
* @Author mapabc
* @Author wanji
* @Description 获取机器码
* @Date 18:49 2020/8/3
* @Param []
......
......@@ -13,7 +13,7 @@ import java.util.Properties;
/**
* @ClassName MailUtils
* @Description 邮件工具类
* @Author mapabc7
* @Author wanji
* @Date 2020/5/29 13:44
* @Version 1.0
*/
......@@ -23,7 +23,7 @@ public class MailUtils {
/**
* @return void
* @throws
* @Author mapabc7
* @Author wanji
* @Description 邮件发送
* @Date 13:57 2020/5/29
* @Param [m2AMail, map]
......
......@@ -8,7 +8,7 @@ import java.util.List;
/**
* @ClassName BeanListUtils
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/6/30 17:54
* @Version 1.0
*/
......
......@@ -12,7 +12,7 @@ import java.util.regex.Pattern;
/**
* @ClassName BeanMapUtils
* @Description 用于Map和domain类的相互转换,比fastjson效率高
* @Author ${mapabc}
* @Author ${wanji}
* @Date 2020/6/19 13:42
* @Version 1.0
*/
......
......@@ -15,7 +15,7 @@ import java.util.Map;
/**
* @ClassName CsvUtils
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/7/15 11:44
* @Version 1.0
*/
......@@ -28,7 +28,7 @@ public class CsvUtils {
/**
* @return void
* @throws
* @Author mapabc7
* @Author wanji
* @Description 写入标题
* @Date 15:01 2020/7/15
* @Param [header, file]
......@@ -65,7 +65,7 @@ public class CsvUtils {
/**
* @return void
* @throws
* @Author mapabc7
* @Author wanji
* @Description 填充数据
* @Date 15:01 2020/7/15
* @Param [data, header, file]
......
......@@ -20,7 +20,7 @@ import static net.wanji.common.framework.Constants.DATE_FORMAT.*;
/**
* 对日期的处理
*
* @author mapabc
* @author wanji
*/
public class DateUtil {
......@@ -89,7 +89,7 @@ public class DateUtil {
}
/**
* @Author mapabc
* @Author wanji
* @Description 比较两个日期的大小,默认before小于after,如果不符合预置条件,则返回false
* @Date 16:02 2020/8/3
* @Param [before, after]
......@@ -218,7 +218,7 @@ public class DateUtil {
* 获得当前系统日期
*
* @return
* @author mapabc Sep 29, 2006 10:43:22 AM
* @author wanji Sep 29, 2006 10:43:22 AM
*/
public static String getDate() {
return new SimpleDateFormat(E_DATE_FORMAT_DAY.getStrFormat()).format(new Date());
......@@ -228,7 +228,7 @@ public class DateUtil {
* 得到当前系统时间和日期
*
* @return
* @author mapabc 2006-10-13 上午09:55:24
* @author wanji 2006-10-13 上午09:55:24
*/
public static String getDateTimeInSecond() {
return new SimpleDateFormat(E_DATE_FORMAT_SECOND.getStrFormat()).format(new Date());
......@@ -245,7 +245,7 @@ public class DateUtil {
* 获得当前系统时间
*
* @return
* @author mapabc Sep 29, 2006 11:06:57 AM
* @author wanji Sep 29, 2006 11:06:57 AM
*/
public static String getTime() {
return new SimpleDateFormat(E_DATE_FORMAT_TIME.getStrFormat()).format(new Date());
......@@ -284,7 +284,7 @@ public class DateUtil {
* @param date
* @param format
* @return
* @author mapabc Sep 29, 2006 10:21:46 AM
* @author wanji Sep 29, 2006 10:21:46 AM
*/
public static String formatDate(Date date, String format) {
return new SimpleDateFormat(format).format(date);
......@@ -369,7 +369,7 @@ public class DateUtil {
* @param date
* @param amount
* @return
* @author mapabc Sep 29, 2006 10:17:14 AM
* @author wanji Sep 29, 2006 10:17:14 AM
*/
public static Date addYear(String date, int amount) throws ParseException {
Calendar cal = Calendar.getInstance();
......@@ -408,7 +408,7 @@ public class DateUtil {
*
* @param dDate
* @return
* @author mapabc 2006-10-27 下午01:26:32
* @author wanji 2006-10-27 下午01:26:32
*/
public static int getWeek(Date dDate) {
Calendar cal = Calendar.getInstance();
......@@ -431,7 +431,7 @@ public class DateUtil {
*
* @param dDate
* @return
* @author mapabc 2006-10-27 下午01:34:37
* @author wanji 2006-10-27 下午01:34:37
*/
public static int getDayOfMonth(Date dDate) {
Calendar cal = Calendar.getInstance();
......
......@@ -13,7 +13,7 @@ import java.security.MessageDigest;
/**
* 类描述: encrypt加密,解密工具类
*
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:15
*/
public class EncryptUtil {
......@@ -25,7 +25,7 @@ public class EncryptUtil {
*
* @param xmlStr 需要加密的消息字符串
* @return java.lang.String 加密后的字符串
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:16
**/
public static String encrypt(String xmlStr) {
......@@ -71,7 +71,7 @@ public class EncryptUtil {
*
* @param xmlStr 需要解密的消息字符串
* @return java.lang.String 解密后的字符串
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:16
**/
public static String decrypt(String xmlStr) throws Exception {
......@@ -127,7 +127,7 @@ public class EncryptUtil {
* @param deskey KEY 由8位字节数组通过SecretKeySpec类转换而成。
* @param ivParam IV偏转向量,由8位字节数组通过IvParameterSpec类转换而成。
* @return byte[] 加密后的字节数组
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:17
**/
public static byte[] DES_CBC_Encrypt(byte[] sourceBuf,
......@@ -150,7 +150,7 @@ public class EncryptUtil {
* @param deskey KEY 由8位字节数组通过SecretKeySpec类转换而成。
* @param ivParam IV偏转向量,由6位字节数组通过IvParameterSpec类转换而成。
* @return byte[] 解密后的字节数组
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:18
**/
public static byte[] DES_CBC_Decrypt(byte[] sourceBuf,
......@@ -174,7 +174,7 @@ public class EncryptUtil {
* @param offset 加密数据起始位置
* @param length 需要加密的数组长度
* @return byte[]
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:18
**/
public static byte[] MD5Hash(byte[] buf, int offset, int length)
......@@ -190,7 +190,7 @@ public class EncryptUtil {
* @param md5Byte 加密内容的MD5Hash字节数组
* @param bodyByte 加密内容字节数组
* @return byte[] 组合后的字节数组,比加密内容长16个字节。
* @Author mapabc
* @Author wanji
* @Date 2019/10/8 11:19
**/
public static byte[] addMD5(byte[] md5Byte, byte[] bodyByte) {
......
......@@ -16,7 +16,7 @@ import java.util.*;
/**
* @ClassName ExcelUtils
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/6/30 13:22
* @Version 1.0
*/
......@@ -88,7 +88,7 @@ public class ExcelUtils {
/**
* @return org.apache.poi.ss.usermodel.Sheet
* @throws
* @Author mapabc7
* @Author wanji
* @Description 根据 workbook 和 sheetName 获取 sheet
* @Date 14:10 2020/7/1
* @Param [book, sheetName, title]
......@@ -130,7 +130,7 @@ public class ExcelUtils {
/**
* @return void
* @throws
* @Author mapabc7
* @Author wanji
* @Description 组装 row 和 cell
* @Date 14:22 2020/7/1
* @Param [sheet, i, lastRowNum, title, rowData]
......
......@@ -9,7 +9,7 @@ import java.io.*;
import java.util.Map;
/**
* @author mapabc
* @author wanji
* @date 2018-04-11
*/
@Slf4j
......
......@@ -7,7 +7,7 @@ import java.util.Random;
import java.util.UUID;
/**
* @author mapabc
* @author wanji
*/
public class IDGenerator {
......
......@@ -13,7 +13,7 @@ import static org.apache.commons.lang3.StringUtils.isEmpty;
/**
* @ClassName JsonUtil
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/6/3 11:15
* @Version 1.0
*/
......
......@@ -10,7 +10,7 @@ import java.io.IOException;
/**
* @ClassName JsonXmlUtils
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/7/28 10:34
* @Version 1.0
*/
......
......@@ -12,7 +12,7 @@ import java.util.regex.Pattern;
/**
* 对字符处理的公共类
*
* @author mapabc
* @author wanji
*/
@Slf4j
public class StringUtils {
......@@ -53,7 +53,7 @@ public class StringUtils {
* 注意:要求在字符串的key和value中不可以包含“,”、“:”,否则会出现分割错误
*
* @return
* @author mapabc
* @author wanji
* @date Nov 3, 2008 10:03:26 AM
*/
public static Map<String, String> strToMap(String str) {
......@@ -74,7 +74,7 @@ public class StringUtils {
*
* @param map
* @return
* @author mapabc
* @author wanji
* @date Nov 3, 2008 10:21:31 AM
*/
public static String mapToStr(Map<String, String> map) {
......
......@@ -8,7 +8,7 @@ import java.util.Map;
/**
* @ClassName SoapUtils
* @Description
* @Author mapabc7
* @Author wanji
* @Date 2020/6/1 18:20
* @Version 1.0
*/
......
......@@ -16,7 +16,7 @@ import java.util.HashMap;
import java.util.Map;
/**
* Created by mapabc4 on 2019/5/22.
* Created by wanji on 2019/5/22.
*/
@Slf4j
public class WebServiceUtils {
......
......@@ -3,16 +3,56 @@
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">
<modelVersion>4.0.0</modelVersion>
<parent>
<artifactId>traffic-signal-platform</artifactId>
<groupId>net.wanji</groupId>
<version>0.2.1</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<groupId>net.wanji</groupId>
<artifactId>wj-databus</artifactId>
<version>0.2.1</version>
<version>0.0.1</version>
<name>wj-databus</name>
<description>wj-databus</description>
<dependencies>
<dependency>
<groupId>net.wanji</groupId>
<artifactId>wj-common</artifactId>
<version>0.0.2</version>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-commons</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-core</artifactId>
</dependency>
</dependencies>
<description>
wj-databus
</description>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<!--将依赖jar包复制到lib目录-->
<execution>
<id>copy-dependencies</id>
<phase>package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.parent.basedir}/assembly/gisc-common/lib</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
\ No newline at end of file
package net.wanji.databus.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.io.Serializable;
/**
* <p>
* 行政区划编码
* </p>
*
* @Author guoliang.dong@wanji.com
* @Date 2020-12-30
*/
@Data
@ApiModel(value="AdCode对象", description="")
public class ApiAdCodeDTO implements Serializable {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "行政区划编码")
private String adCode;
@ApiModelProperty(value = "行政区划名称")
private String adName;
@ApiModelProperty(value = "经度")
private Float lon;
@ApiModelProperty(value = "纬度")
private Float lat;
@ApiModelProperty(value = "行政区划面状要素")
private String geom;
@ApiModelProperty(value = "行政区划面积")
private String area;
@ApiModelProperty(value = "城区面积")
private String cityArea;
@ApiModelProperty(value = "父级行政区划编码")
private String parentId;
@ApiModelProperty(value = "0中国,1省级,2市级,3区县级")
private Integer level;
@ApiModelProperty(value = "行政区划代码版本:年份+月份")
private String version;
@ApiModelProperty(value = "描述信息")
private String description;
@ApiModelProperty(value = "数据状态:enable/disable")
private String status;
@ApiModelProperty(value = "排序")
private Integer sort;
@ApiModelProperty(value = "行政区划英文名")
private String nameEn;
@ApiModelProperty(value = "城市编码")
private String cityCode;
//扩充字段
@ApiModelProperty(value = "几何类型")
private String geomType;
}
package net.wanji.databus.dto;
import lombok.Data;
import java.util.List;
@Data
public class DataImportDTO {
private List<DataImportErrorDTO> exceptionlist;
private int sourceTotal;//源表数据量
private int successTotal;//导入数据量
}
package net.wanji.databus.dto;
import lombok.Data;
@Data
public class DataImportErrorDTO {
private String errorType;
private String errorField;
private String errorMsg;
}
package net.wanji.databus.dto;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
/**
* @Description:
* @NotEmpty 用在集合类上面
* @NotBlank 用在String上面
* @NotNull 用在基本类型上
* @Author Jack
* @Date 2020/8/25 14:02
*/
@Data
public class LoginUserDTO {
@NotBlank(message = "用户名不能为空")
@Size(min = 1, max = 50, message = "用户名长度应当在 1 ~ 50 个字符之间")
private String username;
@NotBlank(message = "密码不能为空")
@Size(min = 1, max = 255, message = "密码长度应当在 1 ~ 255 个字符之间")
private String password;
private String businessAccountId;
private String cardId;
}
package net.wanji.databus.dto;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* 元数据表
*
* @author guoliang.dong@wanji.com
* @date 2021/2/10
*/
@Data
public class TableDTO extends TrackableEntity {
@ApiModelProperty(value = "中文表名")
private String nameCn;
@ApiModelProperty(value = "英文表名")
private String nameEn;
@ApiModelProperty(value = "区分新建还是导入。", example = "new(新建)/import(导入)")
private String recordMode;
@ApiModelProperty(value = "oracle表所属模式名")
private String schemaName;
@ApiModelProperty(value = "数据库id")
private String dbId;
@ApiModelProperty(value = "数据类型(来源于数据类型字典表)")
private String sourceType;
@ApiModelProperty(value = "来源于字典表,用逗号分隔:是否可编辑edit、可发布publish、可缓存cache、可挂接hook、可套和nest、可导出export、是否空间表geometry")
private String features;
@ApiModelProperty(value = "表描述信息")
private String des;
private String dsId;
private String geometryType;
@ApiModelProperty(value = "目录信息")
private String catalogId;
}
package net.wanji.databus.dto;
import net.wanji.databus.entity.component.menu.ClientDevelopMenu;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.List;
@Data
public class WebPageSaveDTO implements Serializable {
@NotBlank(message = "应用ID不能为空")
private String appId;
private List<ClientDevelopMenu> menuList;
private String structure;
}
package net.wanji.databus.dto.statistical;
import io.swagger.annotations.ApiModelProperty;
public class LayersDTO {
@ApiModelProperty(value = "统计数据关键字", required = true)
private String layerId;
@ApiModelProperty(value = "表名", required = true)
private String tableName;
@ApiModelProperty(value = "统计字段", required = true)
private String field;
@ApiModelProperty(value = "查询字典值", required = true)
private String value;
@ApiModelProperty(value = "计算表达式", required = true)
private String exp;
public String getLayerId() {
return layerId;
}
public void setLayerId(String layerId) {
this.layerId = layerId;
}
public String getField() {
return field;
}
public void setField(String field) {
this.field = field;
}
public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
public String getExp() {
return exp;
}
public void setExp(String exp) {
this.exp = exp;
}
public String getTableName() {
return tableName;
}
public void setTableName(String tableName) {
this.tableName = tableName;
}
}
package net.wanji.databus.dto.statistical;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.List;
@ApiModel(value = "路网统计请求")
public class StatisticalDTO {
@ApiModelProperty(value = "行政区划", required = true)
private String adCode;
@ApiModelProperty(value = "统计数据表达式列表", required = true)
private List<LayersDTO> layers;
public String getAdCode() {
return adCode;
}
public void setAdCode(String adCode) {
this.adCode = adCode;
}
public List<LayersDTO> getLayers() {
return layers;
}
public void setLayers(List<LayersDTO> layers) {
this.layers = layers;
}
}
package net.wanji.databus.dto.statistical;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
@ApiModel(value = "路网查询请求")
public class StatisticalSearchDTO {
@ApiModelProperty(value = "当前页", required = true)
private Integer pageNum;
@ApiModelProperty(value = "每页数量", required = true)
private Integer pageSize;
@ApiModelProperty(value = "行政区划", required = true)
private String adCode;
@ApiModelProperty(value = "搜索关键字", required = true)
private String keyword;
@ApiModelProperty(value = "表名多个用,隔开", required = true)
private String tableNames;
@ApiModelProperty(value = "是否返回关联信息:true/false", required = true)
private Boolean returnRelation;
@ApiModelProperty(value = "是否返回几何字段:true/false", required = true)
private Boolean returnGeometry;
@ApiModelProperty(value = "返回空间数据格式:wkt/geojson", required = true)
private String geomType;
public Integer getPageNum() {
return pageNum;
}
public void setPageNum(Integer pageNum) {
this.pageNum = pageNum;
}
public Integer getPageSize() {
return pageSize;
}
public void setPageSize(Integer pageSize) {
this.pageSize = pageSize;
}
public String getAdCode() {
return adCode;
}
public void setAdCode(String adCode) {
this.adCode = adCode;
}
public String getKeyword() {
return keyword;
}
public void setKeyword(String keyword) {
this.keyword = keyword;
}
public String getTableNames() {
return tableNames;
}
public void setTableNames(String tableNames) {
this.tableNames = tableNames;
}
public Boolean getReturnRelation() {
return returnRelation;
}
public void setReturnRelation(Boolean returnRelation) {
this.returnRelation = returnRelation;
}
public Boolean getReturnGeometry() {
return returnGeometry;
}
public void setReturnGeometry(Boolean returnGeometry) {
this.returnGeometry = returnGeometry;
}
public String getGeomType() {
return geomType;
}
public void setGeomType(String geomType) {
this.geomType = geomType;
}
}
package net.wanji.databus.dubbo;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.dubbo.common.URL;
import org.apache.dubbo.rpc.Invocation;
import org.apache.dubbo.rpc.Invoker;
import org.apache.dubbo.rpc.cluster.loadbalance.AbstractLoadBalance;
import org.apache.dubbo.rpc.cluster.loadbalance.RandomLoadBalance;
import java.util.List;
/**
* @Description: 针对开发场景做自定义dubbo负载均衡策略,可按IP规则做路由配置
* @Date 2020/8/23 10:33
*/
@Slf4j
public class DevLoadBalance extends AbstractLoadBalance {
@Override
protected <T> Invoker<T> doSelect(List<Invoker<T>> invokers, URL url, Invocation invocation) {
String devIps = System.getProperty("dev_current_ips");
log.info("=====dev_current_ips===== : {}", devIps);
if (StringUtils.isNotBlank(devIps)) {
String[] patterns = devIps.split(",");
if (ArrayUtils.isNotEmpty(patterns)) {
//匹配开发机器路由
for (String pattern : patterns) {
for (Invoker<T> invoker : invokers) {
if (invoker.getUrl().getHost().matches(pattern)) {
log.info("=====匹配开发机器路由负载均衡地址地址===== : {}", invoker.getUrl().toString());
return invoker;
}
}
}
}
}
//默认随机策略
Invoker<T> invoker = new RandomLoadBalance().select(invokers, url, invocation);
log.info("=======默认随机策略负载均衡地址======= : {}", invoker.getUrl().toString());
return invoker;
}
}
package net.wanji.databus.entity.addata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* <p>
* 行政区划编码
* </p>
*
* @Author guoliang.dong@wanji.com
* @Date 2020-12-30
*/
@Data
@ApiModel(value="AdCode对象", description="")
public class AdCode extends TrackableEntity {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "行政区划编码")
private String adCode;
@ApiModelProperty(value = "行政区划名称")
private String adName;
@ApiModelProperty(value = "经度")
private Float lon;
@ApiModelProperty(value = "纬度")
private Float lat;
@ApiModelProperty(value = "行政区划面状要素")
private String geom;
@ApiModelProperty(value = "行政区划面积")
private String area;
@ApiModelProperty(value = "城区面积")
private String cityArea;
@ApiModelProperty(value = "父级行政区划编码")
private String parentId;
@ApiModelProperty(value = "0中国,1省级,2市级,3区县级")
private Integer level;
@ApiModelProperty(value = "行政区划代码版本:年份+月份")
private String version;
@ApiModelProperty(value = "描述信息")
private String description;
@ApiModelProperty(value = "数据状态:enable/disable")
private String status;
@ApiModelProperty(value = "排序")
private Integer sort;
@ApiModelProperty(value = "行政区划英文名")
private String nameEn;
@ApiModelProperty(value = "城市编码")
private String cityCode;
//扩充字段
@ApiModelProperty(value = "父级行政区划名字")
private String parentName;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* @Author xiaodong.zheng
* @Date 2021/3/5
* @description
*/
@Data
public class AdminArea extends TrackableEntity {
private static final long serialVersionUID = 1L;
private String id;
@ApiModelProperty(value = "区域名称")
private String areaName;
@ApiModelProperty(value = "行政区划编码")
private String adcode;
@ApiModelProperty(value = "城市行政编码")
private String cityCode;
@ApiModelProperty(value = "中心点")
private String centerPoint;
@ApiModelProperty(value = "备注")
private String remark;
@ApiModelProperty(value = "父级ID")
private String pid;
@ApiModelProperty(value = "等级(1省/直辖市,2地级市,3区县,4镇/街道)")
private Integer grade;
@ApiModelProperty(value = "排序号")
private Integer sort;
@ApiModelProperty(value = "大类:行政区域,管界,自定义区域")
private String type1;
@ApiModelProperty(value = "小类:")
private String type2;
/**
* 非标字段
**/
@ApiModelProperty(value = "wkt")
private String wkt;
@ApiModelProperty(value = "geoJson")
private String geoJson;
@ApiModelProperty(value = "dbId")
private String dbId;
@ApiModelProperty(value = "pageNum")
private Integer pageNum;
@ApiModelProperty(value = "pageSize")
private Integer pageSize;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
*
* @author xiaodong.zheng
* @since 2021-03-01
*/
@Data
@ApiModel(value="Area对象", description="")
public class Area extends TrackableEntity {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "区域名称")
private String areaName;
@ApiModelProperty(value = "行政区划编码")
private String adcode;
@ApiModelProperty(value = "区域代码")
private String areaCode;
private Double xCenter;
private Double yCenter;
@ApiModelProperty(value = "备注")
private String remark;
@ApiModelProperty(value = "父级ID")
private String pid;
@ApiModelProperty(value = "等级(1省/直辖市,2地级市,3区县,4镇/街道)")
private Integer grade;
@ApiModelProperty(value = "排序号")
private Integer sort;
@ApiModelProperty(value = "城市行政编码")
private String cityCode;
@ApiModelProperty(value = "大类:行政区域,管界,自定义区域")
private Integer type1;
@ApiModelProperty(value = "小类:")
private Integer type2;
/**
* 非标字段
**/
@ApiModelProperty(value = "wkt")
private String wkt;
@ApiModelProperty(value = "geoJson")
private String geoJson;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
*
* @author xiaodong.zheng
* @since 2020-12-22
*/
@Data
@ApiModel(value="Catalog对象", description="")
public class Catalog extends TrackableEntity {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "目录名称")
private String name;
@ApiModelProperty(value = "父级目录")
private String parentId = "0" ;
@ApiModelProperty(value = "类型",example = "datasource,HD")
private String type;
@ApiModelProperty(value = "描述信息")
private String description;
@ApiModelProperty(value = "返回数目")
private Integer count;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* @Description: 数据库数据源
* @Author: xiaodong.zheng
* @Date: 2020/12/15 15:34
* @param
* @return
**/
@Data
@ApiModel(value = "DataBase", description = "数据库")
public class DataBase extends TrackableEntity {
@ApiModelProperty(value = "数据源名称")
private String name;
@ApiModelProperty(value = "数据源中文名称")
private String nameCn;
@ApiModelProperty(value = "数据源目录ID")
private String catalogId;
@ApiModelProperty(value = "数据源描述")
private String description;
@ApiModelProperty(value = "应用类型",example = "datasource,dataset")
private String appType;
@ApiModelProperty(value = "数据库类型", example = "mysql, oracle, sql server")
private String dbType;
@ApiModelProperty(value = "数据库ip")
private String ip;
@ApiModelProperty(value = "数据库端口")
private String port;
@ApiModelProperty(value = "数据库名称")
private String dbName;
@ApiModelProperty(value = "用户名")
private String user;
@ApiModelProperty(value = "密码")
private String pwd;
@ApiModelProperty(value = "Oracle数据库的模式")
private String schemaName;
@ApiModelProperty(value = "数据集id")
private String dataSetId;
@ApiModelProperty(value = "发布人")
private String author;
}
package net.wanji.databus.entity.basedata;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import net.wanji.common.framework.domain.TrackableEntity;
/**
* <p>
* 数据字典
* </p>
*
* @Author guoliang.dong@wanji.com
* @Date 2020-12-31
*/
@Data
@ApiModel(value="Dictionary对象", description="")
public class Dictionary extends TrackableEntity {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "字典目录")
private String catalogId;
@ApiModelProperty(value = "字典编码")
private String code;
@ApiModelProperty(value = "字典名称")
private String name;
@ApiModelProperty(value = "参考值")
private String reference;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
/**
* @author wanji
* @date 2019/3/6
*/
@Setter
@Getter
@ApiModel(value = "SystemConfigType", description = "系统参数类别")
public class DictionaryType extends TrackableEntity {
@ApiModelProperty(value = "系统参数类别名")
private String name;
public static DictionaryType newInstance() {
return new DictionaryType();
}
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* 封装D2A接口的执行结果。
* <p>
* 包括sql语句,查询参数和sql查询运行结果。
* 其中,前两者为了方便aop日志记录。
*
* @Author wanji
* @Date 2020/4/7 14:07
*/
@Data
@ApiModel(description = "D2A接口的执行结果")
public class ResultView extends TrackableEntity {
@ApiModelProperty(notes = "生成的sql语句")
private String sql;
@ApiModelProperty(notes = "查询参数")
private Object[] queryParams;
@ApiModelProperty(notes = "sql执行结果")
private Object result;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.List;
/**
* 元数据表
*
* @author guoliang.dong@wanji.com
* @date 2021/2/10
*/
@Data
@ApiModel(value = "Table", description = "导入表")
public class Table extends TrackableEntity {
@ApiModelProperty(value = "中文表名")
private String nameCn;
@ApiModelProperty(value = "英文表名")
private String nameEn;
@ApiModelProperty(value = "区分新建还是导入。", example = "new(新建)/import(导入)")
private String recordMode;
@ApiModelProperty(value = "oracle表所属模式名")
private String schemaName;
@ApiModelProperty(value = "数据库id")
private String dbId;
@ApiModelProperty(value = "数据类型(来源于数据类型字典表)")
private String sourceType;
@ApiModelProperty(value = "来源于字典表,用逗号分隔:是否可编辑edit、可发布publish、可缓存cache、可挂接hook、可套和nest、可导出export、是否空间表geometry")
private String features;
@ApiModelProperty(value = "表描述信息")
private String des;
private List<String> tables;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* 表的字段元数据表
*
* @author guoliang.dong@wanji.com
* @date 2021/2/10
*/
@Data
@ApiModel(value = "TableFields" , description = "表字段")
public class TableFields extends TrackableEntity{
@ApiModelProperty(value = "表id")
private String tableId;
@ApiModelProperty(value = "字段名英文名")
private String fieldNameEn;
@ApiModelProperty(value = "字段中文名")
private String fieldNameCn;
@ApiModelProperty(value = "字段类型")
private String type;
@ApiModelProperty(value = "字段长度")
private String length;
@ApiModelProperty(value = "是否主键")
private String isPk;
@ApiModelProperty(value = "是否空值")
private String isNull;
@ApiModelProperty(value = "默认值")
private String defaultValue;
@ApiModelProperty(value = "关联字典表")
private String dictionaryType;
@ApiModelProperty(value = "是否业务主键")
private String isBizPk;
@ApiModelProperty(value = "字段排序")
private Integer flOrder;
@ApiModelProperty(value = "数据验证规则")
private String rule;
@ApiModelProperty(value = "是否可查询")
private String isQuery;
@ApiModelProperty(value = "时否空间字段")
private String isGeom;
@ApiModelProperty(value = "字段描述")
private String desc;
@ApiModelProperty(value = "计算字段")
private String calculatedField;
// 以下为扩展属性,表中不需要有相应的字段。
@ApiModelProperty(value = "是否为旧字段。微服务开发--基础数据--业务表--编辑时旧字段需要修改屏蔽。")
private boolean ifOldField;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* 接口
*
* @author wanji
* @date 2020/3/18
*/
@Data
@ApiModel(value = "TableRestful", description = " Restful接口")
public class TableRestful extends TrackableEntity {
@ApiModelProperty(value = "restful接口名称")
private String name;
@ApiModelProperty(value = "restful接口中文名称")
private String nameCn;
@ApiModelProperty(value = "服务目录")
private String catalogId;
@ApiModelProperty(value = "数据服务类型(restful,wms,wfs,wmts....),从字典中获取")
private String serviceType;
@ApiModelProperty(value = "行政区划编码")
private String adCode;
@ApiModelProperty(value = "数据集ID")
private String datasetId;
@ApiModelProperty(value = "因为中多表查询的接口无法记录表id,所以必须有此冗余字段。")
private String dbId;
@ApiModelProperty(value = "restful接口url")
private String url;
@ApiModelProperty(value = "缩略图url")
private String img;
@ApiModelProperty(value = "查询类型,单表(singleTable)或者多表(multiTable)")
private String type;
@ApiModelProperty(value = "表id")
private String tableId;
@ApiModelProperty(value = "接口编码")
private String interfaceCode;
@ApiModelProperty(value = "返回数据设置的参数")
private String dataOut;
@ApiModelProperty(value = "插件json")
private String pluginJson;
@ApiModelProperty(value = "接口描述")
private String des;
@ApiModelProperty(value = "版本")
private String version;
@ApiModelProperty(value = "编码")
private String key;
@ApiModelProperty(value = "图层样式(SLD)")
private String style;
@ApiModelProperty(value = "最小显示级别")
private String levelMin;
@ApiModelProperty(value = "最大显示级别")
private String levelMax;
// 以下为扩展属性
@ApiModelProperty(value = "表名称。此为扩展属性,表中不需要有相应的字段。")
private String tableName;
@ApiModelProperty(value = "表名称。此为扩展属性,表中不需要有相应的字段。")
private String datasetName;
@ApiModelProperty(value = "表名称。此为扩展属性,表中不需要有相应的字段。")
private String dbName;
@ApiModelProperty(value = "gateWay的主键id。服务发布--模块中所需的属性")
private String gatewayId;
@ApiModelProperty(value = "代理Url。服务发布--模块中所需的属性")
private String gatewayUrl;
@ApiModelProperty(value = "发布状态。服务发布--模块中所需的属性。")
private boolean ifPublished;
}
package net.wanji.databus.entity.basedata;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import net.sf.jftp.gui.tasks.BookmarkItem;
import org.apache.commons.lang3.StringUtils;
import java.util.List;
import static net.wanji.common.framework.Constants.DataTag.DATA_TAG_EDIT;
import static net.wanji.common.framework.Constants.DataTag.DATA_TAG_PUBLISH;
/**
* <p>
* 数据开发中心-数据资源管理-元数据视图
* </p>
*
* @Author guoliang.dong
* @Date 2020-12-25
*/
@Data
@ApiModel(value="TableView视图", description="数据开发中心-数据资源管理-元数据视图")
public class TableView extends TrackableEntity {
private static final long serialVersionUID = 1L;
@ApiModelProperty(notes = "数据库 id")
private String dbId;
@ApiModelProperty(value = "数据表名称")
private String nameEn;
@ApiModelProperty(value = "数据表中文名称")
private String nameCn;
@ApiModelProperty(value = "数据类型")
private String sourceType;
@ApiModelProperty(value = "是否发布")
private Boolean publishable;
@ApiModelProperty(value = "是否可编辑")
private Boolean editable;
@ApiModelProperty(value = "来源于字典表,用逗号分隔:是否可编辑edit、可发布publish、可缓存cache、可挂接hook、可套和nest、可导出export、是否空间表geometry")
private String features;
@ApiModelProperty(notes = "表字段")
private List<TableFields> tableFields;
@ApiModelProperty(value = "数据表描述")
private String description;
@ApiModelProperty(value = "数据模板名称,不为空需要把对应的模型创建为实体表")
private String dataModelName;
private String dataModelId;
}
package net.wanji.databus.entity.basedata;
import com.alibaba.fastjson.JSONObject;
import net.wanji.common.framework.domain.TrackableEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
*
* @author xiaodong.zheng
* @since 2021-03-01
*/
@Data
@ApiModel(value="版本对象", description="")
public class VersionLog extends TrackableEntity {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "id")
private String id;
@ApiModelProperty(value = "相关表")
private String dataTable;
@ApiModelProperty(value = "版本号")
private String dataVersion;
@ApiModelProperty(value = "新版本号")
private String newVersion;
@ApiModelProperty(value = "关联link")
private String linkVersion;
@ApiModelProperty(value = "自定义一区域")
private String author;
@ApiModelProperty(value = "自定义区域")
private String dtCreatedate;
@ApiModelProperty(value = "自定义区域")
private String updateFilePath;
}
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