You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cs...@apache.org on 2016/09/23 12:05:13 UTC
[1/2] activemq git commit:
https://issues.apache.org/jira/browse/AMQ-6434
Repository: activemq
Updated Branches:
refs/heads/activemq-5.14.x d3b86e77d -> 8bde32a07
https://issues.apache.org/jira/browse/AMQ-6434
Rewriting logic in finally block of PooledTaskRunner to avoid using a
return statement
(cherry picked from commit f25e7ab47f1bed223e30fc85afbe43ba1f4c93e6)
Project: http://git-wip-us.apache.org/repos/asf/activemq/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/a80f7ccb
Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/a80f7ccb
Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/a80f7ccb
Branch: refs/heads/activemq-5.14.x
Commit: a80f7ccbe1c0e60c3aa668b33e4dbdc3dbb21128
Parents: d3b86e7
Author: Christopher L. Shannon (cshannon) <ch...@gmail.com>
Authored: Fri Sep 23 07:50:12 2016 -0400
Committer: Christopher L. Shannon (cshannon) <ch...@gmail.com>
Committed: Fri Sep 23 08:04:30 2016 -0400
----------------------------------------------------------------------
.../activemq/thread/PooledTaskRunner.java | 21 ++++++++++----------
1 file changed, 10 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/activemq/blob/a80f7ccb/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java
----------------------------------------------------------------------
diff --git a/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java b/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java
index 2425bc8..c8dc9d7 100644
--- a/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java
+++ b/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java
@@ -142,17 +142,16 @@ class PooledTaskRunner implements TaskRunner {
if (shutdown) {
queued = false;
runable.notifyAll();
- return;
- }
-
- // If we could not iterate all the items
- // then we need to re-queue.
- if (!done) {
- queued = true;
- }
-
- if (queued) {
- executor.execute(runable);
+ } else {
+ // If we could not iterate all the items
+ // then we need to re-queue.
+ if (!done) {
+ queued = true;
+ }
+
+ if (queued) {
+ executor.execute(runable);
+ }
}
}
[2/2] activemq git commit:
https://issues.apache.org/jira/browse/AMQ-6433
Posted by cs...@apache.org.
https://issues.apache.org/jira/browse/AMQ-6433
Generating a new equals method in TypeConversionSupport so the proper
null checks exist
(cherry picked from commit 2b99ffcc22e8c982883ae553bd91d03acc68aaa2)
Project: http://git-wip-us.apache.org/repos/asf/activemq/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/8bde32a0
Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/8bde32a0
Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/8bde32a0
Branch: refs/heads/activemq-5.14.x
Commit: 8bde32a07c28500793924b183f2956e8cc6b13f4
Parents: a80f7cc
Author: Christopher L. Shannon (cshannon) <ch...@gmail.com>
Authored: Fri Sep 23 08:02:22 2016 -0400
Committer: Christopher L. Shannon (cshannon) <ch...@gmail.com>
Committed: Fri Sep 23 08:04:36 2016 -0400
----------------------------------------------------------------------
.../activemq/util/TypeConversionSupport.java | 22 +++++++++++++++++---
1 file changed, 19 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/activemq/blob/8bde32a0/activemq-client/src/main/java/org/apache/activemq/util/TypeConversionSupport.java
----------------------------------------------------------------------
diff --git a/activemq-client/src/main/java/org/apache/activemq/util/TypeConversionSupport.java b/activemq-client/src/main/java/org/apache/activemq/util/TypeConversionSupport.java
index c00b158..d84f94a 100755
--- a/activemq-client/src/main/java/org/apache/activemq/util/TypeConversionSupport.java
+++ b/activemq-client/src/main/java/org/apache/activemq/util/TypeConversionSupport.java
@@ -50,9 +50,25 @@ public final class TypeConversionSupport {
}
@Override
- public boolean equals(Object o) {
- ConversionKey x = (ConversionKey)o;
- return x.from == from && x.to == to;
+ public boolean equals(Object obj) {
+ if (this == obj)
+ return true;
+ if (obj == null)
+ return false;
+ if (getClass() != obj.getClass())
+ return false;
+ ConversionKey other = (ConversionKey) obj;
+ if (from == null) {
+ if (other.from != null)
+ return false;
+ } else if (!from.equals(other.from))
+ return false;
+ if (to == null) {
+ if (other.to != null)
+ return false;
+ } else if (!to.equals(other.to))
+ return false;
+ return true;
}
@Override