You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@oozie.apache.org by jm...@apache.org on 2023/01/06 11:09:50 UTC

[oozie] branch origin/master created (now 5e29ce6ef)

This is an automated email from the ASF dual-hosted git repository.

jmakai pushed a change to branch origin/master
in repository https://gitbox.apache.org/repos/asf/oozie.git


      at 5e29ce6ef OOZIE-3696 [sharelib-git] Fix current SpotBugs discovered issues in Oozie's sharelib-git module (dionusos via jmakai)

This branch includes the following new commits:

     new 5e29ce6ef OOZIE-3696 [sharelib-git] Fix current SpotBugs discovered issues in Oozie's sharelib-git module (dionusos via jmakai)

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[oozie] 01/01: OOZIE-3696 [sharelib-git] Fix current SpotBugs discovered issues in Oozie's sharelib-git module (dionusos via jmakai)

Posted by jm...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jmakai pushed a commit to branch origin/master
in repository https://gitbox.apache.org/repos/asf/oozie.git

commit 5e29ce6efdf3ea47dcc7cc7a9caacaa0564fdbf6
Author: Janos Makai <jm...@apache.org>
AuthorDate: Fri Jan 6 11:41:14 2023 +0100

    OOZIE-3696 [sharelib-git] Fix current SpotBugs discovered issues in Oozie's sharelib-git module (dionusos via jmakai)
---
 release-log.txt                                               |  1 +
 .../java/org/apache/oozie/action/hadoop/GitOperations.java    | 11 ++++-------
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/release-log.txt b/release-log.txt
index d219195a0..2d84e0c8a 100644
--- a/release-log.txt
+++ b/release-log.txt
@@ -1,5 +1,6 @@
 -- Oozie 5.3.0 release (trunk - unreleased)
 
+OOZIE-3696 [sharelib-git] Fix current SpotBugs discovered issues in Oozie's sharelib-git module (dionusos via jmakai)
 OOZIE-3689 Remove usage of commons-httpclient due to EOL (jmakai via dionusos)
 OOZIE-3688 Introduce retry mechanism when starting embedded servlet containers in unit tests (jmakai via dionusos)
 OOZIE-3685 Repair flaky testCoordActionInputCheckXCommandUniqueness unit test (jmakai via dionusos)
diff --git a/sharelib/git/src/main/java/org/apache/oozie/action/hadoop/GitOperations.java b/sharelib/git/src/main/java/org/apache/oozie/action/hadoop/GitOperations.java
index 35057902f..48983b21c 100644
--- a/sharelib/git/src/main/java/org/apache/oozie/action/hadoop/GitOperations.java
+++ b/sharelib/git/src/main/java/org/apache/oozie/action/hadoop/GitOperations.java
@@ -92,13 +92,10 @@ class GitOperations {
         final CloneCommand cloneCommand = Git.cloneRepository();
         cloneCommand.setURI(srcURL.toString());
 
-        if (srcURL.getScheme().toLowerCase().equals("ssh")) {
-          cloneCommand.setTransportConfigCallback(new TransportConfigCallback() {
-              @Override
-              public void configure(final Transport transport) {
-                  final SshTransport sshTransport = (SshTransport)transport;
-                  sshTransport.setSshSessionFactory(sshSessionFactory);
-              }
+        if ("ssh".equalsIgnoreCase(srcURL.getScheme())) {
+          cloneCommand.setTransportConfigCallback(transport -> {
+              final SshTransport sshTransport = (SshTransport)transport;
+              sshTransport.setSshSessionFactory(sshSessionFactory);
           });
         }