#22909 Fix parameters

* @binVersion@
* @github@
* @samples@
* @exampleCodeService@
This commit is contained in:
Martynas Mickevičius 2017-05-12 16:07:51 +03:00
parent 4cb9c2436f
commit 0e7a8e1e61
40 changed files with 320 additions and 253 deletions

View file

@ -17,8 +17,13 @@ enablePlugins(AkkaParadoxPlugin)
paradoxProperties ++= Map(
"extref.wikipedia.base_url" -> "https://en.wikipedia.org/wiki/%s",
"extref.github.base_url" -> ("http://github.com/akka/akka/tree/" + (if (isSnapshot.value) "master" else "v" + version.value) + "/%s"),
"extref.samples.base_url" -> "http://github.com/akka/akka-samples/tree/master/%s",
"extref.ecs.base_url" -> "https://example.lightbend.com/v1/download/%s",
"scala.version" -> scalaVersion.value,
"scala.binary_version" -> scalaBinaryVersion.value,
"akka.version" -> version.value,
"sigar_loader.version" -> "1.6.6-rev002",
"snip.code.base_dir" -> (sourceDirectory in Test).value.getAbsolutePath,
"snip.akka.base_dir" -> ((baseDirectory in Test).value / "..").getAbsolutePath
)

View file

@ -71,8 +71,8 @@ You can also create a CamelMessage yourself with the appropriate body and header
The akka-camel module is implemented as an Akka Extension, the `CamelExtension` object.
Extensions will only be loaded once per `ActorSystem`, which will be managed by Akka.
The `CamelExtension` object provides access to the [Camel](@github@/akka-camel/src/main/scala/akka/camel/Camel.scala) interface.
The [Camel](@github@/akka-camel/src/main/scala/akka/camel/Camel.scala) interface in turn provides access to two important Apache Camel objects, the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) and the `ProducerTemplate`.
The `CamelExtension` object provides access to the @extref[Camel](github:akka-camel/src/main/scala/akka/camel/Camel.scala) interface.
The @extref[Camel](github:akka-camel/src/main/scala/akka/camel/Camel.scala) interface in turn provides access to two important Apache Camel objects, the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) and the `ProducerTemplate`.
Below you can see how you can get access to these Apache Camel objects.
@@snip [CamelExtensionTest.java]($code$/java/jdocs/camel/CamelExtensionTest.java) { #CamelExtension }
@ -80,7 +80,7 @@ Below you can see how you can get access to these Apache Camel objects.
One `CamelExtension` is only loaded once for every one `ActorSystem`, which makes it safe to call the `CamelExtension` at any point in your code to get to the
Apache Camel objects associated with it. There is one [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) and one `ProducerTemplate` for every one `ActorSystem` that uses a `CamelExtension`.
By Default, a new [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) is created when the `CamelExtension` starts. If you want to inject your own context instead,
you can implement the [ContextProvider](@github@/akka-camel/src/main/scala/akka/camel/ContextProvider.scala) interface and add the FQCN of your implementation in the config, as the value of the "akka.camel.context-provider".
you can implement the @extref[ContextProvider](github:akka-camel/src/main/scala/akka/camel/ContextProvider.scala) interface and add the FQCN of your implementation in the config, as the value of the "akka.camel.context-provider".
This interface define a single method `getContext()` used to load the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java).
Below an example on how to add the ActiveMQ component to the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java), which is required when you would like to use the ActiveMQ component.
@ -98,7 +98,7 @@ Actors are created and started asynchronously. When a *Consumer* actor is create
When a *Producer* actor is created, a [SendProcessor](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/processor/SendProcessor.java) and [Endpoint](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/Endpoint.java) are created so that the Producer can send messages to it.
Publication is done asynchronously; setting up an endpoint may still be in progress after you have
requested the actor to be created. Some Camel components can take a while to startup, and in some cases you might want to know when the endpoints are activated and ready to be used.
The [Camel](@github@/akka-camel/src/main/scala/akka/camel/Camel.scala) interface allows you to find out when the endpoint is activated or deactivated.
The @extref[Camel](github:akka-camel/src/main/scala/akka/camel/Camel.scala) interface allows you to find out when the endpoint is activated or deactivated.
@@snip [ActivationTestBase.java]($code$/java/jdocs/camel/ActivationTestBase.java) { #CamelActivation }
@ -112,9 +112,9 @@ A `DeActivationTimeoutException` is thrown if the associated camel objects could
## Consumer Actors
For objects to receive messages, they must inherit from the [UntypedConsumerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedConsumer.scala)
For objects to receive messages, they must inherit from the @extref[UntypedConsumerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedConsumer.scala)
class. For example, the following actor class (Consumer1) implements the
*getEndpointUri* method, which is declared in the [UntypedConsumerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedConsumer.scala) class, in order to receive
*getEndpointUri* method, which is declared in the @extref[UntypedConsumerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedConsumer.scala) class, in order to receive
messages from the `file:data/input/actor` Camel endpoint.
@@snip [Consumer1.java]($code$/java/jdocs/camel/Consumer1.java) { #Consumer1 }
@ -168,7 +168,7 @@ way which is described in the documentation of the individual Camel
components. Another option is to configure timeouts on the level of consumer actors.
Two-way communications between a Camel endpoint and an actor are
initiated by sending the request message to the actor with the [ask](@github@/akka-actor/src/main/scala/akka/pattern/Patterns.scala) pattern
initiated by sending the request message to the actor with the @extref[ask](github:akka-actor/src/main/scala/akka/pattern/Patterns.scala) pattern
and the actor replies to the endpoint when the response is ready. The ask request to the actor can timeout, which will
result in the [Exchange](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/Exchange.java) failing with a TimeoutException set on the failure of the [Exchange](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/Exchange.java).
The timeout on the consumer actor can be overridden with the `replyTimeout`, as shown below.
@ -177,18 +177,18 @@ The timeout on the consumer actor can be overridden with the `replyTimeout`, as
## Producer Actors
For sending messages to Camel endpoints, actors need to inherit from the [UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) class and implement the getEndpointUri method.
For sending messages to Camel endpoints, actors need to inherit from the @extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) class and implement the getEndpointUri method.
@@snip [Producer1.java]($code$/java/jdocs/camel/Producer1.java) { #Producer1 }
Producer1 inherits a default implementation of the onReceive method from the
[UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) class. To customize a producer actor's default behavior you must override the [UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onTransformResponse and
[UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onTransformOutgoingMessage methods. This is explained later in more detail.
Producer Actors cannot override the [UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onReceive method.
@extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) class. To customize a producer actor's default behavior you must override the @extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onTransformResponse and
@extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onTransformOutgoingMessage methods. This is explained later in more detail.
Producer Actors cannot override the @extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onReceive method.
Any message sent to a Producer actor will be sent to
the associated Camel endpoint, in the above example to
`http://localhost:8080/news`. The [UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) always sends messages asynchronously. Response messages (if supported by the
`http://localhost:8080/news`. The @extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) always sends messages asynchronously. Response messages (if supported by the
configured endpoint) will, by default, be returned to the original sender. The
following example uses the ask pattern to send a message to a
Producer actor and waits for a response.
@ -212,7 +212,7 @@ sender.
@@snip [OnRouteResponseTestBase.java]($code$/java/jdocs/camel/OnRouteResponseTestBase.java) { #RouteResponse }
Before producing messages to endpoints, producer actors can pre-process them by
overriding the [UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onTransformOutgoingMessage method.
overriding the @extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala).onTransformOutgoingMessage method.
@@snip [Transformer.java]($code$/java/jdocs/camel/Transformer.java) { #TransformOutgoingMessage }
@ -234,7 +234,7 @@ To correlate request with response messages, applications can set the
### ProducerTemplate
The [UntypedProducerActor](@github@/akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) class is a very convenient way for actors to produce messages to Camel endpoints.
The @extref[UntypedProducerActor](github:akka-camel/src/main/scala/akka/camel/javaapi/UntypedProducerActor.scala) class is a very convenient way for actors to produce messages to Camel endpoints.
Actors may also use a Camel `ProducerTemplate` for producing messages to endpoints.
@@snip [MyActor.java]($code$/java/jdocs/camel/MyActor.java) { #ProducerTemplate }
@ -387,7 +387,7 @@ akka-camel may make some further modifications to it.
<a id="camel-examples"></a>
## Examples
The sample named [Akka Camel Samples with Java](@exampleCodeService@/akka-samples-camel-java) ([source code](@samples@/akka-sample-camel-java))
The sample named @extref[Akka Camel Samples with Java](ecs:akka-samples-camel-java) (@extref[source code](samples:akka-sample-camel-java))
contains 3 samples:
>

View file

@ -139,21 +139,23 @@ Similarly we can have an actor that behaves in a similar fashion for learning wh
To use the Cluster Client you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-tools" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-tools" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-tools_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-tools_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
<a id="cluster-client-config"></a>
## Configuration

View file

@ -14,13 +14,15 @@ Cluster Metrics Extension is a separate Akka module delivered in `akka-cluster-m
To enable usage of the extension you need to add the following dependency to your project:
:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-metrics_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-cluster-metrics_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
and add the following configuration stanza to your `application.conf`
:
@ -98,13 +100,15 @@ unique per instance directory. You can control the extract directory with the
To enable usage of Sigar you can add the following dependency to the user project
:
@@@vars
```
<dependency>
<groupId>io.kamon</groupId>
<artifactId>sigar-loader</artifactId>
<version>@sigarLoaderVersion@</version>
<version>$sigar_loader.version$</version>
</dependency>
```
@@@
You can download Kamon sigar-loader from [Maven Central](http://search.maven.org/#search%7Cga%7C1%7Csigar-loader)
@ -165,9 +169,9 @@ The same type of router could also have been defined in code:
@@snip [FactorialFrontend.java]($code$/java/jdocs/cluster/FactorialFrontend.java) { #router-deploy-in-code }
The easiest way to run **Adaptive Load Balancing** example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-java)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-java)
together with the tutorial. It contains instructions on how to run the **Adaptive Load Balancing** sample.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-java).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-java).
## Subscribe to Metrics Events

View file

@ -373,21 +373,23 @@ different persistenceId.
To use the Cluster Sharding you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-sharding" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-sharding" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-sharding_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-sharding_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Configuration

View file

@ -106,21 +106,24 @@ A more comprehensive sample is available in the tutorial named [Distributed work
To use the Cluster Singleton you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-tools" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-tools" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-tools_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-tools_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Configuration

View file

@ -6,13 +6,15 @@ For introduction to the Akka Cluster concepts please see @ref:[Cluster Specifica
The Akka cluster is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-cluster_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
<a id="cluster-simple-example"></a>
## A Simple Cluster Example
@ -82,9 +84,9 @@ The actor registers itself as subscriber of certain cluster events. It receives
of the cluster when the subscription starts and then it receives events for changes that happen in the cluster.
The easiest way to run this example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-java)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-java)
together with the tutorial. It contains instructions on how to run the `SimpleClusterApp`.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-java).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-java).
## Joining to Seed Nodes
@ -739,7 +741,7 @@ or similar instead.
@@@
The cluster can be managed with the script `akka-cluster` provided in the Akka github repository here: [@github@/akka-cluster/jmx-client](@github@/akka-cluster/jmx-client). Place the script and the `jmxsh-R5.jar` library in the same directory.
The cluster can be managed with the script `akka-cluster` provided in the Akka github repository @extref[here](github:akka-cluster/jmx-client). Place the script and the `jmxsh-R5.jar` library in the same directory.
Run it without parameters to see instructions about how to use the script:

View file

@ -579,7 +579,7 @@ API documentation of the `Replicator` for details.
## Samples
Several interesting samples are included and described in the
tutorial named [Akka Distributed Data Samples with Java](@exampleCodeService@/akka-samples-distributed-data-java) ([source code](@samples@/akka-sample-distributed-data-java))
tutorial named @extref[Akka Distributed Data Samples with Java](ecs:akka-samples-distributed-data-java) (@extref[source code](samples:akka-sample-distributed-data-java))
* Low Latency Voting Service
* Highly Available Shopping Cart
@ -624,21 +624,23 @@ paper by Mark Shapiro et. al.
To use Distributed Data you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-distributed-data" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-distributed-data" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-distributed-data_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-distributed-data_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Configuration

View file

@ -183,18 +183,20 @@ If you are looking for at-least-once delivery guarantee, we recommend [Kafka Akk
To use Distributed Publish Subscribe you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-tools" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-tools" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-tools_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-tools_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@

View file

@ -32,7 +32,7 @@ for any concrete implementation.
The classifiers presented here are part of the Akka distribution, but rolling
your own in case you do not find a perfect match is not difficult, check the
implementation of the existing ones on [github](@github@/akka-actor/src/main/scala/akka/event/EventBus.scala)
implementation of the existing ones on @extref[github](github:akka-actor/src/main/scala/akka/event/EventBus.scala)
### Lookup Classification

View file

@ -432,6 +432,6 @@ zero.
## Examples
A bigger FSM example contrasted with Actor's `become`/`unbecome` can be
downloaded as a ready to run [Akka FSM sample](@exampleCodeService@/akka-samples-fsm-java)
downloaded as a ready to run @extref[Akka FSM sample](ecs:akka-samples-fsm-java)
together with a tutorial. The source code of this sample can be found in the
[Akka Samples Repository](@samples@/akka-sample-fsm-java).
@extref[Akka Samples Repository](samples:akka-sample-fsm-java).

View file

@ -180,7 +180,7 @@ to the network socket.
These write models (with the exception of the second which is rather specialised) are
demonstrated in complete examples below. The full and contiguous source is
available [on GitHub](@github@/akka-docs/rst/java/code/jdocs/io/japi).
available @extref[on GitHub](github:akka-docs/rst/java/code/jdocs/io/japi).
For back-pressuring reads there are two modes of operation

View file

@ -8,13 +8,15 @@ Note that implementations for other journals may have different semantics.
Akka persistence LevelDB query implementation is bundled in the `akka-persistence-query` artifact.
Make sure that you have the following dependency in your project:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-persistence-query_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-persistence-query_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## How to get the ReadJournal

View file

@ -14,13 +14,15 @@ recommend (in the spirit of CQRS) of splitting up the write/read sides into sepa
Akka persistence query is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-persistence-query_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-persistence-query_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Design overview

View file

@ -13,13 +13,15 @@ communication with at-least-once message delivery semantics.
Akka persistence is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-persistence_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-persistence_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
The Akka persistence extension comes with few built-in persistence plugins, including
in-memory heap based journal, local file-system based snapshot-store and LevelDB based journal.
@ -104,9 +106,9 @@ stored, e.g. due to serialization error, `onPersistRejected` will be invoked (lo
by default), and the actor continues with next message.
The easiest way to run this example yourself is to download the ready to run
[Akka Persistence Sample with Scala](@exampleCodeService@/akka-samples-persistence-java)
@extref[Akka Persistence Sample with Scala](ecs:akka-samples-persistence-java)
together with the tutorial. It contains instructions on how to run the `PersistentActorExample`.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-persistence-java).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-persistence-java).
@@@ note
@ -897,7 +899,7 @@ The TCK is usable from Java as well as Scala projects. For Java you need to incl
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-persistence-tck_${scala.version}</artifactId>
<version>@version@</version>
<version>$akka.version$</version>
<scope>test</scope>
</dependency>
```

View file

@ -45,13 +45,15 @@ are also different.
The Akka remoting is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-remote_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
To enable remote capabilities in your Akka project you should, at a minimum, add the following changes
to your `application.conf` file:
@ -569,9 +571,9 @@ That is not done by the router.
<a id="remote-sample-java-artery"></a>
## Remoting Sample
You can download a ready to run [remoting sample](@exampleCodeService@/akka-samples-remote-java)
You can download a ready to run @extref[remoting sample](ecs:akka-samples-remote-java)
together with a tutorial for a more hands-on experience. The source code of this sample can be found in the
[Akka Samples Repository](@samples@/akka-sample-remote-java).
@extref[Akka Samples Repository](samples:akka-sample-remote-java).
## Performance tuning
@ -717,7 +719,7 @@ the system might have less latency than at low message rates.
@@@ note
In this version (@version@) the flight-recorder is disabled by default because there is no automatic
In this version ($akka.version$) the flight-recorder is disabled by default because there is no automatic
file name and path calculation implemented to make it possible to reuse the same file for every restart of
the same actor system without clashing with files produced by other systems (possibly running on the same machine).
Currently, you have to set the path and file names yourself to avoid creating an unbounded number

View file

@ -17,13 +17,15 @@ network and/or Akka configuration will have to be changed as described in
The Akka remoting is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-remote_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
To enable remote capabilities in your Akka project you should, at a minimum, add the following changes
to your `application.conf` file:
@ -368,9 +370,9 @@ That is not done by the router.
<a id="remote-sample"></a>
## Remoting Sample
You can download a ready to run [remoting sample](@exampleCodeService@/akka-samples-remote-java)
You can download a ready to run @extref[remoting sample](ecs:akka-samples-remote-java)
together with a tutorial for a more hands-on experience. The source code of this sample can be found in the
[Akka Samples Repository](@samples@/akka-sample-remote-java).
@extref[Akka Samples Repository](samples:akka-sample-remote-java).
### Remote Events

View file

@ -867,7 +867,7 @@ behavior is not the default).
### Encoding Scala Actors nested receives without accidentally leaking memory
See this [Unnested receive example](@github@/akka-docs/rst/scala/code/docs/actor/UnnestedReceives.scala).
See this @extref[Unnested receive example](github:akka-docs/src/main/scala/docs/actor/UnnestedReceives.scala).
<a id="stash"></a>
## Stash

View file

@ -70,7 +70,7 @@ in an application composed of multiple JARs to reside under a single package nam
might scan all classes from `com.example.plugins` for specific service implementations with that package existing in
several contributed JARs.
While it is possible to support overlapping packages with complex manifest headers, it's much better to use non-overlapping
package spaces and facilities such as [Akka Cluster](@github@/akka-docs/rst/scala/code/docs/akka/current/common/cluster.html)
package spaces and facilities such as @extref[Akka Cluster](github:akka-docs/rst/scala/code/docs/akka/current/common/cluster.html)
for service discovery. Stylistically, many organizations opt to use the root package path as the name of the bundle
distribution file.
@ -104,14 +104,16 @@ from the application bundle and all transitive dependencies.
The `ActorSystemActivator` class is included in the `akka-osgi` artifact:
@@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-osgi_@binVersion@</artifactId>
<version>@version@</version>
<artifactId>akka-osgi_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Sample
A complete sample project is provided in [akka-sample-osgi-dining-hakkers](@samples@/tree/master/akka-sample-osgi-dining-hakkers)
A complete sample project is provided in @extref[akka-sample-osgi-dining-hakkers](samples:akka-sample-osgi-dining-hakkers)

View file

@ -69,8 +69,8 @@ You can also create a CamelMessage yourself with the appropriate body and header
The akka-camel module is implemented as an Akka Extension, the `CamelExtension` object.
Extensions will only be loaded once per `ActorSystem`, which will be managed by Akka.
The `CamelExtension` object provides access to the [Camel](@github@/akka-camel/src/main/scala/akka/camel/Camel.scala) trait.
The [Camel](@github@/akka-camel/src/main/scala/akka/camel/Camel.scala) trait in turn provides access to two important Apache Camel objects, the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) and the `ProducerTemplate`.
The `CamelExtension` object provides access to the @extref[Camel](github:akka-camel/src/main/scala/akka/camel/Camel.scala) trait.
The @extref[Camel](github:akka-camel/src/main/scala/akka/camel/Camel.scala) trait in turn provides access to two important Apache Camel objects, the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) and the `ProducerTemplate`.
Below you can see how you can get access to these Apache Camel objects.
@@snip [Introduction.scala]($code$/scala/docs/camel/Introduction.scala) { #CamelExtension }
@ -78,7 +78,7 @@ Below you can see how you can get access to these Apache Camel objects.
One `CamelExtension` is only loaded once for every one `ActorSystem`, which makes it safe to call the `CamelExtension` at any point in your code to get to the
Apache Camel objects associated with it. There is one [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) and one `ProducerTemplate` for every one `ActorSystem` that uses a `CamelExtension`.
By Default, a new [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java) is created when the `CamelExtension` starts. If you want to inject your own context instead,
you can extend the [ContextProvider](@github@/akka-camel/src/main/scala/akka/camel/ContextProvider.scala) trait and add the FQCN of your implementation in the config, as the value of the "akka.camel.context-provider".
you can extend the @extref[ContextProvider](github:akka-camel/src/main/scala/akka/camel/ContextProvider.scala) trait and add the FQCN of your implementation in the config, as the value of the "akka.camel.context-provider".
This interface define a single method `getContext` used to load the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java).
Below an example on how to add the ActiveMQ component to the [CamelContext](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/CamelContext.java), which is required when you would like to use the ActiveMQ component.
@ -94,7 +94,7 @@ Actors are created and started asynchronously. When a *Consumer* actor is create
When a *Producer* actor is created, a [SendProcessor](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/processor/SendProcessor.java) and [Endpoint](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/Endpoint.java) are created so that the Producer can send messages to it.
Publication is done asynchronously; setting up an endpoint may still be in progress after you have
requested the actor to be created. Some Camel components can take a while to startup, and in some cases you might want to know when the endpoints are activated and ready to be used.
The [Camel](@github@/akka-camel/src/main/scala/akka/camel/Camel.scala) trait allows you to find out when the endpoint is activated or deactivated.
The @extref[Camel](github:akka-camel/src/main/scala/akka/camel/Camel.scala) trait allows you to find out when the endpoint is activated or deactivated.
@@snip [Introduction.scala]($code$/scala/docs/camel/Introduction.scala) { #CamelActivation }
@ -108,7 +108,7 @@ A `DeActivationTimeoutException` is thrown if the associated camel objects could
## Consumer Actors
For objects to receive messages, they must mixin the [Consumer](@github@/akka-camel/src/main/scala/akka/camel/Consumer.scala)
For objects to receive messages, they must mixin the @extref[Consumer](github:akka-camel/src/main/scala/akka/camel/Consumer.scala)
trait. For example, the following actor class (Consumer1) implements the
endpointUri method, which is declared in the Consumer trait, in order to receive
messages from the `file:data/input/actor` Camel endpoint.
@ -118,7 +118,7 @@ messages from the `file:data/input/actor` Camel endpoint.
Whenever a file is put into the data/input/actor directory, its content is
picked up by the Camel [file component](http://camel.apache.org/file2.html) and sent as message to the
actor. Messages consumed by actors from Camel endpoints are of type
[CamelMessage](@github@/akka-camel/src/main/scala/akka/camel/CamelMessage.scala). These are immutable representations of Camel messages.
@extref[CamelMessage](github:akka-camel/src/main/scala/akka/camel/CamelMessage.scala). These are immutable representations of Camel messages.
Here's another example that sets the endpointUri to
`jetty:http://localhost:8877/camel/default`. It causes Camel's Jetty
@ -130,7 +130,7 @@ from localhost on port 8877.
After starting the actor, clients can send messages to that actor by POSTing to
`http://localhost:8877/camel/default`. The actor sends a response by using the
sender *!* method. For returning a message body and headers to the HTTP
client the response type should be [CamelMessage](@github@/akka-camel/src/main/scala/akka/camel/CamelMessage.scala). For any other response type, a
client the response type should be @extref[CamelMessage](github:akka-camel/src/main/scala/akka/camel/CamelMessage.scala). For any other response type, a
new CamelMessage object is created by akka-camel with the actor response as message
body.
@ -164,7 +164,7 @@ way which is described in the documentation of the individual Camel
components. Another option is to configure timeouts on the level of consumer actors.
Two-way communications between a Camel endpoint and an actor are
initiated by sending the request message to the actor with the [ask](@github@/akka-actor/src/main/scala/akka/pattern/AskSupport.scala) pattern
initiated by sending the request message to the actor with the @extref[ask](github:akka-actor/src/main/scala/akka/pattern/AskSupport.scala) pattern
and the actor replies to the endpoint when the response is ready. The ask request to the actor can timeout, which will
result in the [Exchange](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/Exchange.java) failing with a TimeoutException set on the failure of the [Exchange](https://svn.apache.org/repos/asf/camel/tags/camel-2.8.0/camel-core/src/main/java/org/apache/camel/Exchange.java).
The timeout on the consumer actor can be overridden with the `replyTimeout`, as shown below.
@ -173,18 +173,18 @@ The timeout on the consumer actor can be overridden with the `replyTimeout`, as
## Producer Actors
For sending messages to Camel endpoints, actors need to mixin the [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala) trait and implement the endpointUri method.
For sending messages to Camel endpoints, actors need to mixin the @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala) trait and implement the endpointUri method.
@@snip [Producers.scala]($code$/scala/docs/camel/Producers.scala) { #Producer1 }
Producer1 inherits a default implementation of the receive method from the
Producer trait. To customize a producer actor's default behavior you must override the [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala).transformResponse and
[Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala).transformOutgoingMessage methods. This is explained later in more detail.
Producer Actors cannot override the default [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala).receive method.
Producer trait. To customize a producer actor's default behavior you must override the @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala).transformResponse and
@extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala).transformOutgoingMessage methods. This is explained later in more detail.
Producer Actors cannot override the default @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala).receive method.
Any message sent to a [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala) actor will be sent to
Any message sent to a @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala) actor will be sent to
the associated Camel endpoint, in the above example to
`http://localhost:8080/news`. The [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala) always sends messages asynchronously. Response messages (if supported by the
`http://localhost:8080/news`. The @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala) always sends messages asynchronously. Response messages (if supported by the
configured endpoint) will, by default, be returned to the original sender. The
following example uses the ask pattern to send a message to a
Producer actor and waits for a response.
@ -204,7 +204,7 @@ sender.
@@snip [Producers.scala]($code$/scala/docs/camel/Producers.scala) { #RouteResponse }
Before producing messages to endpoints, producer actors can pre-process them by
overriding the [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala).transformOutgoingMessage method.
overriding the @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala).transformOutgoingMessage method.
@@snip [Producers.scala]($code$/scala/docs/camel/Producers.scala) { #TransformOutgoingMessage }
@ -226,7 +226,7 @@ To correlate request with response messages, applications can set the
### ProducerTemplate
The [Producer](@github@/akka-camel/src/main/scala/akka/camel/Producer.scala) trait is a very
The @extref[Producer](github:akka-camel/src/main/scala/akka/camel/Producer.scala) trait is a very
convenient way for actors to produce messages to Camel endpoints. Actors may also use a Camel
`ProducerTemplate` for producing messages to endpoints.
@ -377,7 +377,7 @@ akka-camel may make some further modifications to it.
<a id="camel-examples"></a>
## Examples
The sample named [Akka Camel Samples with Scala](@exampleCodeService@/akka-samples-camel-scala) ([source code](@samples@/akka-sample-camel-scala))
The sample named @extref[Akka Camel Samples with Scala](ecs:akka-samples-camel-scala) (@extref[source code](samples:akka-sample-camel-scala))
contains 3 samples:
>

View file

@ -139,21 +139,23 @@ Similarly we can have an actor that behaves in a similar fashion for learning wh
To use the Cluster Client you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-tools" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-tools" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-tools_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-tools_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
<a id="cluster-client-config"></a>
## Configuration

View file

@ -14,9 +14,11 @@ Cluster Metrics Extension is a separate Akka module delivered in `akka-cluster-m
To enable usage of the extension you need to add the following dependency to your project:
:
@@@vars
```
"com.typesafe.akka" % "akka-cluster-metrics_@binVersion@" % "@version@"
"com.typesafe.akka" % "akka-cluster-metrics_$scala.binary_version$" % "$akka.version$"
```
@@@
and add the following configuration stanza to your `application.conf`
:
@ -94,9 +96,11 @@ unique per instance directory. You can control the extract directory with the
To enable usage of Sigar you can add the following dependency to the user project
:
@@@vars
```
"io.kamon" % "sigar-loader" % "@sigarLoaderVersion@"
"io.kamon" % "sigar-loader" % "$sigar_loader.version$"
```
@@@
You can download Kamon sigar-loader from [Maven Central](http://search.maven.org/#search%7Cga%7C1%7Csigar-loader)
@ -157,9 +161,9 @@ The same type of router could also have been defined in code:
@@snip [FactorialFrontend.scala]($code$/scala/docs/cluster/FactorialFrontend.scala) { #router-deploy-in-code }
The easiest way to run **Adaptive Load Balancing** example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-scala)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-scala)
together with the tutorial. It contains instructions on how to run the **Adaptive Load Balancing** sample.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-scala).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-scala).
## Subscribe to Metrics Events

View file

@ -375,21 +375,23 @@ different persistenceId.
To use the Cluster Sharding you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-sharding" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-sharding" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-sharding_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-sharding_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Configuration

View file

@ -110,21 +110,23 @@ A more comprehensive sample is available in the tutorial named [Distributed work
To use the Cluster Singleton you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-tools" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-tools" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-tools_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-tools_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Configuration

View file

@ -6,9 +6,11 @@ For introduction to the Akka Cluster concepts please see @ref:[Cluster Specifica
The Akka cluster is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-cluster" % "@version@" @crossString@
"com.typesafe.akka" %% "akka-cluster" % $akka.version$
```
@@@
## A Simple Cluster Example
@ -77,9 +79,9 @@ The actor registers itself as subscriber of certain cluster events. It receives
of the cluster when the subscription starts and then it receives events for changes that happen in the cluster.
The easiest way to run this example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-scala)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-scala)
together with the tutorial. It contains instructions on how to run the `SimpleClusterApp`.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-scala).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-scala).
## Joining to Seed Nodes
@ -331,9 +333,9 @@ actor. Death watch generates the `Terminated` message to the watching actor when
unreachable cluster node has been downed and removed.
The easiest way to run **Worker Dial-in Example** example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-scala)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-scala)
together with the tutorial. It contains instructions on how to run the **Worker Dial-in Example** sample.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-scala).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-scala).
## Node Roles
@ -623,9 +625,9 @@ This means that user requests can be sent to `StatsService` on any node and it w
`StatsWorker` on all nodes.
The easiest way to run **Router Example with Group of Routees** example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-scala)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-scala)
together with the tutorial. It contains instructions on how to run the **Router Example with Group of Routees** sample.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-scala).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-scala).
### Router with Pool of Remote Deployed Routees
@ -706,9 +708,9 @@ akka.actor.deployment {
```
The easiest way to run **Router Example with Pool of Remote Deployed Routees** example yourself is to download the ready to run
[Akka Cluster Sample with Scala](@exampleCodeService@/akka-samples-cluster-scala)
@extref[Akka Cluster Sample with Scala](ecs:akka-samples-cluster-scala)
together with the tutorial. It contains instructions on how to run the **Router Example with Pool of Remote Deployed Routees** sample.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-cluster-scala).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-cluster-scala).
## Cluster Metrics
@ -803,7 +805,7 @@ or similar instead.
@@@
The cluster can be managed with the script `akka-cluster` provided in the Akka github repository here: [@github@/akka-cluster/jmx-client](@github@/akka-cluster/jmx-client). Place the script and the `jmxsh-R5.jar` library in the same directory.
The cluster can be managed with the script `akka-cluster` provided in the Akka github repository @extref[here](github:akka-cluster/jmx-client). Place the script and the `jmxsh-R5.jar` library in the same directory.
Run it without parameters to see instructions about how to use the script:

View file

@ -583,7 +583,7 @@ API documentation of the `Replicator` for details.
## Samples
Several interesting samples are included and described in the
tutorial named [Akka Distributed Data Samples with Scala](@exampleCodeService@/akka-samples-distributed-data-scala) ([source code](@samples@/akka-sample-distributed-data-scala))
tutorial named @extref[Akka Distributed Data Samples with Scala](ecs:akka-samples-distributed-data-scala) (@extref[source code](samples:akka-sample-distributed-data-scala))
* Low Latency Voting Service
* Highly Available Shopping Cart
@ -628,21 +628,23 @@ paper by Mark Shapiro et. al.
To use Distributed Data you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-distributed-data" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-distributed-data" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-distributed-data_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-distributed-data_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@
## Configuration

View file

@ -186,18 +186,20 @@ If you are looking for at-least-once delivery guarantee, we recommend [Kafka Akk
To use Distributed Publish Subscribe you must add the following dependency in your project.
sbt:
sbt
: @@@vars
```
"com.typesafe.akka" %% "akka-cluster-tools" % $akka.version$
```
@@@
```
"com.typesafe.akka" %% "akka-cluster-tools" % "@version@" @crossString@
```
maven:
```
<dependency>
Maven
: @@@vars
```
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-cluster-tools_@binVersion@</artifactId>
<version>@version@</version>
</dependency>
```
<artifactId>akka-cluster-tools_$scala.binary_version$</artifactId>
<version>$akka.version$</version>
</dependency>
```
@@@

View file

@ -32,7 +32,7 @@ for any concrete implementation.
The classifiers presented here are part of the Akka distribution, but rolling
your own in case you do not find a perfect match is not difficult, check the
implementation of the existing ones on [github](@github@/akka-actor/src/main/scala/akka/event/EventBus.scala)
implementation of the existing ones on @extref[github](github:akka-actor/src/main/scala/akka/event/EventBus.scala)
### Lookup Classification

View file

@ -476,6 +476,6 @@ zero.
## Examples
A bigger FSM example contrasted with Actor's `become`/`unbecome` can be
downloaded as a ready to run [Akka FSM sample](@exampleCodeService@/akka-samples-fsm-scala)
downloaded as a ready to run @extref[Akka FSM sample](ecs:akka-samples-fsm-scala)
together with a tutorial. The source code of this sample can be found in the
[Akka Samples Repository](@samples@/akka-sample-fsm-scala).
@extref[Akka Samples Repository](samples:akka-sample-fsm-scala).

View file

@ -180,7 +180,7 @@ to the network socket.
These write back-pressure models (with the exception of the second which is rather specialised) are
demonstrated in complete examples below. The full and contiguous source is
available [on GitHub](@github@/akka-docs/rst/scala/code/docs/io/EchoServer.scala).
available @extref[on GitHub](github:akka-docs/rst/scala/code/docs/io/EchoServer.scala).
For back-pressuring reads there are two modes of operation

View file

@ -21,7 +21,7 @@ You can specify JVM options for the forked JVMs:
jvmOptions in MultiJvm := Seq("-Xmx256M")
```
Here is an example of a [sample project](@samples@/tree/master/akka-sample-multi-node-scala) that uses the `sbt-multi-jvm` plugin.
Here is an example of a @extref[sample project](samples:tree/master/akka-sample-multi-node-scala) that uses the `sbt-multi-jvm` plugin.
## Running tests

View file

@ -152,11 +152,14 @@ complete the test names.
The multi node testing kit is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-multi-node-testkit" % "@version@" @crossString@```
"com.typesafe.akka" %% "akka-multi-node-testkit" % $akka.version$
```
@@@
If you are using the latest nightly build you should pick a timestamped Akka version from
[http://repo.akka.io/snapshots/com/typesafe/akka/akka-multi-node-testkit_@binVersion@/](http://repo.akka.io/snapshots/com/typesafe/akka/akka-multi-node-testkit_@binVersion@/).
[http://repo.akka.io/snapshots/com/typesafe/akka/akka-multi-node-testkit_2.11/](http://repo.akka.io/snapshots/com/typesafe/akka/akka-multi-node-testkit_2.11/).
We recommend against using `SNAPSHOT` in order to obtain stable builds.
## A Multi Node Testing Example
@ -177,8 +180,8 @@ message send/receive.
@@snip [MultiNodeSample.scala]($akka$/akka-remote-tests/src/multi-jvm/scala/akka/remote/sample/MultiNodeSample.scala) { #package #spec }
The easiest way to run this example yourself is to download the ready to run
[Akka Multi-Node Testing Sample with Scala](@exampleCodeService@/akka-samples-multi-node-scala)
together with the tutorial. The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-multi-node-scala).
@extref[Akka Multi-Node Testing Sample with Scala](ecs:akka-samples-multi-node-scala)
together with the tutorial. The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-multi-node-scala).
## Things to Keep in Mind

View file

@ -8,9 +8,11 @@ Note that implementations for other journals may have different semantics.
Akka persistence LevelDB query implementation is bundled in the `akka-persistence-query` artifact.
Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-persistence-query" % "@version@" @crossString@
"com.typesafe.akka" %% "akka-persistence-query" % $akka.version$
```
@@@
## How to get the ReadJournal

View file

@ -14,9 +14,11 @@ recommend (in the spirit of CQRS) of splitting up the write/read sides into sepa
Akka persistence query is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-persistence-query" % "@version@" @crossString@
"com.typesafe.akka" %% "akka-persistence-query" % $akka.version$
```
@@@
## Design overview

View file

@ -17,9 +17,11 @@ concepts and architecture of [eventsourced](https://github.com/eligosource/event
Akka persistence is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-persistence" % "@version@" @crossString@
"com.typesafe.akka" %% "akka-persistence" % $akka.version$
```
@@@
The Akka persistence extension comes with few built-in persistence plugins, including
in-memory heap based journal, local file-system based snapshot-store and LevelDB based journal.
@ -94,9 +96,9 @@ stored, e.g. due to serialization error, `onPersistRejected` will be invoked (lo
by default) and the actor continues with the next message.
The easiest way to run this example yourself is to download the ready to run
[Akka Persistence Sample with Scala](@exampleCodeService@/akka-samples-persistence-scala)
@extref[Akka Persistence Sample with Scala](ecs:akka-samples-persistence-scala)
together with the tutorial. It contains instructions on how to run the `PersistentActorExample`.
The source code of this sample can be found in the [Akka Samples Repository](@samples@/akka-sample-persistence-scala).
The source code of this sample can be found in the @extref[Akka Samples Repository](samples:akka-sample-persistence-scala).
@@@ note
@ -903,7 +905,7 @@ In order to help developers build correct and high quality storage plugins, we p
The TCK is usable from Java as well as Scala projects. For Scala you need to include the akka-persistence-tck dependency:
```
"com.typesafe.akka" %% "akka-persistence-tck" % "@version@" % "test"
"com.typesafe.akka" %% "akka-persistence-tck" % "$akka.version$" % "test"
```
To include the Journal TCK tests in your test suite simply extend the provided `JournalSpec`:

View file

@ -28,4 +28,4 @@ It can be [signed online](http://www.lightbend.com/contribute/cla).
## Licenses for Dependency Libraries
Each dependency and its license can be seen in the project build file (the comment on the side of each dependency):
[AkkaBuild.scala](@github@/project/AkkaBuild.scala#L1054)
@extref[AkkaBuild.scala](github:project/AkkaBuild.scala#L1054)

View file

@ -37,7 +37,7 @@ Nightly builds are available in [http://repo.akka.io/snapshots](http://repo.akka
timestamped versions.
For timestamped versions, pick a timestamp from
[http://repo.akka.io/snapshots/com/typesafe/akka/akka-actor_@binVersion@](http://repo.akka.io/snapshots/com/typesafe/akka/akka-actor_@binVersion@)/.
[http://repo.akka.io/snapshots/com/typesafe/akka](http://repo.akka.io/snapshots/com/typesafe/akka).
All Akka modules that belong to the same build have the same timestamp.
@@@ warning
@ -56,10 +56,11 @@ resolvers += "Akka Snapshots" at "http://repo.akka.io/snapshots/"
Define the library dependencies with the timestamp as version. For example:
@@@vars
```
libraryDependencies += "com.typesafe.akka" % "akka-remote_@binVersion@" %
"2.5-20170510-230859"
libraryDependencies += "com.typesafe.akka" % "akka-remote_$scala.binary_version$" % "2.5-20170510-230859"
```
@@@
### maven definition of snapshot repository
@ -78,12 +79,14 @@ Make sure that you add the repository to the maven repositories in pom.xml:
Define the library dependencies with the timestamp as version. For example:
@@@vars
```
<dependencies>
<dependency>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_@binVersion@</artifactId>
<artifactId>akka-remote_$scala.binary_version$</artifactId>
<version>2.5-20170510-230859</version>
</dependency>
</dependencies>
```
@@@

View file

@ -45,9 +45,11 @@ are also different.
The Akka remoting is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-remote" % "@version@" @crossString@
"com.typesafe.akka" %% "akka-remote" % $akka.version$
```
@@@
To enable remote capabilities in your Akka project you should, at a minimum, add the following changes
to your `application.conf` file:
@ -567,9 +569,9 @@ That is not done by the router.
<a id="remote-sample-scala-artery"></a>
## Remoting Sample
You can download a ready to run [remoting sample](@exampleCodeService@/akka-samples-remote-scala)
You can download a ready to run @extref[remoting sample](ecs:akka-samples-remote-scala)
together with a tutorial for a more hands-on experience. The source code of this sample can be found in the
[Akka Samples Repository](@samples@/akka-sample-remote-scala).
@extref[Akka Samples Repository](samples:akka-sample-remote-scala).
## Performance tuning
@ -715,7 +717,7 @@ the system might have less latency than at low message rates.
@@@ note
In this version (@version@) the flight-recorder is disabled by default because there is no automatic
In this version ($akka.version$) the flight-recorder is disabled by default because there is no automatic
file name and path calculation implemented to make it possible to reuse the same file for every restart of
the same actor system without clashing with files produced by other systems (possibly running on the same machine).
Currently, you have to set the path and file names yourself to avoid creating an unbounded number

View file

@ -17,9 +17,11 @@ network and/or Akka configuration will have to be changed as described in
The Akka remoting is a separate jar file. Make sure that you have the following dependency in your project:
@@@vars
```
"com.typesafe.akka" %% "akka-remote" % "@version@" @crossString@
"com.typesafe.akka" %% "akka-remote" % $akka.version$
```
@@@
To enable remote capabilities in your Akka project you should, at a minimum, add the following changes
to your `application.conf` file:
@ -396,9 +398,9 @@ That is not done by the router.
<a id="remote-sample"></a>
## Remoting Sample
You can download a ready to run [remoting sample](@exampleCodeService@/akka-samples-remote-scala)
You can download a ready to run @extref[remoting sample](ecs:akka-samples-remote-scala)
together with a tutorial for a more hands-on experience. The source code of this sample can be found in the
[Akka Samples Repository](@samples@/akka-sample-remote-scala).
@extref[Akka Samples Repository](samples:akka-sample-remote-scala).
### Remote Events

View file

@ -117,6 +117,7 @@ object Dependencies {
object Provided {
// TODO remove from "test" config
// If changed, update akka-docs/build.sbt as well
val sigarLoader = "io.kamon" % "sigar-loader" % "1.6.6-rev002" % "optional;provided;test" // ApacheV2
val levelDB = "org.iq80.leveldb" % "leveldb" % "0.7" % "optional;provided" // ApacheV2