Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[docs] Add the documentation of "janusnode".
Signed-off-by: Stéphane Galland <galland@arakhne.org>
- Loading branch information
1 parent
4aa6786
commit 97b4a9a
Showing
4 changed files
with
650 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
86 changes: 86 additions & 0 deletions
86
docs/io.sarl.docs.markdown/src/main/documentation/tools/Janusnode.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
# Janus Command-line Launcher with Network Support | ||
|
||
[:Outline:] | ||
|
||
[Janus](http://www.janusproject.io) is the default SARL Run-time Environment (SRE). | ||
Its role is to provide all the libraries and plugins that are needed for running SARL agents. | ||
|
||
The [`janus`](./Janus.md) tool is the base command-line tool for launching the SRE. | ||
But, it does not provide a support for exchaning events over a computer | ||
network. If you would like to have benefit of this feature, you should use one of the following | ||
methods: | ||
|
||
1. Add on the classpath of the `janus` command a library that includes the networking feature to the SRE; or | ||
2. Use the version of the SRE that already includes the standard network feature: `[:name](janusnode)`. | ||
|
||
The [:name:] is explained on this page. | ||
|
||
## Basics of the Networking Feature | ||
|
||
Basically, the networking feature of the SRE enables you to launch instances of the Janus kernel on different | ||
computers, and exchange events between these instances. | ||
|
||
In order to implement this feature, the [Hazelcast](http://www.hazelcast.com) library is used. | ||
Hazelcast is an open source in-memory data grid based on Java. In a Hazelcast grid, data is | ||
evenly distributed among the nodes of a computer cluster, allowing for horizontal scaling of | ||
processing and available storage. Backups are also distributed among nodes to protect against | ||
failure of any single node. | ||
|
||
In addition to the data-sharing and efficient communication means, Hazelcast provides the ability | ||
to build the node network automatically. Each Hazelcast node that is associated to a given cluster | ||
name is *connected automatically* to the other nodes in the same cluster on the local network. | ||
It means that you do not need to provide a network configuration to the [:name:] tool. | ||
|
||
## Usage | ||
|
||
The [:name:] tool takes arguments: | ||
|
||
```text | ||
[:name!] [OPTIONS] <[:agname](agent_fully_qualified_name)> | ||
``` | ||
|
||
|
||
The [:agname:] is the name of the agent to launch. This name is equal to the | ||
fully qualified name of the agent's type. | ||
|
||
> **_Note::_** Janus enables to launch only one agent from the command-line shell. If you want to launch | ||
> more than one agent, you should launch a first agent, which will create the other agents. | ||
You could change the behavior of the [:name:] tool with the command-line options. | ||
For obtaining a list of the options, type: | ||
|
||
```texts | ||
[:name!] -help | ||
``` | ||
|
||
|
||
## Command-Line Options | ||
|
||
The Janus framework provides options on the command-line. | ||
The list of the options is displayed below. This list includes | ||
all the standard modules of Janus, and the networking features. | ||
If you add an extra module into the classpath of your application, | ||
more options may become available. | ||
|
||
|
||
|
||
| Option | Description | | ||
| ------ | ----------- | | ||
[:Dynamic:]{ | ||
runShellSilently( | ||
makeExecName("..", "..", "..", "..", "..", "..", "sre", "io.janusproject", "io.janusproject.kernel.network", "target", "janusnode"), | ||
"generatemarkdownhelp".makeCliOption) | ||
|
||
} | ||
|
||
|
||
|
||
## List of Errors and Warnings | ||
|
||
The list of error and warning messages that may be generated by Janus are provided on the | ||
help page of the [main command-line tool](./Janus.md). | ||
|
||
|
||
|
||
[:Include:](../legal.inc) | ||
|
Oops, something went wrong.