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

dpavlov pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ignite-teamcity-bot.git


The following commit(s) were added to refs/heads/master by this push:
     new ce202af  Optimize imports & code formatted for GitHub integration
ce202af is described below

commit ce202af0a6b1da2752a31f9308a7221b37bc8743
Author: Dmitriy Pavlov <[email protected]>
AuthorDate: Thu Feb 14 18:11:18 2019 +0300

    Optimize imports & code formatted for GitHub integration
---
 .../main/java/org/apache/ignite/ci/github/PullRequest.java |  2 +-
 .../ignite/ci/github/ignited/GitHubConnIgnitedImpl.java    | 14 +++++++-------
 .../ignite/ci/github/ignited/IGitHubConnIgnited.java       |  4 ++--
 .../apache/ignite/ci/github/pure/GitHubConnectionImpl.java |  5 ++---
 .../apache/ignite/ci/github/pure/IGitHubConnection.java    |  3 +--
 .../ignite/ci/github/pure/IGitHubConnectionProvider.java   |  1 -
 6 files changed, 13 insertions(+), 16 deletions(-)

diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/PullRequest.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/PullRequest.java
index e434417..4437436 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/PullRequest.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/PullRequest.java
@@ -51,7 +51,7 @@ public class PullRequest implements IVersionedEntity {
     /** Pull Request statuses URL. */
     @SerializedName("statuses_url") private String statusesUrl;
 
-    @SerializedName("user")  private GitHubUser gitHubUser;
+    @SerializedName("user") private GitHubUser gitHubUser;
 
     @SerializedName("head") private GitHubBranch head;
 
diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/GitHubConnIgnitedImpl.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/GitHubConnIgnitedImpl.java
index c317a39..e17e7bb 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/GitHubConnIgnitedImpl.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/GitHubConnIgnitedImpl.java
@@ -43,7 +43,7 @@ import org.jetbrains.annotations.NotNull;
  *
  */
 class GitHubConnIgnitedImpl implements IGitHubConnIgnited {
-    /** Cache name*/
+    /** Cache name. */
     public static final String GIT_HUB_PR = "gitHubPr";
 
     /** Server id. */
@@ -89,6 +89,7 @@ class GitHubConnIgnitedImpl implements IGitHubConnIgnited {
     @Override public String gitBranchPrefix() {
         return config().gitBranchPrefix();
     }
+
     /** {@inheritDoc} */
     @Override public IGitHubConfig config() {
         return conn.config();
@@ -115,7 +116,6 @@ class GitHubConnIgnitedImpl implements IGitHubConnIgnited {
         return IGitHubConnIgnited.class.getSimpleName() + "." + taskName + "." 
+ srvId;
     }
 
-
     private void actualizePrs() {
         runActualizePrs(srvId, false);
 
@@ -177,11 +177,11 @@ class GitHubConnIgnitedImpl implements IGitHubConnIgnited 
{
     @MonitoredTask(name = "Check Outdated PRs(srv)", nameExtArgsIndexes = {0})
     protected String refreshOutdatedPrs(String srvId, Set<Integer> actualPrs) {
         final long cnt = StreamSupport.stream(prCache.spliterator(), false)
-                .filter(entry -> entry.getKey() >> 32 == srvIdMaskHigh)
-                .filter(entry -> 
PullRequest.OPEN.equals(entry.getValue().getState()))
-                .filter(entry -> 
!actualPrs.contains(entry.getValue().getNumber()))
-                .peek(entry -> prCache.put(entry.getKey(), 
conn.getPullRequest(entry.getValue().getNumber())))
-                .count();
+            .filter(entry -> entry.getKey() >> 32 == srvIdMaskHigh)
+            .filter(entry -> 
PullRequest.OPEN.equals(entry.getValue().getState()))
+            .filter(entry -> !actualPrs.contains(entry.getValue().getNumber()))
+            .peek(entry -> prCache.put(entry.getKey(), 
conn.getPullRequest(entry.getValue().getNumber())))
+            .count();
 
         return "PRs updated for " + srvId + ": " + cnt + " from " + 
prCache.size();
     }
diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/IGitHubConnIgnited.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/IGitHubConnIgnited.java
index ae405f8..1170c7a 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/IGitHubConnIgnited.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/ignited/IGitHubConnIgnited.java
@@ -44,8 +44,8 @@ public interface IGitHubConnIgnited {
     public void notifyGit(String url, String body);
 
     /**
-     * Prefix to be added to git branch instead of {@link 
IJiraServerConfig#branchNumPrefix()}.
-     * Usually it is a lower case of JIRA branch mention, e.. JIRA branch num 
is 'IGNITE-', and git is 'ignite-'
+     * Prefix to be added to git branch instead of {@link 
IJiraServerConfig#branchNumPrefix()}. Usually it is a lower
+     * case of JIRA branch mention, e.. JIRA branch num is 'IGNITE-', and git 
is 'ignite-'
      */
     public String gitBranchPrefix();
 }
diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/GitHubConnectionImpl.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/GitHubConnectionImpl.java
index da392dc..522421d 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/GitHubConnectionImpl.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/GitHubConnectionImpl.java
@@ -31,6 +31,7 @@ import java.util.List;
 import java.util.Properties;
 import java.util.StringTokenizer;
 import java.util.concurrent.atomic.AtomicReference;
+import javax.inject.Inject;
 import org.apache.ignite.ci.HelperConfig;
 import org.apache.ignite.ci.di.AutoProfiling;
 import org.apache.ignite.ci.github.PullRequest;
@@ -41,8 +42,6 @@ import org.jetbrains.annotations.Nullable;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import javax.inject.Inject;
-
 import static com.google.common.base.Strings.isNullOrEmpty;
 
 class GitHubConnectionImpl implements IGitHubConnection {
@@ -185,7 +184,7 @@ class GitHubConnectionImpl implements IGitHubConnection {
     }
 
     /** {@inheritDoc} */
-    @Override  public IGitHubConfig config() {
+    @Override public IGitHubConfig config() {
         return config.getGitConfig(srvCode);
     }
 }
diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnection.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnection.java
index 733c057..f02fc8c 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnection.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnection.java
@@ -16,11 +16,10 @@
  */
 package org.apache.ignite.ci.github.pure;
 
+import com.google.common.base.Strings;
 import java.util.List;
 import java.util.Objects;
 import java.util.concurrent.atomic.AtomicReference;
-
-import com.google.common.base.Strings;
 import org.apache.ignite.ci.github.PullRequest;
 import org.apache.ignite.ci.tcbot.conf.IGitHubConfig;
 import org.jetbrains.annotations.Nullable;
diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnectionProvider.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnectionProvider.java
index 71e7844..3da468f 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnectionProvider.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/github/pure/IGitHubConnectionProvider.java
@@ -19,7 +19,6 @@ package org.apache.ignite.ci.github.pure;
 public interface IGitHubConnectionProvider {
     /**
      * @param srvId Server id.
-     *
      */
     public IGitHubConnection server(String srvId);
 }

Reply via email to