Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dsk-dsc-flink
Project
Project
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
shezaixing
dsk-dsc-flink
Commits
4a492dfd
Commit
4a492dfd
authored
Jan 02, 2025
by
liaowenwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加并行度
parent
b9829263
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
2 deletions
+8
-2
AsyncMysqlDataTransferFunctionNew.java
...sc/common/function/AsyncMysqlDataTransferFunctionNew.java
+1
-1
MysqlDataTransferSink.java
.../com/dsk/flink/dsc/common/sink/MysqlDataTransferSink.java
+1
-1
EtlUtils.java
src/main/java/com/dsk/flink/dsc/utils/EtlUtils.java
+6
-0
No files found.
src/main/java/com/dsk/flink/dsc/common/function/AsyncMysqlDataTransferFunctionNew.java
View file @
4a492dfd
...
...
@@ -36,7 +36,7 @@ public class AsyncMysqlDataTransferFunctionNew extends RichAsyncFunction<JSONObj
@Override
public
void
open
(
Configuration
parameters
)
throws
Exception
{
//初始化线程池
executorService
=
new
ThreadPoolExecutor
(
4
,
4
,
20
,
TimeUnit
.
MINUTES
,
new
LinkedBlockingDeque
<>());
executorService
=
new
ThreadPoolExecutor
(
10
,
10
,
20
,
TimeUnit
.
MINUTES
,
new
LinkedBlockingDeque
<>());
}
@Override
...
...
src/main/java/com/dsk/flink/dsc/common/sink/MysqlDataTransferSink.java
View file @
4a492dfd
...
...
@@ -32,7 +32,7 @@ public class MysqlDataTransferSink extends RichSinkFunction<String> {
@Override
public
void
open
(
Configuration
parameters
)
throws
Exception
{
executorService
=
new
ThreadPoolExecutor
(
4
,
4
,
20
,
TimeUnit
.
MINUTES
,
new
LinkedBlockingDeque
<>());
executorService
=
new
ThreadPoolExecutor
(
10
,
10
,
20
,
TimeUnit
.
MINUTES
,
new
LinkedBlockingDeque
<>());
//初始化获取配置
String
configTidbUrl
=
String
.
format
(
envProps
.
getDb_url
(),
envProps
.
getDb_host
(),
envProps
.
getDb_port
(),
envProps
.
getDb_database
());
//System.out.println(configTidbUrl);
...
...
src/main/java/com/dsk/flink/dsc/utils/EtlUtils.java
View file @
4a492dfd
...
...
@@ -20,6 +20,12 @@ public class EtlUtils {
properties
.
setProperty
(
"max.partition.fetch.bytes"
,
"2097152000"
);
properties
.
setProperty
(
"flink.consumer.max.fetch.size"
,
"2097152000"
);
properties
.
setProperty
(
"frame.size"
,
"2097152000"
);
properties
.
setProperty
(
"session.timeout.ms"
,
"30000"
);
properties
.
setProperty
(
"heartbeat.interval.ms"
,
"10000"
);
properties
.
setProperty
(
"request.timeout.ms"
,
"60000"
);
properties
.
setProperty
(
"retries"
,
"3"
);
properties
.
setProperty
(
"retry.backoff.ms"
,
"5000"
);
return
properties
;
}
...
...
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