-
Notifications
You must be signed in to change notification settings - Fork 26
Add a workflow task that uses JDBC #379
Add a workflow task that uses JDBC #379
Conversation
741f7dc
to
7e53eeb
Compare
import java.util.List; | ||
import java.util.Map; | ||
|
||
interface JdbcService { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls add doc comments to the interface and methods.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do u mean by doc comments?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
javadoc, but based on the incremental approach, let's skip this in this PR.
prebuilt-tasks/pom.xml
Outdated
@@ -30,6 +30,10 @@ | |||
</repositories> | |||
|
|||
<dependencies> | |||
<dependency> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls move next to other org.springframework.boot
group dependencies
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
prebuilt-tasks/src/main/java/com/redhat/parodos/tasks/jdbc/JdbcWorkFlowTask.java
Show resolved
Hide resolved
prebuilt-tasks/src/main/java/com/redhat/parodos/tasks/jdbc/JdbcWorkFlowTask.java
Show resolved
Hide resolved
DriverManagerDataSource dataSource = new DriverManagerDataSource(); | ||
dataSource.setUrl(url); | ||
|
||
JdbcTemplate jdbcTemplate = new JdbcTemplate(dataSource); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is repetitive. the 4 lines above repeat themselves in this class.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please suggest change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
extract lines 14-17 to a private function and reuse it in execute/update/query functions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
prebuilt-tasks/src/main/java/com/redhat/parodos/tasks/jdbc/JdbcWorkFlowTask.java
Show resolved
Hide resolved
cf6203b
to
55bdc72
Compare
pls fix build errors, overall lgtm. |
a9a2fa1
to
f181239
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: pkliczewski The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
96a2170
to
09e02a8
Compare
FLPATH-215 https://issues.redhat.com/browse/FLPATH-215 Signed-off-by: Yaron Dayagi <ydayagi@redhat.com>
/lgtm |
FLPATH-215 https://issues.redhat.com/browse/FLPATH-215
What this PR does / why we need it:
JDBC task for executing SQL queries/statements.
README file provides all details.
Which issue(s) this PR fixes:
FLPATH-215
Change type
Impacted services