Dispatcher

org.apache.pekko.dispatch.Dispatcher
class Dispatcher(_configurator: MessageDispatcherConfigurator, val id: String, val throughput: Int, val throughputDeadlineTime: Duration, executorServiceFactoryProvider: ExecutorServiceFactoryProvider, val shutdownTimeout: FiniteDuration) extends MessageDispatcher

The event-based Dispatcher binds a set of Actors to a thread pool backed up by a BlockingQueue.

The preferred way of creating dispatchers is to define configuration of it and use the the lookup method in pekko.dispatch.Dispatchers.

Value parameters

throughput

positive integer indicates the dispatcher will only process so much messages at a time from the mailbox, without checking the mailboxes of other actors. Zero or negative means the dispatcher always continues until the mailbox is empty. Larger values (or zero or negative) increase throughput, smaller values increase fairness

Attributes

Source
Dispatcher.scala
Graph
Supertypes
trait Executor
class Object
trait Matchable
class Any
Show all
Known subtypes

Members list

Value members

Concrete methods

final override def batchable(runnable: Runnable): Boolean

Override this to define which runnables will be batched.

Override this to define which runnables will be batched.

Attributes

Definition Classes
BatchingExecutor
Source
Dispatcher.scala

Inherited methods

final def attach(actor: ActorCell): Unit

Attaches the specified actor instance to this dispatcher, which includes scheduling it to run for the first time (Create() is expected to have been enqueued by the ActorCell upon mailbox creation).

Attaches the specified actor instance to this dispatcher, which includes scheduling it to run for the first time (Create() is expected to have been enqueued by the ActorCell upon mailbox creation).

Attributes

Inherited from:
MessageDispatcher
Source
AbstractDispatcher.scala
final def detach(actor: ActorCell): Unit

Detaches the specified actor instance from this dispatcher

Detaches the specified actor instance from this dispatcher

Attributes

Inherited from:
MessageDispatcher
Source
AbstractDispatcher.scala
override def execute(runnable: Runnable): Unit

Attributes

Definition Classes
BatchingExecutor -> Executor
Inherited from:
BatchingExecutor (hidden)
Source
BatchingExecutor.scala
final def inhabitants: Long

Attributes

Inherited from:
MessageDispatcher
Source
AbstractDispatcher.scala
override def reportFailure(t: Throwable): Unit

Attributes

Definition Classes
Inherited from:
MessageDispatcher
Source
AbstractDispatcher.scala

Deprecated and Inherited methods

Attributes

Deprecated
[Since version 2.12.0] preparation of ExecutionContexts will be removed
Inherited from:
ExecutionContext

Concrete fields

val id: String

Identifier of this dispatcher, corresponds to the full key of the dispatcher configuration.

Identifier of this dispatcher, corresponds to the full key of the dispatcher configuration.

Attributes

Source
Dispatcher.scala

When the dispatcher no longer has any actors registered, how long will it wait until it shuts itself down, defaulting to your pekko configs "pekko.actor.default-dispatcher.shutdown-timeout" or default specified in reference.conf

When the dispatcher no longer has any actors registered, how long will it wait until it shuts itself down, defaulting to your pekko configs "pekko.actor.default-dispatcher.shutdown-timeout" or default specified in reference.conf

INTERNAL API

Attributes

Source
Dispatcher.scala

INTERNAL API

INTERNAL API

Attributes

Source
Dispatcher.scala

INTERNAL API

INTERNAL API

Attributes

Source
Dispatcher.scala
override val toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Source
Dispatcher.scala

Inherited fields

Attributes

Inherited from:
MessageDispatcher
Source
AbstractDispatcher.scala
val mailboxes: Mailboxes

Attributes

Inherited from:
MessageDispatcher
Source
AbstractDispatcher.scala