Hi toivo,
On 01.01.14 18:08, [email protected] wrote:
I am using 2.3 M2
1. Destination get every Persistent message twice:
01-_Jan_18:35:29.486 WARNING lab6.First$$_anonfun_$receive$1
_akka_://InitialPChannelTester: unknown message:
ConfirmablePersistentImpl(data183529.439,1,,false,false,0,List(),Confirm(,1,/user/first/myPersistentChannel,1,null),Actor[_akka_://InitialPChannelTester/system/journal#137981169],null)
01-_Jan_ 18:35:29.489 INFO lab6.Second$$_anonfun_$receive$2
_akka_://InitialPChannelTester: got _payload_=data183529.439
sequenceNr=1 _redeliveries_=0
01-_Jan_ 18:35:33.440 WARNING lab6.First$$_anonfun_$receive$1
_akka_://InitialPChannelTester: unknown message:
ConfirmablePersistentImpl(data183533.439,2,,false,false,0,List(),Confirm(,2,/user/first/myPersistentChannel,2,null),Actor[_akka_://InitialPChannelTester/system/journal#137981169],null)
01-_Jan_ 18:35:33.440 INFO lab6.Second$$_anonfun_$receive$2
_akka_://InitialPChannelTester: got _payload_=data183533.439
sequenceNr=2 _redeliveries_=0
Is this expected behavior?
How should I handle this?
The destination doesn't get the message twice. The "unknown message"
warning comes from the fact that you created the PersistentChannel with
replyPersistent=true. This means that the message persisted by the
channel is replied to the sender (= First actor).
2. Should unconfirmed Persistent messages redelivered when JVM is
restarted?
Yes. The reason why this doesn't happen in your example is that the
stored actor ref of the destination doesn't match the actor ref of the
new destination incarnation when the application is restarted. To ensure
that the destination is automatically resolved in a new application run use
channel ! Deliver(Persistent(data), destination, Resolve.destination)
More details in
http://doc.akka.io/docs/akka/2.3-M2/scala/persistence.html#sender-resolution
When JVM is restarted previous Persistent messages end up in Dead letters.
[INFO] [01/01/2014 18:42:09.842]
[InitialPChannelTester-akka.actor.default-dispatcher-4]
[akka://InitialPChannelTester/user/first/second] Message
[akka.persistence.ConfirmablePersistentImpl] from
Actor[akka://InitialPChannelTester/user/first#-1529344871] to
Actor[akka://InitialPChannelTester/user/first/second#1254233072] was
not delivered. [1] dead letters encountered. This logging can be
turned off or adjusted with configuration settings
'akka.log-dead-letters' and 'akka.log-dead-letters-during-shutdown'.
[INFO] [01/01/2014 18:42:09.843]
[InitialPChannelTester-akka.actor.default-dispatcher-2]
[akka://InitialPChannelTester/user/first/second] Message
[akka.persistence.ConfirmablePersistentImpl] from
Actor[akka://InitialPChannelTester/user/first#-1529344871] to
Actor[akka://InitialPChannelTester/user/first/second#1254233072] was
not delivered. [2] dead letters encountered. This logging can be
turned off or adjusted with configuration settings
'akka.log-dead-letters' and 'akka.log-dead-letters-during-shutdown'.
Thanks for great work, looks very promising
toivo
--
>>>>>>>>>> Read the docs: http://akka.io/docs/
>>>>>>>>>> Check the FAQ: http://akka.io/faq/
>>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
---
You received this message because you are subscribed to the Google
Groups "Akka User List" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.
--
Martin Krasser
blog: http://krasserm.blogspot.com
code: http://github.com/krasserm
twitter: http://twitter.com/mrt1nz
--
Read the docs: http://akka.io/docs/
Check the FAQ: http://akka.io/faq/
Search the archives: https://groups.google.com/group/akka-user
---
You received this message because you are subscribed to the Google Groups "Akka User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.