Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #783 from akka/wip-2604-remote-config-∂π

add small hint for programmatic remoting config, see #2604
  • Loading branch information...
commit 39b4b52e6ba9f4526feb9cec90c48b881d57a5fe 2 parents 89c1f66 + 2bf9b32
@rkuhn rkuhn authored
View
10 akka-docs/rst/java/code/docs/remoting/RemoteDeploymentDocTestBase.java
@@ -7,6 +7,8 @@
import org.junit.BeforeClass;
import org.junit.Test;
+import com.typesafe.config.ConfigFactory;
+
//#import
import akka.actor.ActorRef;
import akka.actor.Address;
@@ -60,6 +62,14 @@ public void demonstrateSampleActor() {
actor.tell("Pretty slick", null);
//#sample-actor
}
+
+ @Test
+ public void demonstrateProgrammaticConfig() {
+ //#programmatic
+ ConfigFactory.parseString("akka.remote.netty.hostname=\"1.2.3.4\"")
+ .withFallback(ConfigFactory.load());
+ //#programmatic
+ }
}
View
7 akka-docs/rst/java/remoting.rst
@@ -60,6 +60,13 @@ reference file for more information:
.. literalinclude:: ../../../akka-remote/src/main/resources/reference.conf
:language: none
+.. note::
+
+ Setting properties like the listening IP and port number programmatically is
+ best done by using something like the following:
+
+ .. includecode:: code/docs/remoting/RemoteDeploymentDocTestBase.java#programmatic
+
Looking up Remote Actors
^^^^^^^^^^^^^^^^^^^^^^^^
View
7 akka-docs/rst/scala/remoting.rst
@@ -57,6 +57,13 @@ reference file for more information:
.. literalinclude:: ../../../akka-remote/src/main/resources/reference.conf
:language: none
+.. note::
+
+ Setting properties like the listening IP and port number programmatically is
+ best done by using something like the following:
+
+ .. includecode:: ../java/code/docs/remoting/RemoteDeploymentDocTestBase.java#programmatic
+
Types of Remote Interaction
^^^^^^^^^^^^^^^^^^^^^^^^^^^
Please sign in to comment.
Something went wrong with that request. Please try again.