From 4106ceff8a11fb0fff7dba31e958920cd43675c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20Bon=C3=A9r?= Date: Sun, 18 Jul 2010 07:28:56 +0200 Subject: [PATCH] Fixed bug when trying to abort an already committed CommitBarrier --- akka-core/src/main/scala/actor/ActorRef.scala | 6 ++++-- akka-core/src/main/scala/remote/RemoteServer.scala | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/akka-core/src/main/scala/actor/ActorRef.scala b/akka-core/src/main/scala/actor/ActorRef.scala index 9db90a6e78..82f035f311 100644 --- a/akka-core/src/main/scala/actor/ActorRef.scala +++ b/akka-core/src/main/scala/actor/ActorRef.scala @@ -1189,8 +1189,10 @@ sealed class LocalActorRef private[akka]( // abort transaction set if (isTransactionSetInScope) { val txSet = getTransactionSetInScope - Actor.log.debug("Aborting transaction set [%s]", txSet) - txSet.abort + if (!txSet.isCommitted) { + Actor.log.debug("Aborting transaction set [%s]", txSet) + txSet.abort + } } senderFuture.foreach(_.completeWithException(this, reason)) diff --git a/akka-core/src/main/scala/remote/RemoteServer.scala b/akka-core/src/main/scala/remote/RemoteServer.scala index f425d8accf..4283945de9 100644 --- a/akka-core/src/main/scala/remote/RemoteServer.scala +++ b/akka-core/src/main/scala/remote/RemoteServer.scala @@ -222,7 +222,7 @@ class RemoteServer extends Logging { bootstrap.releaseExternalResources Cluster.deregisterLocalNode(hostname, port) } catch { - case e: java.nio.channels.ClosedChannelException => log.warning("Could not close remote server channel in a graceful way") + case e => log.warning("Could not close remote server channel in a graceful way") } } }