CreationApplication is using remote deployed actors. I got the impression
that you are not using that in your original application.

What you are saying is that you see completely different behavior when you
run on one machine compared to two separate machines? Any firewall
in-between? Are the machines allowed to open connections in both directions?


On Tue, Mar 18, 2014 at 2:43 PM, Rob S <[email protected]> wrote:

> First I just want to thank you for attempting to help me with my issue.
>  Now I have tried to work with the examples you linked and here are my
> results:
>
> Scenario 1:
>
>   I ran  akka-sample-remote-java]$ ./activator  "run-main
> sample.mote.calculator.CreationApplication CalculatorWorker" and
> ./activator "run-main sample.rote.calculator.CreationApplication Creation"
> in two terminals on the same system and everything worked fine (the
> common.conf is set to the ip of the system).  I was able to kill the
> Creation and start it up again and everything works fine.  The calculating
> resumes and I see results in the terminal running Creation (I see this same
> behavior with my application.  I can start and stop everything on the same
> system and it works)
>
> Scenario 2:
>
>   I ran akka-sample-remote-java]$ ./activator  "run-main
> sample.mote.calculator.CreationApplication CalculatorWorker" on System A,
> with the common.conf updated to reflect the ip of System A.  I
> ran ./activator "run-main sample.rote.calculator.CreationApplication
> Creation" on System B with the common.conf updated to reflect the ip of
> System B and the remote creation updated the remote ip to connect to System
> A.  I start the CalculatorWorker on System A, I start Creation on System B
> and everything works.  I see Calculating on System A and results on System
> B.  I do a CTRL+C on System B and here are my results:
>
>
> Calculating 3360.0 / 54
> Calculating 74 * 50
> Calculating 35 * 26
> Calculating 75 * 15
> Calculating 6 * 28
> Calculating 4789.0 / 54
> [WARN] [03/18/2014 09:35:00.045]
> [CalculatorWorkerSystem-akka.remote.default-remote-dispatcher-4]
> [akka.tcp://
> [email protected]:2552/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0]
> Association with remote system [akka.tcp://
> [email protected]:2554] has failed, address is now gated for
> [5000] ms. Reason is: [Disassociated].
> [INFO] [03/18/2014 09:35:00.060]
> [CalculatorWorkerSystem-akka.actor.default-dispatcher-2]
> [akka://CalculatorWorkerSystem/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.14.136%3A33691-1]
> Message
> [akka.remote.transport.ActorTransportAdapter$DisassociateUnderlying] from
> Actor[akka://CalculatorWorkerSystem/deadLetters] to
> Actor[akka://CalculatorWorkerSystem/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.14.136%3A33691-1#-254990838]
> 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] [03/18/2014 09:35:00.061]
> [CalculatorWorkerSystem-akka.actor.default-dispatcher-3]
> [akka://CalculatorWorkerSystem/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0/endpointWriter]
> Message [akka.actor.FSM$Timer] from
> Actor[akka://CalculatorWorkerSystem/deadLetters] to
> Actor[akka://CalculatorWorkerSystem/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0/endpointWriter#-257802128]
> 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'.
> [WARN] [03/18/2014 09:35:05.130]
> [CalculatorWorkerSystem-akka.remote.default-remote-dispatcher-4]
> [akka.tcp://
> [email protected]:2552/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0]
> Association with remote system [akka.tcp://
> [email protected]:2554] has failed, address is now gated for
> [5000] ms. Reason is: [Association failed with
> [akka.tcp://[email protected]:2554]].
>
>
>
> This message continuously repeats on System A
>
> [WARN] [03/18/2014 09:36:00.427]
> [CalculatorWorkerSystem-akka.remote.default-remote-dispatcher-12]
> [akka.tcp://
> [email protected]:2552/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0]
> Association with remote system [akka.tcp://
> [email protected]:2554] has failed, address is now gated for
> [5000] ms. Reason is: [Association failed with
> [akka.tcp://[email protected]:2554]].
>
>
> Now if I try to start Creation on System B I see the following:
>
>
> Calculating 9329.0 / 80
> [WARN] [03/18/2014 09:14:57.059]
> [CalculatorWorkerSystem-akka.remote.default-remote-dispatcher-6]
> [akka.tcp://
> [email protected]:2552/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0]
> Association with remote system [akka.tcp://
> [email protected]:2554] has failed, address is now gated for
> [5000] ms. Reason is: [Association failed with
> [akka.tcp://[email protected]:2554]].
> Calculating 87 * 7
> Calculating 2127.0 / 80
> Calculating 1075.0 / 46
> Calculating 8937.0 / 15
> Calculating 5608.0 / 16
> [WARN] [03/18/2014 09:15:02.089]
> [CalculatorWorkerSystem-akka.remote.default-remote-dispatcher-6]
> [akka.tcp://
> [email protected]:2552/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCreationSystem%40192.168.14.136%3A2554-0]
> Association with remote system [akka.tcp://
> [email protected]:2554] has failed, address is now gated for
> [5000] ms. Reason is: [Association failed with
> [akka.tcp://[email protected]:2554]].
> Calculating 6424.0 / 8
> Calculating 97 * 20
> Calculating 8204.0 / 91
> Calculating 8716.0 / 80
> Calculating 2914.0 / 9
>
>
> This seems like System A is receiving the messages from System B which is
> fine but on System B I see the following:
>
>
> ./activator "run-main sample.remote.calculator.CreationApplication
> Creation"
> [info] Loading project definition from
> /home/rstratton/akka-sample-remote-java/project
> [warn] Multiple resolvers having different access mechanism configured
> with same name 'typesafe-ivy-releases'. To avoid conflict, Remove duplicate
> project resolvers (`resolvers`) or rename publishing resolver (`publishTo`).
> [info] Set current project to akka-sample-remote-java (in build
> file:/home/rstratton/akka-sample-remote-java/)
> [info] Running sample.remote.calculator.CreationApplication Creation
> [INFO] [03/18/2014 09:40:00.911] [run-main-0] [Remoting] Starting remoting
> [INFO] [03/18/2014 09:40:01.120] [run-main-0] [Remoting] Remoting started;
> listening on addresses :[akka.tcp://[email protected]:2554]
> [INFO] [03/18/2014 09:40:01.122] [run-main-0] [Remoting] Remoting now
> listens on addresses: [akka.tcp://[email protected]:2554]
> Started CreationSystem
> [WARN] [03/18/2014 09:40:19.140]
> [CreationSystem-akka.remote.default-remote-dispatcher-5] [akka.tcp://
> [email protected]:2554/system/remote-watcher] Detected
> unreachable: [akka.tcp://[email protected]:2552]
> [WARN] [03/18/2014 09:40:19.143]
> [CreationSystem-akka.remote.default-remote-dispatcher-13] [Remoting]
> Association to [akka.tcp://[email protected]:2552]
> with unknown UID is reported as quarantined, but address cannot be
> quarantined without knowing the UID, gating instead for 5000 ms.
> [INFO] [03/18/2014 09:40:19.158]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/deadLetters] Message [akka.remote.DaemonMsgCreate]
> from Actor[akka://CreationSystem/deadLetters] to
> Actor[akka://CreationSystem/deadLetters] 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] [03/18/2014 09:40:19.158]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/deadLetters] Message
> [sample.remote.calculator.Op$Multiply] from
> Actor[akka://CreationSystem/user/creationActor#-767125346] to
> Actor[akka://CreationSystem/deadLetters] 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'.
> [INFO] [03/18/2014 09:40:19.163]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-0/endpointWriter]
> Message [akka.actor.FSM$Timer] from
> Actor[akka://CreationSystem/deadLetters] to
> Actor[akka://CreationSystem/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-0/endpointWriter#964741640]
> was not delivered. [3] 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] [03/18/2014 09:40:19.164]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-0/endpointWriter/endpointReader-akka.tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-0]
> Message [akka.remote.transport.AssociationHandle$Disassociated] from
> Actor[akka://CreationSystem/deadLetters] to
> Actor[akka://CreationSystem/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-0/endpointWriter/endpointReader-akka.tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-0#2142222706]
> was not delivered. [4] 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] [03/18/2014 09:40:19.171]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-1]
> Message [akka.remote.transport.AssociationHandle$Disassociated] from
> Actor[akka://CreationSystem/deadLetters] to
> Actor[akka://CreationSystem/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FCalculatorWorkerSystem%40192.168.12.23%3A2552-1#-1191318212]
> was not delivered. [5] 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] [03/18/2014 09:40:20.140]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/deadLetters] Message [akka.remote.DaemonMsgCreate]
> from Actor[akka://CreationSystem/deadLetters] to
> Actor[akka://CreationSystem/deadLetters] was not delivered. [6] 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] [03/18/2014 09:40:20.140]
> [CreationSystem-akka.actor.default-dispatcher-3]
> [akka://CreationSystem/deadLetters] Message
> [sample.remote.calculator.Op$Multiply] from
> Actor[akka://CreationSystem/user/creationActor#-767125346] to
> Actor[akka://CreationSystem/deadLetters] was not delivered. [7] 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 again for your help
>
> Rob
>
>
> On Monday, March 17, 2014 3:42:01 PM UTC-4, Rob S wrote:
>
>> Hi all,
>>
>> I am starting out with remote actors and I have run into an issue I can't
>> seem to find an answer for.  I have setup an application that performs
>> distributed work on remote systems.  Simply I have an actor system on one
>> computer that sends a work request to a remote actor, the remote performs
>> the work and returns the result.  This process works perfectly.  My issue
>> comes in when I shutdown the requesting actor system and trying to start it
>> up again.  I get a connection refused on the remote system and I can not
>> pass any messages to the remote system anymore.  When I restart both
>> applications everything works fine.  I am using Akka 2.3.0
>>
>>
>> 1. System A starts up
>> 2. System B starts up and sends request to System A
>> 3. System A sends a reply to System B
>> 4. System B shutsdown
>> 5. System B starts up and sends request to System A
>> 6. System A outputs connection refused
>>
>> Rob
>>
>  --
> >>>>>>>>>> Read the docs: http://akka.io/docs/
> >>>>>>>>>> Check the FAQ:
> http://doc.akka.io/docs/akka/current/additional/faq.html
> >>>>>>>>>> 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/d/optout.
>



-- 

Patrik Nordwall
Typesafe <http://typesafe.com/> -  Reactive apps on the JVM
Twitter: @patriknw

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      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/d/optout.

Reply via email to