From ba61e3647cb619a8abdb311d764c46599d0cbfc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20Bon=C3=A9r?= Date: Tue, 1 Jun 2010 18:10:48 +0200 Subject: [PATCH] Removed redundant servlet spec API jar from dist manifest --- akka-core/src/main/scala/actor/Agent.scala | 7 +++---- .../src/main/scala/dispatch/MessageHandling.scala | 13 ++++++++++++- project/build/AkkaProject.scala | 9 +-------- 3 files changed, 16 insertions(+), 13 deletions(-) diff --git a/akka-core/src/main/scala/actor/Agent.scala b/akka-core/src/main/scala/actor/Agent.scala index e20f1d8da9..b800c94f23 100644 --- a/akka-core/src/main/scala/actor/Agent.scala +++ b/akka-core/src/main/scala/actor/Agent.scala @@ -88,7 +88,8 @@ class AgentException private[akka](message: String) extends RuntimeException(mes * *

* -* IMPORTANT: +* IMPORTANT: +*

* You can *not* call 'agent.get', 'agent()' or use the monadic 'foreach', * 'map' and 'flatMap' within an enclosing transaction since that would block * the transaction indefinitely. But all other operations are fine. The system @@ -101,7 +102,6 @@ class AgentException private[akka](message: String) extends RuntimeException(mes sealed class Agent[T] private (initialValue: T) { import Agent._ import Actor._ - if (initialValue eq null) throw new AgentException("Initial value to Agent can't be NULL") private val dispatcher = actorOf(new AgentDispatcher[T](initialValue)).start @@ -233,6 +233,5 @@ final class AgentDispatcher[T] private[akka] (initialValue: T) extends Transacto * Performs a CAS operation, atomically swapping the internal state with the value * provided as a by-name parameter. */ - private final def swap(newData: => T): Unit = value.swap(newData) + private def swap(newData: => T): Unit = value.swap(newData) } - diff --git a/akka-core/src/main/scala/dispatch/MessageHandling.scala b/akka-core/src/main/scala/dispatch/MessageHandling.scala index 7dcf3f5554..fbf52224ce 100644 --- a/akka-core/src/main/scala/dispatch/MessageHandling.scala +++ b/akka-core/src/main/scala/dispatch/MessageHandling.scala @@ -13,13 +13,15 @@ import java.util.concurrent.ConcurrentHashMap import org.multiverse.commitbarriers.CountDownCommitBarrier +/** + * @author Jonas Bonér + */ final class MessageInvocation(val receiver: ActorRef, val message: Any, val sender: Option[ActorRef], val senderFuture: Option[CompletableFuture[Any]], val transactionSet: Option[CountDownCommitBarrier]) { if (receiver eq null) throw new IllegalArgumentException("receiver is null") - if (message eq null) throw new IllegalArgumentException("message is null") def invoke = receiver.invoke(this) @@ -50,10 +52,16 @@ final class MessageInvocation(val receiver: ActorRef, } } +/** + * @author Jonas Bonér + */ trait MessageQueue { def append(handle: MessageInvocation) } +/** + * @author Jonas Bonér + */ trait MessageDispatcher extends Logging { protected val references = new ConcurrentHashMap[String, ActorRef] def dispatch(invocation: MessageInvocation) @@ -69,6 +77,9 @@ trait MessageDispatcher extends Logging { def usesActorMailbox : Boolean } +/** + * @author Jonas Bonér + */ trait MessageDemultiplexer { def select def wakeUp diff --git a/project/build/AkkaProject.scala b/project/build/AkkaProject.scala index 4ad4858d09..21f2332fcb 100644 --- a/project/build/AkkaProject.scala +++ b/project/build/AkkaProject.scala @@ -66,14 +66,6 @@ class AkkaParent(info: ProjectInfo) extends DefaultProject(info) { val atmosphereModuleConfig = ModuleConfiguration("org.atmosphere", sonatypeSnapshotRepo) val liftModuleConfig = ModuleConfiguration("net.liftweb", ScalaToolsSnapshots) - /* These are not needed and can possibly be deleted. - val databinder = "DataBinder" at "http://databinder.net/repo" - // val configgy = "Configgy" at "http://www.lag.net/repo" - val codehaus = "Codehaus" at "http://repository.codehaus.org" - val codehaus_snapshots = "Codehaus Snapshots" at "http://snapshots.repository.codehaus.org" - val google = "Google" at "http://google-maven-repository.googlecode.com/svn/repository" - */ - // ------------------------------------------------------------ // project defintions lazy val akka_core = project("akka-core", "akka-core", new AkkaCoreProject(_)) @@ -108,6 +100,7 @@ class AkkaParent(info: ProjectInfo) extends DefaultProject(info) { // create a manifest with all akka jars and dependency jars on classpath override def manifestClassPath = Some(allArtifacts.getFiles .filter(_.getName.endsWith(".jar")) + .filter(!_.getName.contains("servlet_2.4")) .filter(!_.getName.contains("scala-library")) .map("lib_managed/scala_%s/compile/".format(buildScalaVersion) + _.getName) .mkString(" ") +