Hi Łukas,

there are two components to consider when it comes to hostname:port:

the local bind address
the address that is advertised to communication partners

The second one is needed because a system we are talking to might need to 
connect back (e.g. after a connection failure). ActorRefs contain the second 
part whenever they are sent abroad, so that any system which gets hold of a ref 
has a means to talk to the actor that this ref points to.

Now the choice that you are talking is about is whether or not the two cases 
above should have identical answers or not. We currently require the bind 
address and the externally reachable address to be exactly equal. No magic 
occurs during comparisons because doing name lookups etc. would just make this 
process completely non-understandable in the large.

There is one change that we are currently investigating: it might make sense to 
explicitly configure the bind address to be different from the system’s 
external name. This would be required in order to make ActorSystems reachable 
within Docker containers. But using that within EC2 would mean that different 
nodes in the cloud would talk to each other via their public IPs (if they need 
to be externally visible as well—something I would strongly recommend against 
but which we have been asked about nevertheless).

Coming back to your initial log snippets: it seems that mismatching 
hostname:port information is the source of your troubles.

Regards,

Roland

13 jun 2014 kl. 11:36 skrev Łukasz Kuczera <[email protected]>:

> Patrik, there is no firewall between those machines. 
> 
> I understand that NAT is not supported and it is quite common for servers to 
> have more than one interface. While NAT is problematic, being able to receive 
> messages directed to different network interfaces by single Akka application 
> is something rather expected. Otherwise it binds Akka deployments to low 
> level network topography and makes complex setups much harder to implement 
> and manage.
> 
> On Friday, June 13, 2014 8:05:16 AM UTC+2, Patrik Nordwall wrote:
> Hi,
> 
> NAT setups are not supported as explained here: 
> http://doc.akka.io/docs/akka/2.3.3/general/remoting.html#Peer-to-Peer_vs__Client-Server
> and the the hostname must be exactly the same as the configured 
> akka.remote.netty.tcp.hostname
> 
> Does that explain your issue?
> 
> /Patrik
> 
> 
> On Wed, Jun 11, 2014 at 11:40 PM, Łukasz Kuczera <[email protected]> wrote:
> Hello hAkkers.
> I've strange problems with mentioned upgrade. Communication with remote 
> actors work but only partially. There are two components that talk to each 
> other via remoting. Here is excerpt from the logs.
> 
> Portal:
> 
> [INFO] [06/10/2014 19:46:42.312] 
> [QLP-SCRIBE-CLIENT-akka.actor.default-dispatcher-4] 
> [akka://QLP-SCRIBE-CLIENT/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FQLP-SCRIBE-CLIENT%4010.68.177.228%3A44658-5]
>  Message [akka.remote.transport.AssociationHandle$Disassociated] from 
> Actor[akka://QLP-SCRIBE-CLIENT/deadLetters] to 
> Actor[akka://QLP-SCRIBE-CLIENT/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FQLP-SCRIBE-CLIENT%4010.68.177.228%3A44658-5#-1710053545]
>  was not delivered. [8] 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] [06/10/2014 19:46:42.313] 
> [QLP-SCRIBE-CLIENT-akka.actor.default-dispatcher-4] 
> [akka://QLP-SCRIBE-CLIENT/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FQLP-SCRIBE-CLIENT%4010.68.177.228%3A44658-5]
>  Message [akka.remote.transport.ActorTransportAdapter$DisassociateUnderlying] 
> from Actor[akka://QLP-SCRIBE-CLIENT/deadLetters] to 
> Actor[akka://QLP-SCRIBE-CLIENT/system/transports/akkaprotocolmanager.tcp0/akkaProtocol-tcp%3A%2F%2FQLP-SCRIBE-CLIENT%4010.68.177.228%3A44658-5#-1710053545]
>  was not delivered. [9] 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'.
> 
> 
> and here is database:
> 
> [WARN] [06/10/2014 20:00:00.197] 
> [new-scribe-system-akka.remote.default-remote-dispatcher-24] 
> [akka.tcp://[email protected]:5225/system/endpointManager/reliableEndpointWriter-akka.tcp%3A%2F%2FQLP-SCRIBE-CLIENT%4010.101.159.54%3A5225-1]
>  Association with remote system 
> [akka.tcp://[email protected]:5225] has failed, address is now 
> gated for [5000] ms. Reason is: [Disassociated].
> 
> What I figured out so far it seems that they try to communicate via local 
> address. Not public. This is deployed on Amazon AWS, locally it works fine. 
> What's also interesting is that some messages do work but some do not. I ran 
> that locally with exact same data and it worked. 
> 
> Last but not least I'm not sure if that is a feature or a bug (for me it is a 
> bug) but host name resolution doesn't work well with Akka remoting. If I have 
> one node that is configured to listen on specific address A then if message 
> arrive on another interface but on the same host it doesn't work. Even 
> localhost vs. 127.0.0.1 fails with log message that it wasn't targeted to 
> "me".
> 
> Sorry for lengthy post. I hope someone can chime in and help.
> 
> -- 
> >>>>>>>>>> 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 -  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.



Dr. Roland Kuhn
Akka Tech Lead
Typesafe – Reactive apps on the JVM.
twitter: @rolandkuhn


-- 
>>>>>>>>>>      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