Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dinky
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
wangpeng
dinky
Commits
e0ba0c54
Unverified
Commit
e0ba0c54
authored
Jan 10, 2024
by
ZackYoung
Committed by
GitHub
Jan 10, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Bug] [Flink]fix add jar some bug (#2974)
parent
757a298b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
21 deletions
+9
-21
docker_build.yaml
.github/workflows/docker_build.yaml
+6
-6
SinkBuilderFactory.java
...-core/src/main/java/org/dinky/cdc/SinkBuilderFactory.java
+2
-14
Executor.java
dinky-core/src/main/java/org/dinky/executor/Executor.java
+1
-1
No files found.
.github/workflows/docker_build.yaml
View file @
e0ba0c54
...
@@ -46,9 +46,9 @@ jobs:
...
@@ -46,9 +46,9 @@ jobs:
key
:
${{ runner.os }}-maven-${{ hashFiles('pom.xml') }}
key
:
${{ runner.os }}-maven-${{ hashFiles('pom.xml') }}
restore-keys
:
|
restore-keys
:
|
${{ runner.os }}-maven-
${{ runner.os }}-maven-
# - name: Check Style
# - name: Check Style
# run: |
# run: |
# ./mvnw -T 4C -B --no-snapshot-updates clean spotless:check
# ./mvnw -T 4C -B --no-snapshot-updates clean spotless:check
-
name
:
Build and Package
-
name
:
Build and Package
run
:
|
run
:
|
./mvnw -B clean install \
./mvnw -B clean install \
...
@@ -114,7 +114,7 @@ jobs:
...
@@ -114,7 +114,7 @@ jobs:
-
uses
:
actions/checkout@v3
-
uses
:
actions/checkout@v3
-
name
:
Move Dockerfile
-
name
:
Move Dockerfile
run
:
|
run
:
|
cp ./docker/Dockerfile* ./
cp
-r
./docker/Dockerfile* ./
-
name
:
Download math result for job 1
-
name
:
Download math result for job 1
uses
:
actions/download-artifact@v3
uses
:
actions/download-artifact@v3
with
:
with
:
...
@@ -173,7 +173,7 @@ jobs:
...
@@ -173,7 +173,7 @@ jobs:
-
uses
:
actions/checkout@v3
-
uses
:
actions/checkout@v3
-
name
:
Move Dockerfile
-
name
:
Move Dockerfile
run
:
|
run
:
|
cp ./docker/Dockerfile* ./
cp
-r
./docker/Dockerfile* ./
-
uses
:
actions/checkout@v3
-
uses
:
actions/checkout@v3
-
name
:
set the flink_big_version
-
name
:
set the flink_big_version
run
:
|
run
:
|
...
@@ -204,7 +204,7 @@ jobs:
...
@@ -204,7 +204,7 @@ jobs:
FLINK_VERSION=${{ matrix.FLINK_VERSION }}
FLINK_VERSION=${{ matrix.FLINK_VERSION }}
DINKY_IMAGE=${{ matrix.url }}/${{ matrix.namespace }}/dinky-standalone-server:${{ inputs.version }}
DINKY_IMAGE=${{ matrix.url }}/${{ matrix.namespace }}/dinky-standalone-server:${{ inputs.version }}
FLINK_BIG_VERSION=${{ matrix.FLINK_BIG_VERSION }}
FLINK_BIG_VERSION=${{ matrix.FLINK_BIG_VERSION }}
file
:
./docker/
DockerfileDinkyFlink
file
:
DockerfileDinkyFlink
context
:
.
context
:
.
push
:
true
push
:
true
tags
:
${{ matrix.url }}/${{ matrix.namespace }}/dinky-standalone-server:${{ inputs.version }}-flink-${{matrix.FLINK_BIG_VERSION }}
tags
:
${{ matrix.url }}/${{ matrix.namespace }}/dinky-standalone-server:${{ inputs.version }}-flink-${{matrix.FLINK_BIG_VERSION }}
dinky-cdc/dinky-cdc-core/src/main/java/org/dinky/cdc/SinkBuilderFactory.java
View file @
e0ba0c54
...
@@ -69,24 +69,12 @@ public class SinkBuilderFactory {
...
@@ -69,24 +69,12 @@ public class SinkBuilderFactory {
sinkBuilders
.
add
(
factory
);
sinkBuilders
.
add
(
factory
);
}
}
Map
<
String
,
Supplier
<
SinkBuilder
>>
plusSinkBuilder
=
sinkBuilders
.
stream
()
Map
<
String
,
Supplier
<
SinkBuilder
>>
plusSinkBuilder
=
.
collect
(
Collectors
.
toMap
(
SinkBuilderFactory:
:
getKeyWord
,
SinkBuilderFactory:
:
getSupplier
));
sinkBuilders
.
stream
().
collect
(
Collectors
.
toMap
(
SinkBuilderFactory:
:
getKeyWord
,
x
->
()
->
x
));
map
.
putAll
(
plusSinkBuilder
);
map
.
putAll
(
plusSinkBuilder
);
return
map
;
return
map
;
}
}
@SuppressWarnings
(
"unchecked"
)
private
static
Supplier
<
SinkBuilder
>
getSupplier
(
SinkBuilder
clazz
)
{
return
()
->
{
try
{
return
SinkBuilder
.
class
.
newInstance
();
}
catch
(
InstantiationException
|
IllegalAccessException
e
)
{
logger
.
warn
(
"Could not get constructor supplier : {}"
,
e
.
getMessage
());
}
return
null
;
};
}
public
static
String
getKeyWord
(
SinkBuilder
c
)
{
public
static
String
getKeyWord
(
SinkBuilder
c
)
{
String
fieldName
=
"KEY_WORD"
;
String
fieldName
=
"KEY_WORD"
;
String
result
=
null
;
String
result
=
null
;
...
...
dinky-core/src/main/java/org/dinky/executor/Executor.java
View file @
e0ba0c54
...
@@ -209,7 +209,7 @@ public abstract class Executor {
...
@@ -209,7 +209,7 @@ public abstract class Executor {
Configuration
configuration
=
tableEnvironment
.
getRootConfiguration
();
Configuration
configuration
=
tableEnvironment
.
getRootConfiguration
();
List
<
String
>
jars
=
configuration
.
get
(
PipelineOptions
.
JARS
);
List
<
String
>
jars
=
configuration
.
get
(
PipelineOptions
.
JARS
);
if
(
jars
==
null
)
{
if
(
jars
==
null
)
{
configuration
.
set
(
PipelineOptions
.
JARS
,
CollUtil
.
newArrayList
(
jarPath
));
tableEnvironment
.
addConfiguration
(
PipelineOptions
.
JARS
,
CollUtil
.
newArrayList
(
jarPath
));
}
else
{
}
else
{
CollUtil
.
addAll
(
jars
,
jarPath
);
CollUtil
.
addAll
(
jars
,
jarPath
);
}
}
...
...
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