From f587ca0ba8e3f565e4e897875ce4e5d0061cb988 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Fri, 28 Feb 2020 17:10:51 +0800 Subject: [PATCH 01/11] :memo: Writing docs. README.md --- README.md | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/README.md b/README.md index 47bdea4a0..6d77216a8 100644 --- a/README.md +++ b/README.md @@ -3,19 +3,9 @@ pigX并非一个开源软件,作者保留全部的权利。 擅自窃用,即属严重侵权行为,与盗窃无异。产生的一切任何后果责任由侵权者自负。 -### 🌹权益 - -1. 个人使用 -2. 允许用于学习、毕设等。 - ### 🚫禁止 -1. 将本项目的部分或全部代码和资源进行任何形式的再发行(尤其上传GitHub、Gitee ) -2. 利用本项目的部分或全部代码和资源进行`任何商业行为` - -### 免责声明 - -PigX 未对任何组织、团队,书面授权商业使用。如若出现任何商业后果、纠纷和本人无关,特此声明 +将本项目的部分或全部代码和资源进行任何形式的再发行(上传GitHub、Gitee ) ## 贡献代码 From 95028e8f5266c589d2f4e547e003fadc87ae96a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Tue, 10 Mar 2020 11:10:04 +0800 Subject: [PATCH 02/11] =?UTF-8?q?#825=203.7=20token=20=E5=88=B7=E6=96=B0?= =?UTF-8?q?=E7=A9=BA=E6=8C=87=E9=92=88=E9=97=AE=E9=A2=98=20&=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E6=96=B9=E6=A1=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pigx/gateway/filter/PasswordDecoderFilter.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pigx-gateway/src/main/java/com/pig4cloud/pigx/gateway/filter/PasswordDecoderFilter.java b/pigx-gateway/src/main/java/com/pig4cloud/pigx/gateway/filter/PasswordDecoderFilter.java index 8c500bdc2..e0cbf6955 100644 --- a/pigx-gateway/src/main/java/com/pig4cloud/pigx/gateway/filter/PasswordDecoderFilter.java +++ b/pigx-gateway/src/main/java/com/pig4cloud/pigx/gateway/filter/PasswordDecoderFilter.java @@ -80,6 +80,12 @@ public class PasswordDecoderFilter extends AbstractGatewayFilterFactory { return chain.filter(exchange); } + // 刷新token,直接向下执行 + String grantType = request.getQueryParams().getFirst("grant_type"); + if (StrUtil.equals(SecurityConstants.REFRESH_TOKEN, grantType)) { + return chain.filter(exchange); + } + Class inClass = String.class; Class outClass = String.class; ServerRequest serverRequest = ServerRequest.create(exchange, From e98f5a922daddeacc6585da698c1018e47c61f87 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Tue, 10 Mar 2020 11:14:29 +0800 Subject: [PATCH 03/11] =?UTF-8?q?#820=20=E3=80=90=E8=8F=9C=E5=8D=95?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E3=80=91=E6=96=B0=E5=A2=9E=E6=8C=89=E9=92=AE?= =?UTF-8?q?=20>=20=E6=9D=83=E9=99=90=20=E6=97=A0=E6=B3=95=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=20&=20=E4=BF=AE=E5=A4=8D=E6=96=B9=E6=A1=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/pig4cloud/pigx/admin/api/dto/MenuTree.java | 7 +++++-- .../java/com/pig4cloud/pigx/admin/api/vo/TreeUtil.java | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/dto/MenuTree.java b/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/dto/MenuTree.java index b496a5887..f85261485 100644 --- a/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/dto/MenuTree.java +++ b/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/dto/MenuTree.java @@ -41,7 +41,7 @@ public class MenuTree extends TreeNode implements Serializable { @ApiModelProperty(value = "菜单图标") private String icon; /** - * 菜单名称 + * 菜单名称 */ @ApiModelProperty(value = "菜单名称") private String name; @@ -60,7 +60,7 @@ public class MenuTree extends TreeNode implements Serializable { * 权限编码 */ @ApiModelProperty(value = "权限编码") - private String code; + private String permission; /** * 菜单类型 (0菜单 1按钮) */ @@ -79,9 +79,11 @@ public class MenuTree extends TreeNode implements Serializable { /** * 是否包含子节点 + * * @since 3.7 */ private Boolean hasChildren; + public MenuTree() { } @@ -106,6 +108,7 @@ public class MenuTree extends TreeNode implements Serializable { this.name = menuVo.getName(); this.path = menuVo.getPath(); this.type = menuVo.getType(); + this.permission = menuVo.getPermission(); this.label = menuVo.getName(); this.sort = menuVo.getSort(); this.keepAlive = menuVo.getKeepAlive(); diff --git a/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/vo/TreeUtil.java b/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/vo/TreeUtil.java index 60e46bb27..8f6ad7d08 100644 --- a/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/vo/TreeUtil.java +++ b/pigx-upms/pigx-upms-api/src/main/java/com/pig4cloud/pigx/admin/api/vo/TreeUtil.java @@ -112,7 +112,7 @@ public class TreeUtil { node.setParentId(menu.getParentId()); node.setName(menu.getName()); node.setPath(menu.getPath()); - node.setCode(menu.getPermission()); + node.setPermission(menu.getPermission()); node.setLabel(menu.getName()); node.setIcon(menu.getIcon()); node.setType(menu.getType()); From 431687b00ef26a11cd0be4b703d46ac0232c6fa2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Wed, 11 Mar 2020 15:34:05 +0800 Subject: [PATCH 04/11] =?UTF-8?q?:recycle:=20Refactoring=20code.=20?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=BA=90=E7=AE=A1=E7=90=86=EF=BC=8C=E4=B8=8D?= =?UTF-8?q?=E5=9C=A8=E9=BB=98=E8=AE=A4=E5=BC=95=E5=85=A5=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E6=BA=90=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- db/8pigxx_codegen.sql | 11 ----------- .../config/JdbcDynamicDataSourceProvider.java | 7 +++++++ .../datasource/support/DataSourceConstants.java | 5 +++++ 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/db/8pigxx_codegen.sql b/db/8pigxx_codegen.sql index 86a79313e..47da6fc18 100644 --- a/db/8pigxx_codegen.sql +++ b/db/8pigxx_codegen.sql @@ -20,17 +20,6 @@ CREATE TABLE `gen_datasource_conf` ( PRIMARY KEY (`id`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='数据源表'; --- ---------------------------- --- Records of gen_datasource_conf --- ---------------------------- -BEGIN; -INSERT INTO `gen_datasource_conf` VALUES (1, 'master', 'jdbc:mysql://pigx-mysql:3306/pigxx_codegen?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true', 'root', 'hyxlg2iaqpDLOe9qEcv2xQ==', '2019-08-12 15:47:39', '2019-08-12 15:47:39', '0', 1); -INSERT INTO `gen_datasource_conf` VALUES (2, 'pigxx_core', 'jdbc:mysql://pigx-mysql:3306/pigxx?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true', 'root', 'Cx+ocw0iFCpae4Qo4IoFmQ==', '2019-03-31 16:40:43', '2019-06-13 03:07:24', '0', 1); -INSERT INTO `gen_datasource_conf` VALUES (3, 'pigxx_ac', 'jdbc:mysql://pigx-mysql:3306/pigxx_ac?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8', 'root', 'Cx+ocw0iFCpae4Qo4IoFmQ==', '2019-03-31 17:53:25', '2019-06-13 03:07:25', '0', 1); -INSERT INTO `gen_datasource_conf` VALUES (4, 'pigxx_job', 'jdbc:mysql://pigx-mysql:3306/pigxx_job?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8', 'root', 'Cx+ocw0iFCpae4Qo4IoFmQ==', '2019-03-31 17:53:25', '2019-06-13 03:07:26', '0', 1); -INSERT INTO `gen_datasource_conf` VALUES (5, 'pigxx_mp', 'jdbc:mysql://pigx-mysql:3306/pigxx_mp?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8', 'root', 'Cx+ocw0iFCpae4Qo4IoFmQ==', '2019-03-31 17:53:25', '2019-06-13 03:07:28', '0', 1); -INSERT INTO `gen_datasource_conf` VALUES (6, 'pigxx_pay', 'jdbc:mysql://pigx-mysql:3306/pigxx_pay?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8', 'root', 'Cx+ocw0iFCpae4Qo4IoFmQ==', '2019-03-31 17:53:25', '2019-06-13 03:07:30', '0', 1); -COMMIT; -- ---------------------------- -- Table structure for gen_form_conf diff --git a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java index b8706e57e..621426c87 100644 --- a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java +++ b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java @@ -70,6 +70,13 @@ public class JdbcDynamicDataSourceProvider extends AbstractJdbcDataSourceProvide property.setUrl(url); map.put(name, property); } + + // 添加默认主数据源 + DataSourceProperty property = new DataSourceProperty(); + property.setUsername(properties.getUsername()); + property.setPassword(properties.getPassword()); + property.setUrl(properties.getUrl()); + map.put(DataSourceConstants.DS_MASTER, property); return map; } } diff --git a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java index 3d23df3e8..620554711 100644 --- a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java +++ b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java @@ -17,6 +17,11 @@ public interface DataSourceConstants { */ String DS_NAME = "name"; + /** + * 默认数据源(master) + */ + String DS_MASTER = "master"; + /** * jdbcurl */ From 660cc073e9a8e9b3574369dbb51c192083cde321 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Fri, 13 Mar 2020 13:03:00 +0800 Subject: [PATCH 05/11] =?UTF-8?q?:recycle:=20Refactoring=20code.=20pigx-co?= =?UTF-8?q?mmon-ds=20=E4=BE=9D=E8=B5=96=E9=A1=B9=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pigx-common/pigx-common-datasource/pom.xml | 56 +------------------ .../config/DruidDataSourceProperties.java | 18 +++++- .../config/JdbcDynamicDataSourceProvider.java | 5 +- .../support/DataSourceConstants.java | 4 -- .../pigx/codegen/mapper/GeneratorMapper.java | 2 + pom.xml | 2 +- 6 files changed, 22 insertions(+), 65 deletions(-) diff --git a/pigx-common/pigx-common-datasource/pom.xml b/pigx-common/pigx-common-datasource/pom.xml index 6f586e0ee..9939cfb2a 100644 --- a/pigx-common/pigx-common-datasource/pom.xml +++ b/pigx-common/pigx-common-datasource/pom.xml @@ -17,70 +17,16 @@ pigx 动态切换数据源 - - org.springframework.boot - spring-boot-starter-jdbc - - - javax.servlet - javax.servlet-api - - - org.springframework - spring-webmvc - - - - com.pig4cloud - pigx-common-core - com.baomidou dynamic-datasource-spring-boot-starter - - com.baomidou - mybatis-plus-boot-starter - - - mysql - mysql-connector-java - com.alibaba druid-spring-boot-starter - - - - com.pig4cloud - pigx-common-swagger - - - - com.pig4cloud - pigx-common-security - - - com.pig4cloud - pigx-common-log - - - - velocity - org.apache.velocity - ${velocity.version} - - - - org.springframework.boot - spring-boot-starter-web - - - - org.springframework.boot - spring-boot-starter-undertow + provided \ No newline at end of file diff --git a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/DruidDataSourceProperties.java b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/DruidDataSourceProperties.java index 08a8ba6d3..5c9164b7f 100644 --- a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/DruidDataSourceProperties.java +++ b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/DruidDataSourceProperties.java @@ -14,13 +14,29 @@ import org.springframework.stereotype.Component; @Component @ConfigurationProperties("spring.datasource.druid") public class DruidDataSourceProperties { + + /** + * 数据源用户名 + */ private String username; + + /** + * 数据源密码 + */ private String password; + + /** + * jdbcurl + */ private String url; + + /** + * 数据源驱动 + */ private String driverClassName; /** * 查询数据源的SQL */ - private String queryDsSql; + private String queryDsSql = "select * from gen_datasource_conf where del_flag = 0"; } diff --git a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java index 621426c87..3881d21ef 100644 --- a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java +++ b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/config/JdbcDynamicDataSourceProvider.java @@ -17,7 +17,6 @@ package com.pig4cloud.pigx.common.datasource.config; -import cn.hutool.core.util.StrUtil; import com.baomidou.dynamic.datasource.provider.AbstractJdbcDataSourceProvider; import com.baomidou.dynamic.datasource.spring.boot.autoconfigure.DataSourceProperty; import com.pig4cloud.pigx.common.datasource.support.DataSourceConstants; @@ -54,9 +53,7 @@ public class JdbcDynamicDataSourceProvider extends AbstractJdbcDataSourceProvide */ @Override protected Map executeStmt(Statement statement) throws SQLException { - ResultSet rs = statement.executeQuery(StrUtil.isBlank(properties.getQueryDsSql()) - ? DataSourceConstants.QUERY_DS_SQL - : properties.getQueryDsSql()); + ResultSet rs = statement.executeQuery(properties.getQueryDsSql()); Map map = new HashMap<>(8); while (rs.next()) { diff --git a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java index 620554711..07a34ea62 100644 --- a/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java +++ b/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java @@ -7,10 +7,6 @@ package com.pig4cloud.pigx.common.datasource.support; * 数据源相关常量 */ public interface DataSourceConstants { - /** - * 查询数据源的SQL - */ - String QUERY_DS_SQL = "select * from gen_datasource_conf where del_flag = 0"; /** * 数据源名称 diff --git a/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/mapper/GeneratorMapper.java b/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/mapper/GeneratorMapper.java index 5af04db55..6e5639d82 100755 --- a/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/mapper/GeneratorMapper.java +++ b/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/mapper/GeneratorMapper.java @@ -48,6 +48,7 @@ public interface GeneratorMapper { * 查询表信息 * * @param tableName 表名称 + * @param dsName 数据源名称 * @return */ @DS("#last") @@ -57,6 +58,7 @@ public interface GeneratorMapper { * 查询表列信息 * * @param tableName 表名称 + * @param dsName 数据源名称 * @return */ @DS("#last") diff --git a/pom.xml b/pom.xml index 169e85e90..3f294d936 100644 --- a/pom.xml +++ b/pom.xml @@ -40,7 +40,7 @@ 1.8 1.8 2.2.2 - 5.1.5 + 5.2.0 1.6.2 2.9.2 2.0.2 From 7906f4b74b7dd8068ecdcae1add959b1667aec2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Fri, 13 Mar 2020 13:03:54 +0800 Subject: [PATCH 06/11] =?UTF-8?q?:sparkles:=20Introducing=20new=20features?= =?UTF-8?q?.=20#864=20=E3=80=90=E7=81=B0=E5=BA=A6=E8=B7=AF=E7=94=B1?= =?UTF-8?q?=E3=80=91swagger=20=E8=B0=83=E8=AF=95=E7=81=B0=E5=BA=A6?= =?UTF-8?q?=E8=B7=AF=E7=94=B1=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../config/SwaggerAutoConfiguration.java | 60 +++++++++++-------- 1 file changed, 36 insertions(+), 24 deletions(-) diff --git a/pigx-common/pigx-common-swagger/src/main/java/com/pig4cloud/pigx/common/swagger/config/SwaggerAutoConfiguration.java b/pigx-common/pigx-common-swagger/src/main/java/com/pig4cloud/pigx/common/swagger/config/SwaggerAutoConfiguration.java index e715ffdde..a07a1c2c3 100644 --- a/pigx-common/pigx-common-swagger/src/main/java/com/pig4cloud/pigx/common/swagger/config/SwaggerAutoConfiguration.java +++ b/pigx-common/pigx-common-swagger/src/main/java/com/pig4cloud/pigx/common/swagger/config/SwaggerAutoConfiguration.java @@ -25,8 +25,10 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import springfox.documentation.builders.ApiInfoBuilder; +import springfox.documentation.builders.ParameterBuilder; import springfox.documentation.builders.PathSelectors; import springfox.documentation.builders.RequestHandlerSelectors; +import springfox.documentation.schema.ModelRef; import springfox.documentation.service.*; import springfox.documentation.spi.DocumentationType; import springfox.documentation.spi.service.contexts.SecurityContext; @@ -49,9 +51,9 @@ import java.util.List; public class SwaggerAutoConfiguration { /** - * 默认的排除路径,排除Spring Boot默认的错误处理路径和端点 + * 默认的排除路径,排除Spring Boot默认的错误处理路径和端点 */ - private static final List DEFAULT_EXCLUDE_PATH = Arrays.asList("/error","/actuator/**"); + private static final List DEFAULT_EXCLUDE_PATH = Arrays.asList("/error", "/actuator/**"); private static final String BASE_PATH = "/**"; @Bean @@ -77,16 +79,26 @@ public class SwaggerAutoConfiguration { List> excludePath = new ArrayList<>(); swaggerProperties.getExcludePath().forEach(path -> excludePath.add(PathSelectors.ant(path))); + // 版本请求头处理 + ParameterBuilder versionPar = new ParameterBuilder(); + List pars = new ArrayList<>(); + versionPar.name("VERSION").description("灰度路由版本信息") + .modelRef(new ModelRef("string")).parameterType("header") + .required(false).build(); + pars.add(versionPar.build()); + //noinspection Guava return new Docket(DocumentationType.SWAGGER_2) - .host(swaggerProperties.getHost()) - .apiInfo(apiInfo(swaggerProperties)).select() - .apis(RequestHandlerSelectors.basePackage(swaggerProperties.getBasePackage())) - .paths(Predicates.and(Predicates.not(Predicates.or(excludePath)), Predicates.or(basePath))) - .build() - .securitySchemes(Collections.singletonList(securitySchema())) - .securityContexts(Collections.singletonList(securityContext())) - .pathMapping("/"); + .host(swaggerProperties.getHost()) + .apiInfo(apiInfo(swaggerProperties)) + .globalOperationParameters(pars) + .select() + .apis(RequestHandlerSelectors.basePackage(swaggerProperties.getBasePackage())) + .paths(Predicates.and(Predicates.not(Predicates.or(excludePath)), Predicates.or(basePath))) + .build() + .securitySchemes(Collections.singletonList(securitySchema())) + .securityContexts(Collections.singletonList(securityContext())) + .pathMapping("/"); } /** @@ -96,9 +108,9 @@ public class SwaggerAutoConfiguration { */ private SecurityContext securityContext() { return SecurityContext.builder() - .securityReferences(defaultAuth()) - .forPaths(PathSelectors.regex(swaggerProperties().getAuthorization().getAuthRegex())) - .build(); + .securityReferences(defaultAuth()) + .forPaths(PathSelectors.regex(swaggerProperties().getAuthorization().getAuthRegex())) + .build(); } /** @@ -111,9 +123,9 @@ public class SwaggerAutoConfiguration { swaggerProperties().getAuthorization().getAuthorizationScopeList().forEach(authorizationScope -> authorizationScopeList.add(new AuthorizationScope(authorizationScope.getScope(), authorizationScope.getDescription()))); AuthorizationScope[] authorizationScopes = new AuthorizationScope[authorizationScopeList.size()]; return Collections.singletonList(SecurityReference.builder() - .reference(swaggerProperties().getAuthorization().getName()) - .scopes(authorizationScopeList.toArray(authorizationScopes)) - .build()); + .reference(swaggerProperties().getAuthorization().getName()) + .scopes(authorizationScopeList.toArray(authorizationScopes)) + .build()); } @@ -127,14 +139,14 @@ public class SwaggerAutoConfiguration { private ApiInfo apiInfo(SwaggerProperties swaggerProperties) { return new ApiInfoBuilder() - .title(swaggerProperties.getTitle()) - .description(swaggerProperties.getDescription()) - .license(swaggerProperties.getLicense()) - .licenseUrl(swaggerProperties.getLicenseUrl()) - .termsOfServiceUrl(swaggerProperties.getTermsOfServiceUrl()) - .contact(new Contact(swaggerProperties.getContact().getName(), swaggerProperties.getContact().getUrl(), swaggerProperties.getContact().getEmail())) - .version(swaggerProperties.getVersion()) - .build(); + .title(swaggerProperties.getTitle()) + .description(swaggerProperties.getDescription()) + .license(swaggerProperties.getLicense()) + .licenseUrl(swaggerProperties.getLicenseUrl()) + .termsOfServiceUrl(swaggerProperties.getTermsOfServiceUrl()) + .contact(new Contact(swaggerProperties.getContact().getName(), swaggerProperties.getContact().getUrl(), swaggerProperties.getContact().getEmail())) + .version(swaggerProperties.getVersion()) + .build(); } } From 312a8e57d434ae0a405fd19b0b13e2032430b390 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Sat, 14 Mar 2020 12:21:56 +0800 Subject: [PATCH 07/11] =?UTF-8?q?:bug:=20Fixing=20a=20bug.#888=20xxl-job?= =?UTF-8?q?=E5=90=AF=E5=8A=A8=E6=8A=A5=E9=94=99=20Address=20already=20in?= =?UTF-8?q?=20use:=20bind?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/pig4cloud/pigx/common/job/XxlJobAutoConfiguration.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/pigx-common/pigx-common-job/src/main/java/com/pig4cloud/pigx/common/job/XxlJobAutoConfiguration.java b/pigx-common/pigx-common-job/src/main/java/com/pig4cloud/pigx/common/job/XxlJobAutoConfiguration.java index 7e81e44bd..443b22b73 100644 --- a/pigx-common/pigx-common-job/src/main/java/com/pig4cloud/pigx/common/job/XxlJobAutoConfiguration.java +++ b/pigx-common/pigx-common-job/src/main/java/com/pig4cloud/pigx/common/job/XxlJobAutoConfiguration.java @@ -20,7 +20,6 @@ package com.pig4cloud.pigx.common.job; import com.pig4cloud.pigx.common.job.properties.XxlJobProperties; import com.xxl.job.core.executor.impl.XxlJobSpringExecutor; import org.springframework.boot.autoconfigure.EnableAutoConfiguration; -import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; @@ -35,7 +34,6 @@ import org.springframework.context.annotation.Configuration; @ComponentScan("com.pig4cloud.pigx.common.job.properties") public class XxlJobAutoConfiguration { - @Bean(initMethod = "start", destroyMethod = "destroy") public XxlJobSpringExecutor xxlJobSpringExecutor(XxlJobProperties xxlJobProperties) { XxlJobSpringExecutor xxlJobSpringExecutor = new XxlJobSpringExecutor(); xxlJobSpringExecutor.setAdminAddresses(xxlJobProperties.getAdmin().getAddresses()); From 0eb05bf7fc606d790f16edc981aeff7af7aaf542 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Sat, 14 Mar 2020 12:22:43 +0800 Subject: [PATCH 08/11] =?UTF-8?q?:ok=5Fhand:=20Updating=20code=20due=20to?= =?UTF-8?q?=20code=20review=20changes.=20p3c=20=E4=BB=A3=E7=A0=81=E5=AE=A1?= =?UTF-8?q?=E6=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../data/cache/RedisTemplateConfig.java | 2 +- .../security/util/ConcurrentDateFormat.java | 87 ------------------- .../pigx/common/sequence/range/BizName.java | 2 + 3 files changed, 3 insertions(+), 88 deletions(-) delete mode 100644 pigx-common/pigx-common-security/src/main/java/com/pig4cloud/pigx/common/security/util/ConcurrentDateFormat.java diff --git a/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/cache/RedisTemplateConfig.java b/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/cache/RedisTemplateConfig.java index d2bf27e95..d89791f6a 100644 --- a/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/cache/RedisTemplateConfig.java +++ b/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/cache/RedisTemplateConfig.java @@ -78,7 +78,7 @@ public class RedisTemplateConfig { // https://github.com/lettuce-io/lettuce-core/wiki/ReadFrom-Settings LettuceClientConfiguration lettuceClientConfiguration = LettuceClientConfiguration.builder() - .readFrom(ReadFrom.SLAVE_PREFERRED) + .readFrom(ReadFrom.REPLICA_PREFERRED) .clientOptions(clusterClientOptions).build(); return new LettuceConnectionFactory(redisClusterConfiguration, lettuceClientConfiguration); diff --git a/pigx-common/pigx-common-security/src/main/java/com/pig4cloud/pigx/common/security/util/ConcurrentDateFormat.java b/pigx-common/pigx-common-security/src/main/java/com/pig4cloud/pigx/common/security/util/ConcurrentDateFormat.java deleted file mode 100644 index b0063b674..000000000 --- a/pigx-common/pigx-common-security/src/main/java/com/pig4cloud/pigx/common/security/util/ConcurrentDateFormat.java +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Copyright (c) 2018-2025, lengleng All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * Neither the name of the pig4cloud.com developer nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * Author: lengleng (wangiegie@gmail.com) - */ - -package com.pig4cloud.pigx.common.security.util; - -import java.text.ParseException; -import java.text.SimpleDateFormat; -import java.util.Date; -import java.util.Locale; -import java.util.Queue; -import java.util.TimeZone; -import java.util.concurrent.ConcurrentLinkedQueue; - -/** - * 参考tomcat8中的并发DateFormat - *

- * {@link SimpleDateFormat}的线程安全包装器。 - * 不使用ThreadLocal,创建足够的SimpleDateFormat对象来满足并发性要求。 - * - * @author L.cm - */ -public class ConcurrentDateFormat { - private final String format; - private final Locale locale; - private final TimeZone timezone; - private final Queue queue = new ConcurrentLinkedQueue<>(); - - private ConcurrentDateFormat(String format, Locale locale, TimeZone timezone) { - this.format = format; - this.locale = locale; - this.timezone = timezone; - SimpleDateFormat initial = createInstance(); - queue.add(initial); - } - - public static ConcurrentDateFormat of(String format) { - return new ConcurrentDateFormat(format, Locale.getDefault(), TimeZone.getDefault()); - } - - public static ConcurrentDateFormat of(String format, TimeZone timezone) { - return new ConcurrentDateFormat(format, Locale.getDefault(), timezone); - } - - public static ConcurrentDateFormat of(String format, Locale locale, TimeZone timezone) { - return new ConcurrentDateFormat(format, locale, timezone); - } - - public String format(Date date) { - SimpleDateFormat sdf = queue.poll(); - if (sdf == null) { - sdf = createInstance(); - } - String result = sdf.format(date); - queue.add(sdf); - return result; - } - - public Date parse(String source) throws ParseException { - SimpleDateFormat sdf = queue.poll(); - if (sdf == null) { - sdf = createInstance(); - } - Date result = sdf.parse(source); - queue.add(sdf); - return result; - } - - private SimpleDateFormat createInstance() { - SimpleDateFormat sdf = new SimpleDateFormat(format, locale); - sdf.setTimeZone(timezone); - return sdf; - } -} diff --git a/pigx-common/pigx-common-sequence/src/main/java/com/pig4cloud/pigx/common/sequence/range/BizName.java b/pigx-common/pigx-common-sequence/src/main/java/com/pig4cloud/pigx/common/sequence/range/BizName.java index 93ef9ec9b..04d0ba57a 100644 --- a/pigx-common/pigx-common-sequence/src/main/java/com/pig4cloud/pigx/common/sequence/range/BizName.java +++ b/pigx-common/pigx-common-sequence/src/main/java/com/pig4cloud/pigx/common/sequence/range/BizName.java @@ -9,6 +9,8 @@ package com.pig4cloud.pigx.common.sequence.range; public interface BizName { /** * 生成名称 + * + * @return 返回文本序号 */ String create(); From bbfa067f95f0d2b16d120d17dc629d5bec2435b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Sun, 15 Mar 2020 16:03:42 +0800 Subject: [PATCH 09/11] =?UTF-8?q?:bug:=20Fixing=20a=20bug.#894=20=E5=89=8D?= =?UTF-8?q?=E7=AB=AF=E6=9D=A1=E4=BB=B6=E6=90=9C=E7=B4=A2=E4=BC=9A=E8=87=AA?= =?UTF-8?q?=E5=8A=A8=E5=B8=A6=E5=85=A5=E5=BD=93=E5=89=8D=E9=A1=B5=E7=A0=81?= =?UTF-8?q?=E8=BF=9B=E5=8E=BB=E5=AF=BC=E8=87=B4=E6=9F=A5=E4=B8=8D=E5=87=BA?= =?UTF-8?q?=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pigx-codegen/src/main/resources/template/avue/index.vue.vm | 1 + 1 file changed, 1 insertion(+) diff --git a/pigx-visual/pigx-codegen/src/main/resources/template/avue/index.vue.vm b/pigx-visual/pigx-codegen/src/main/resources/template/avue/index.vue.vm index 4272691ff..6c46c9ab1 100755 --- a/pigx-visual/pigx-codegen/src/main/resources/template/avue/index.vue.vm +++ b/pigx-visual/pigx-codegen/src/main/resources/template/avue/index.vue.vm @@ -118,6 +118,7 @@ }, searchChange(form, done) { this.searchForm = form + this.page.currentPage = 1 this.getList(this.page, form) done() }, From e9676c01cb8cc6bd19bc5eb1ce4cb03537686cf6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Wed, 18 Mar 2020 10:22:13 +0800 Subject: [PATCH 10/11] =?UTF-8?q?:bug:=20Fixing=20a=20bug.#904=20=E4=BB=A3?= =?UTF-8?q?=E7=A0=81=E7=94=9F=E6=88=90=E5=89=8D=E7=AB=AFxxx-form.vue?= =?UTF-8?q?=E7=94=9F=E6=88=90=E5=91=BD=E5=90=8D=E4=B8=8Eindex.vue=E5=BC=95?= =?UTF-8?q?=E7=94=A8=E4=B8=8D=E4=B8=80=E8=87=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/pig4cloud/pigx/codegen/util/GenUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/util/GenUtils.java b/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/util/GenUtils.java index d5622a555..f1dae2987 100644 --- a/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/util/GenUtils.java +++ b/pigx-visual/pigx-codegen/src/main/java/com/pig4cloud/pigx/codegen/util/GenUtils.java @@ -329,7 +329,7 @@ public class GenUtils { if (template.contains(ELE_ADD_UPDATE_VUE_VM)) { return CommonConstants.FRONT_END_PROJECT + File.separator + "src" + File.separator + "views" + File.separator + moduleName + File.separator + className.toLowerCase() - + File.separator + moduleName + "-form.vue"; + + File.separator + className.toLowerCase() + "-form.vue"; } return null; From 12c90c9542551eae1a79588892aae8b6b375298c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= Date: Thu, 19 Mar 2020 10:50:42 +0800 Subject: [PATCH 11/11] =?UTF-8?q?:bug:=20Fixing=20a=20bug.#909=20=E5=BC=80?= =?UTF-8?q?=E5=8F=91=E5=B9=B3=E5=8F=B0=E7=9A=84=E6=95=B0=E6=8D=AE=E6=BA=90?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E4=B8=AD=E6=96=B0=E5=BB=BA=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E6=BA=90=E6=B2=A1=E6=9C=89=E5=AD=98=E4=B8=8B=E7=A7=9F=E6=88=B7?= =?UTF-8?q?id?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- db/6pigxx_config.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/db/6pigxx_config.sql b/db/6pigxx_config.sql index fbef2bd09..ab96a0913 100644 --- a/db/6pigxx_config.sql +++ b/db/6pigxx_config.sql @@ -34,7 +34,7 @@ CREATE TABLE `config_info` ( BEGIN; INSERT INTO `config_info` VALUES (1, 'application-dev.yml', 'DEFAULT_GROUP', 'jasypt:\n encryptor:\n password: pigx\n \nspring:\n redis:\n host: pigx-redis\n servlet:\n multipart:\n max-file-size: 100MB\n max-request-size: 100MB\n cloud:\n sentinel:\n eager: true\n filter:\n url-patterns: /** \n transport:\n dashboard: pigx-sentinel:5020\n \nmanagement:\n endpoints:\n web:\n exposure:\n include: \'*\'\n\nfeign:\n sentinel:\n enabled: true\n okhttp:\n enabled: true\n httpclient:\n enabled: false\n client:\n config:\n default:\n connectTimeout: 10000\n readTimeout: 10000\n compression:\n request:\n enabled: true\n response:\n enabled: true\n\nribbon:\n ReadTimeout: 10000\n ConnectTimeout: 10000\n\n#开启灰度\ngray:\n rule:\n enabled: true\n\nmybatis-plus:\n tenant-enable: ture\n mapper-locations: classpath:/mapper/*Mapper.xml\n global-config:\n banner: false\n db-config:\n id-type: auto\n field-strategy: NOT_EMPTY\n type-handlers-package: com.pig4cloud.pigx.common.data.handler\n\nswagger:\n title: PigX Swagger API\n license: Powered By PigX\n licenseUrl: https://pig4cloud.com/\n terms-of-service-url: https://pig4cloud.com/\n contact:\n email: wangiegie@gmail.com\n url: https://pig4cloud.com/about.html\n authorization:\n name: pigX OAuth\n auth-regex: ^.*$\n authorization-scope-list:\n - scope: server\n description: server all\n token-url-list:\n - http://${GATEWAY-HOST:pigx-gateway}:${GATEWAY-PORT:9999}/auth/oauth/token\n\nsecurity:\n oauth2:\n client:\n ignore-urls:\n - /actuator/**\n - /v2/api-docs\n resource:\n loadBalanced: true\n token-info-uri: http://pigx-auth/oauth/check_token', '954b56ac77f2691529aad5c497591b28', '2019-04-18 02:10:20', '2020-02-24 13:58:21', NULL, '172.17.0.125', '', '', '通用配置文件', 'null', 'null', 'yaml', 'null'); INSERT INTO `config_info` VALUES (2, 'pigx-auth-dev.yml', 'DEFAULT_GROUP', '# 数据源\nspring:\n datasource:\n type: com.alibaba.druid.pool.DruidDataSource\n druid:\n driver-class-name: com.mysql.cj.jdbc.Driver\n username: ${MYSQL-USER:root}\n password: ${MYSQL-PWD:root}\n url: jdbc:mysql://${MYSQL-HOST:pigx-mysql}:${MYSQL-PORT:3306}/${MYSQL-DB:pigxx}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true\n freemarker:\n allow-request-override: false\n allow-session-override: false\n cache: true\n charset: UTF-8\n check-template-location: true\n content-type: text/html\n enabled: true\n expose-request-attributes: false\n expose-session-attributes: false\n expose-spring-macro-helpers: true\n prefer-file-system-access: true\n suffix: .ftl\n template-loader-path: classpath:/templates/', 'a6674e6747c1a0bb6c6d78e13706f8f0', '2019-04-18 02:11:32', '2019-08-27 18:24:04', NULL, '127.0.0.1', '', '', '认证中心配置文件', 'null', 'null', 'yaml', 'null'); -INSERT INTO `config_info` VALUES (3, 'pigx-codegen-dev.yml', 'DEFAULT_GROUP', '## spring security 配置\nsecurity:\n oauth2:\n client:\n client-id: ENC(gPFcUOmJm8WqM3k3eSqS0Q==)\n client-secret: ENC(gPFcUOmJm8WqM3k3eSqS0Q==)\n scope: server\n# 数据源\nspring:\n datasource:\n type: com.alibaba.druid.pool.DruidDataSource\n druid:\n driver-class-name: com.mysql.cj.jdbc.Driver\n username: ${MYSQL-USER:root}\n password: ${MYSQL-PWD:root}\n url: jdbc:mysql://${MYSQL-HOST:pigx-mysql}:${MYSQL-PORT:3306}/${MYSQL-DB:pigxx_codegen}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true\n resources:\n static-locations: classpath:/static/,classpath:/views/\n\npigx:\n tenant:\n column: tenant_id\n tables:\n - sys_datasource_conf', 'b7d132a3ecdfac4252c994adbb65b23a', '2019-04-18 02:12:10', '2019-08-27 18:24:18', NULL, '127.0.0.1', '', '', '代码生成', 'null', 'null', 'yaml', 'null'); +INSERT INTO `config_info` VALUES (3, 'pigx-codegen-dev.yml', 'DEFAULT_GROUP', '## spring security 配置\nsecurity:\n oauth2:\n client:\n client-id: ENC(gPFcUOmJm8WqM3k3eSqS0Q==)\n client-secret: ENC(gPFcUOmJm8WqM3k3eSqS0Q==)\n scope: server\n# 数据源\nspring:\n datasource:\n type: com.alibaba.druid.pool.DruidDataSource\n druid:\n driver-class-name: com.mysql.cj.jdbc.Driver\n username: ${MYSQL-USER:root}\n password: ${MYSQL-PWD:root}\n url: jdbc:mysql://${MYSQL-HOST:pigx-mysql}:${MYSQL-PORT:3306}/${MYSQL-DB:pigxx_codegen}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true\n resources:\n static-locations: classpath:/static/,classpath:/views/\n\npigx:\n tenant:\n column: tenant_id\n tables:\n - gen_datasource_conf', 'b7d132a3ecdfac4252c994adbb65b23a', '2019-04-18 02:12:10', '2019-08-27 18:24:18', NULL, '127.0.0.1', '', '', '代码生成', 'null', 'null', 'yaml', 'null'); INSERT INTO `config_info` VALUES (4, 'pigx-daemon-elastic-job-dev.yml', 'DEFAULT_GROUP', '## spring security 配置\nsecurity:\n oauth2:\n client:\n client-id: ENC(tz2NM4GcmnE7sNJTYL8ZSg==)\n client-secret: ENC(tz2NM4GcmnE7sNJTYL8ZSg==)\n scope: server\n## 定时任务\n# 数据源\nspring:\n datasource:\n type: com.alibaba.druid.pool.DruidDataSource\n druid:\n driver-class-name: com.mysql.cj.jdbc.Driver\n username: ${MYSQL-USER:root}\n password: ${MYSQL-PWD:root}\n url: jdbc:mysql://${MYSQL-HOST:pigx-mysql}:${MYSQL-PORT:3306}/${MYSQL-DB:pigxx_job}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true\n elasticjob:\n # 分布式任务协调依赖zookeeper\n zookeeper:\n server-lists: ${ZOOKEEPER-HOST:pigx-zookeeper}:${ZOOKEEPER-PORT:2181}\n namespace: pigx-daemon\n # 普通任务\n simples:\n spring-simple-job:\n job-class: com.pig4cloud.pigx.daemon.elastic.job.PigxSimpleJob\n cron: 0 0 0/1 * * ?\n sharding-total-count: 3\n sharding-item-parameters: 0=service1,1=service2,2=service3\n eventTraceRdbDataSource: \'dataSource\'\n listener:\n listener-class: com.pig4cloud.pigx.daemon.elastic.listener.PigxElasticJobListener\n spring-simple-job2:\n job-class: com.pig4cloud.pigx.daemon.elastic.job.PigxSimpleJob2\n cron: 0 0 0/1 * * ?\n sharding-total-count: 3\n sharding-item-parameters: 0=service1,1=service2,2=service3\n eventTraceRdbDataSource: \'dataSource\'\n listener:\n listener-class: com.pig4cloud.pigx.daemon.elastic.listener.PigxElasticJobListener\n # 简单任务\n dataflows:\n spring-dataflow-job:\n job-class: com.pig4cloud.pigx.daemon.elastic.job.PigxDataflowJob\n cron: 0 0 0/1 * * ?\n sharding-total-count: 3\n sharding-item-parameters: 0=service1,1=service2,2=service3\n streaming-process: true\n eventTraceRdbDataSource: \'dataSource\'\n listener:\n distributed-listener-class: com.pig4cloud.pigx.daemon.elastic.listener.PigxDistributeElasticJobListener\n started-timeout-milliseconds: 5000\n completed-timeout-milliseconds: 10000\n\nxxl:\n job:\n admin:\n addresses: http://${XXL-HOST:pigx-xxl}:${XXL-HOST:9080}/xxl-job-admin\n executor:\n port: 9988\n appName: test-xxl', '9ce58242d57b57f737dcb59a41ee6e55', '2019-04-18 02:12:57', '2019-10-04 11:22:56', NULL, '127.0.0.1', '', '', '定时任务-elastic-job配置', 'null', 'null', 'yaml', 'null'); INSERT INTO `config_info` VALUES (5, 'pigx-gateway-dev.yml', 'DEFAULT_GROUP', 'security:\n encode:\n key: \'pigxpigxpigxpigx\'\n\nignore:\n clients:\n - test\n swagger-providers:\n - pigx-auth\n - pigx-tx-manager\n\nribbon:\n rule:\n gray-enabled: true', '24403a5b205b1e9d320078e309584bbc', '2019-04-18 02:13:52', '2019-10-20 17:07:42', NULL, '127.0.0.1', '', '', '网关配置文件', 'null', 'null', 'yaml', 'null'); INSERT INTO `config_info` VALUES (6, 'pigx-monitor-dev.yml', 'DEFAULT_GROUP', 'spring:\n # 安全配置\n security:\n user:\n name: ENC(rZHA4LW5hHmhLAAzJoFNag==) # pigx\n password: ENC(bjeyh+Aeii3kHXkoo00ZUw==) # pigx\n boot:\n admin:\n ui:\n title: \'pigx 服务状态监控\'\n brand: \'pigx 服务状态监控\'\nmanagement:\n endpoints:\n web:\n exposure:\n include: \'*\'\n endpoint:\n health:\n show-details: ALWAYS #显示详细信息', '7925a0c734460526262319b6a189e39d', '2019-04-18 02:14:17', '2019-12-31 19:04:00', NULL, '172.17.0.157', '', '', '监控配置文件', 'null', 'null', 'yaml', 'null');