Quantcast
Channel: Akka Libraries - Discussion Forum for Akka technologies
Viewing all articles
Browse latest Browse all 1366

Data receiving actor goes to Terminated state due to possible cause: channel flooding

$
0
0

Hi!

Akka version.
1.4.27 or 1.4.45.

Environment.

  • .NET.
  • Wi-Fi connection, local network.
  • There are two remote actors. One of them sends data buffers to the other via IActorRef.Tell:
foreach (Message msg in Message.Split(parameters))
{
  messagesConsumer.Tell(msg);
}

Problem.
The connection between actors is lost – the receiving one goes to the Terminated state. The sender has time to send about 23000 messages (on average). While the recipient has time to process about 820 messages (on average).

Bad solution.
Add Thread.Sleep(50) before foreach:

Thread.Sleep(50);
foreach (Message msg in Message.Split(parameters))
{
  messagesConsumer.Tell(msg);
}

Question.
How to solve this problem correctly? Is it a channel flooding problem?

Another attempts.
I tried changing Akka-configuration, but it didn’t help:

enforce-ip-family = true
dns-use-ipv6 = false
tcp-nodelay = off
io.tcp.direct-buffer-pool.buffer-pool-limit = 102400
io.tcp.direct-buffer-pool-pool-limit = 100000
actor.inbox.inbox-size = 10000
actor.inbox.default-timeout = 30s

NOTE!
The same program logic works successfully if two actors are on the same machine. That is, messages between actors are not transmitted via Wi-Fi.

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 1366

Trending Articles