Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
datax-cloud
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄营
datax-cloud
Commits
a67d3f4b
Commit
a67d3f4b
authored
Aug 11, 2020
by
yuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
项目初始化
parent
27c24b81
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
64 deletions
+3
-64
datax-service-workflow-dev.yml
.../src/main/resources/config/datax-service-workflow-dev.yml
+2
-14
pom.xml
...-modules/workflow-service-parent/workflow-service/pom.xml
+1
-8
ProcessEngineConfig.java
...cn/datax/service/workflow/config/ProcessEngineConfig.java
+0
-32
StartedUpRunner.java
...ava/cn/datax/service/workflow/config/StartedUpRunner.java
+0
-10
No files found.
datax-config/src/main/resources/config/datax-service-workflow-dev.yml
View file @
a67d3f4b
...
@@ -18,7 +18,7 @@ spring:
...
@@ -18,7 +18,7 @@ spring:
datasource
:
datasource
:
mysql
:
mysql
:
driver-class-name
:
com.p6spy.engine.spy.P6SpyDriver
driver-class-name
:
com.p6spy.engine.spy.P6SpyDriver
url
:
jdbc:p6spy:mysql://localhost:3306/data_
test
?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
url
:
jdbc:p6spy:mysql://localhost:3306/data_
cloud
?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
username
:
root
username
:
root
password
:
1234@abcd
password
:
1234@abcd
flowable
:
flowable
:
...
@@ -27,17 +27,6 @@ spring:
...
@@ -27,17 +27,6 @@ spring:
password
:
1234@abcd
password
:
1234@abcd
# 如果不加这个参数,建表会失败:nullCatalogMeansCurrent=true
# 如果不加这个参数,建表会失败:nullCatalogMeansCurrent=true
url
:
jdbc:mysql://localhost:3306/data_cloud_flowable?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true
url
:
jdbc:mysql://localhost:3306/data_cloud_flowable?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true
# primary:
# driver-class-name: com.mysql.cj.jdbc.Driver
# username: root
# password: 1234@abcd
# url: jdbc:mysql://localhost:3306/data_test?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
# flowable:
# driver-class-name: com.mysql.cj.jdbc.Driver
# username: root
# password: 1234@abcd
# # 如果不加这个参数,建表会失败:nullCatalogMeansCurrent=true
# url: jdbc:mysql://localhost:3306/data_cloud_flowable?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true
flowable
:
flowable
:
# 关闭定时任务JOB
# 关闭定时任务JOB
async-executor-activate
:
false
async-executor-activate
:
false
...
@@ -81,4 +70,4 @@ swagger:
...
@@ -81,4 +70,4 @@ swagger:
contact
:
contact
:
name
:
yuwei
name
:
yuwei
url
:
http://www.baidu.com
url
:
http://www.baidu.com
email
:
312075478@qq.com
email
:
312075478@qq.com
\ No newline at end of file
datax-modules/workflow-service-parent/workflow-service/pom.xml
View file @
a67d3f4b
...
@@ -48,12 +48,6 @@
...
@@ -48,12 +48,6 @@
<groupId>
cn.datax
</groupId>
<groupId>
cn.datax
</groupId>
<artifactId>
datax-common-mybatis
</artifactId>
<artifactId>
datax-common-mybatis
</artifactId>
<version>
2.0.0
</version>
<version>
2.0.0
</version>
<!-- <exclusions>-->
<!-- <exclusion>-->
<!-- <groupId>com.baomidou</groupId>-->
<!-- <artifactId>dynamic-datasource-spring-boot-starter</artifactId>-->
<!-- </exclusion>-->
<!-- </exclusions>-->
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
cn.datax
</groupId>
<groupId>
cn.datax
</groupId>
...
@@ -90,4 +84,4 @@
...
@@ -90,4 +84,4 @@
</plugin>
</plugin>
</plugins>
</plugins>
</build>
</build>
</project>
</project>
\ No newline at end of file
datax-modules/workflow-service-parent/workflow-service/src/main/java/cn/datax/service/workflow/config/ProcessEngineConfig.java
View file @
a67d3f4b
package
cn
.
datax
.
service
.
workflow
.
config
;
package
cn
.
datax
.
service
.
workflow
.
config
;
import
com.baomidou.dynamic.datasource.DynamicRoutingDataSource
;
import
com.baomidou.dynamic.datasource.DynamicRoutingDataSource
;
import
com.zaxxer.hikari.HikariDataSource
;
import
lombok.AllArgsConstructor
;
import
lombok.AllArgsConstructor
;
import
org.flowable.engine.ProcessEngineConfiguration
;
import
org.flowable.engine.ProcessEngineConfiguration
;
import
org.flowable.spring.SpringProcessEngineConfiguration
;
import
org.flowable.spring.SpringProcessEngineConfiguration
;
import
org.springframework.boot.autoconfigure.jdbc.DataSourceProperties
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.context.annotation.Primary
;
import
org.springframework.jdbc.datasource.DataSourceTransactionManager
;
import
org.springframework.jdbc.datasource.DataSourceTransactionManager
;
import
javax.sql.DataSource
;
import
javax.sql.DataSource
;
...
@@ -20,34 +16,6 @@ public class ProcessEngineConfig {
...
@@ -20,34 +16,6 @@ public class ProcessEngineConfig {
private
final
DataSource
dataSource
;
private
final
DataSource
dataSource
;
// @Bean
// @Primary
// @ConfigurationProperties("spring.datasource.primary")
// public DataSourceProperties primaryDataSourceProperties() {
// return new DataSourceProperties();
// }
//
// @Bean
// @Primary
// @ConfigurationProperties("spring.datasource.primary.configuration")
// public HikariDataSource firstDataSource() {
// return primaryDataSourceProperties().initializeDataSourceBuilder()
// .type(HikariDataSource.class).build();
// }
//
// @Bean
// @ConfigurationProperties("spring.datasource.flowable")
// public DataSourceProperties flowableDataSourceProperties() {
// return new DataSourceProperties();
// }
//
// @Bean
// @ConfigurationProperties("spring.datasource.flowable.configuration")
// public HikariDataSource flowableDataSource() {
// return flowableDataSourceProperties().initializeDataSourceBuilder()
// .type(HikariDataSource.class).build();
// }
/**
/**
* ProcessEngine 配置,注入DataSourceTransactionManager和DataSource
* ProcessEngine 配置,注入DataSourceTransactionManager和DataSource
* @return
* @return
...
...
datax-modules/workflow-service-parent/workflow-service/src/main/java/cn/datax/service/workflow/config/StartedUpRunner.java
View file @
a67d3f4b
package
cn
.
datax
.
service
.
workflow
.
config
;
package
cn
.
datax
.
service
.
workflow
.
config
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.ApplicationArguments
;
import
org.springframework.boot.ApplicationArguments
;
import
org.springframework.boot.ApplicationRunner
;
import
org.springframework.boot.ApplicationRunner
;
import
org.springframework.context.ConfigurableApplicationContext
;
import
org.springframework.context.ConfigurableApplicationContext
;
import
org.springframework.core.env.Environment
;
import
org.springframework.core.env.Environment
;
import
org.springframework.jdbc.core.JdbcTemplate
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Component
;
import
java.time.LocalDateTime
;
import
java.time.LocalDateTime
;
import
java.time.format.DateTimeFormatter
;
import
java.time.format.DateTimeFormatter
;
import
java.util.List
;
import
java.util.Map
;
@Component
@Component
@RequiredArgsConstructor
@RequiredArgsConstructor
...
@@ -21,9 +17,6 @@ public class StartedUpRunner implements ApplicationRunner {
...
@@ -21,9 +17,6 @@ public class StartedUpRunner implements ApplicationRunner {
private
final
ConfigurableApplicationContext
context
;
private
final
ConfigurableApplicationContext
context
;
private
final
Environment
environment
;
private
final
Environment
environment
;
@Autowired
private
JdbcTemplate
jdbcTemplate
;
@Override
@Override
public
void
run
(
ApplicationArguments
args
)
{
public
void
run
(
ApplicationArguments
args
)
{
if
(
context
.
isActive
())
{
if
(
context
.
isActive
())
{
...
@@ -33,9 +26,6 @@ public class StartedUpRunner implements ApplicationRunner {
...
@@ -33,9 +26,6 @@ public class StartedUpRunner implements ApplicationRunner {
"端口号:"
+
environment
.
getProperty
(
"server.port"
)
+
"\n"
+
"端口号:"
+
environment
.
getProperty
(
"server.port"
)
+
"\n"
+
"-----------------------------------------"
;
"-----------------------------------------"
;
System
.
out
.
println
(
banner
);
System
.
out
.
println
(
banner
);
List
<
Map
<
String
,
Object
>>
list
=
jdbcTemplate
.
queryForList
(
"select * from t_user"
);
System
.
out
.
println
(
list
);
}
}
}
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment