Package org.apache.pekko.dispatch
Class SingleConsumerOnlyUnboundedMailbox
java.lang.Object
org.apache.pekko.dispatch.SingleConsumerOnlyUnboundedMailbox
- All Implemented Interfaces:
Serializable,MailboxType,ProducesMessageQueue<NodeMessageQueue>,scala.Equals,scala.Product
public final class SingleConsumerOnlyUnboundedMailbox
extends Object
implements MailboxType, ProducesMessageQueue<NodeMessageQueue>, scala.Product, Serializable
SingleConsumerOnlyUnboundedMailbox is a high-performance, multiple producer—single consumer, unbounded MailboxType,
with the drawback that you can't have multiple consumers,
which rules out using it with BalancingPool (BalancingDispatcher) for instance.
Currently this queue is slower for some benchmarks than the ConcurrentLinkedQueue from JDK 8 that is used by default, so be sure to measure the performance in your particular setting in order to determine which one to use.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSingleConsumerOnlyUnboundedMailbox(ActorSystem.Settings settings, com.typesafe.config.Config config) -
Method Summary
Modifier and TypeMethodDescriptionapply()booleancopy()final MessageQueuecreate(scala.Option<ActorRef> owner, scala.Option<ActorSystem> system) booleaninthashCode()intproductElement(int x$1) productElementName(int x$1) scala.collection.Iterator<Object>toString()static booleanMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface scala.Product
productElementNames
-
Constructor Details
-
SingleConsumerOnlyUnboundedMailbox
public SingleConsumerOnlyUnboundedMailbox() -
SingleConsumerOnlyUnboundedMailbox
public SingleConsumerOnlyUnboundedMailbox(ActorSystem.Settings settings, com.typesafe.config.Config config)
-
-
Method Details
-
apply
-
unapply
-
create
- Specified by:
createin interfaceMailboxType
-
copy
-
productPrefix
- Specified by:
productPrefixin interfacescala.Product
-
productArity
public int productArity()- Specified by:
productArityin interfacescala.Product
-
productElement
- Specified by:
productElementin interfacescala.Product
-
productIterator
- Specified by:
productIteratorin interfacescala.Product
-
canEqual
- Specified by:
canEqualin interfacescala.Equals
-
productElementName
- Specified by:
productElementNamein interfacescala.Product
-
hashCode
public int hashCode() -
toString
-
equals
-