Return-Path: X-Original-To: apmail-camel-commits-archive@www.apache.org Delivered-To: apmail-camel-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BD26917635 for ; Fri, 6 Nov 2015 07:31:48 +0000 (UTC) Received: (qmail 34417 invoked by uid 500); 6 Nov 2015 07:31:48 -0000 Delivered-To: apmail-camel-commits-archive@camel.apache.org Received: (qmail 34360 invoked by uid 500); 6 Nov 2015 07:31:48 -0000 Mailing-List: contact commits-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list commits@camel.apache.org Received: (qmail 34351 invoked by uid 99); 6 Nov 2015 07:31:48 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Nov 2015 07:31:48 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 86D39DFAF3; Fri, 6 Nov 2015 07:31:48 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: davsclaus@apache.org To: commits@camel.apache.org Date: Fri, 06 Nov 2015 07:31:48 -0000 Message-Id: <854f5d791f4f41dd91724e10b1669fdc@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [01/10] camel git commit: Fixed todo Repository: camel Updated Branches: refs/heads/camel-2.16.x 5cbdace38 -> 5ca0e663c refs/heads/master 48f64e4a9 -> f55834e06 Fixed todo Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/ca7fe373 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/ca7fe373 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/ca7fe373 Branch: refs/heads/master Commit: ca7fe37339d436e0c69630adffb298b747d3a5af Parents: 4b23332 Author: Claus Ibsen Authored: Thu Nov 5 22:11:13 2015 +0100 Committer: Claus Ibsen Committed: Fri Nov 6 08:34:25 2015 +0100 ---------------------------------------------------------------------- .../apache/camel/impl/ActiveMQUuidGenerator.java | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/ca7fe373/camel-core/src/main/java/org/apache/camel/impl/ActiveMQUuidGenerator.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/impl/ActiveMQUuidGenerator.java b/camel-core/src/main/java/org/apache/camel/impl/ActiveMQUuidGenerator.java index 6817ad5..7a4f0d0 100644 --- a/camel-core/src/main/java/org/apache/camel/impl/ActiveMQUuidGenerator.java +++ b/camel-core/src/main/java/org/apache/camel/impl/ActiveMQUuidGenerator.java @@ -16,11 +16,11 @@ */ package org.apache.camel.impl; -import java.io.IOException; import java.net.ServerSocket; import java.util.concurrent.atomic.AtomicLong; import org.apache.camel.spi.UuidGenerator; +import org.apache.camel.util.IOHelper; import org.apache.camel.util.InetAddressUtil; import org.apache.camel.util.ObjectHelper; import org.slf4j.Logger; @@ -94,19 +94,7 @@ public class ActiveMQUuidGenerator implements UuidGenerator { Thread.currentThread().interrupt(); } } finally { - // some environments, such as a PaaS may not allow us to create the ServerSocket - if (ss != null) { - try { - // TODO: replace the following line with IOHelper.close(ss) when Java 6 support is dropped - ss.close(); - } catch (IOException ioe) { - if (LOG.isTraceEnabled()) { - LOG.trace("Closing the server socket failed", ioe); - } else { - LOG.warn("Closing the server socket failed due " + ioe.getMessage() + ". This exception is ignored."); - } - } - } + IOHelper.close(ss); } }