[nats] Release v2.0.0

This is a major new release. Details can be found [here](https://github.com/nats-io/nats-server/releases/tag/v2.0.0)

Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
This commit is contained in:
Ivan Kozlovic 2019-06-05 09:11:14 -06:00
parent 31c038be35
commit a59f4a741d
1 changed files with 22 additions and 14 deletions

View File

@ -4,6 +4,10 @@
`nats` is a high performance server for the NATS Messaging System.
# Backward Compatibility
The routing protocol has been dramatically improved and adds support for accounts and multi-tenancy. The new protocol is not backward compatible with servers pre v2.0.0.
# Example usage
```bash
@ -30,10 +34,11 @@
# Check "docker run" for more information.
$ docker run -d --name nats-main -p 4222:4222 -p 6222:6222 -p 8222:8222 %%IMAGE%%
[INF] Starting nats-server version 1.4.1
[INF] Git commit [ce2df36]
[INF] Starting nats-server version 2.0.0
[INF] Git commit [e12e56a]
[INF] Starting http monitor on 0.0.0.0:8222
[INF] Listening for client connections on 0.0.0.0:4222
[INF] Server id is NDMKAAJBQA7OIWCOSJFE5A54LBGN7PRGDFXA6YWTFLY7BB3EJE26PYS6
[INF] Server is ready
[INF] Listening for route connections on 0.0.0.0:6222
@ -43,23 +48,25 @@ $ docker run -d --name nats-main -p 4222:4222 -p 6222:6222 -p 8222:8222 %%IMAGE%
# Note that since you are passing arguments, this overrides the CMD section
# of the Dockerfile, so you need to pass all arguments, including the
# config file.
$ docker run -d --name=nats-2 --link nats-main -p 4222:4222 -p 6222:6222 -p 8222:8222 %%IMAGE%% -c gnatsd.conf --routes=nats-route://ruser:T0pS3cr3t@nats-main:6222
$ docker run -d --name=nats-2 --link nats-main -p 4222:4222 -p 6222:6222 -p 8222:8222 %%IMAGE%% -c nats-server.conf --routes=nats-route://ruser:T0pS3cr3t@nats-main:6222
# If you want to verify the routes are connected, try this instead:
$ docker run -d --name=nats-2 --link nats-main -p 4222:4222 -p 6222:6222 -p 8222:8222 %%IMAGE%% -c gnatsd.conf --routes=nats-route://ruser:T0pS3cr3t@nats-main:6222 -DV
[INF] Starting nats-server version 1.4.1
[DBG] Go build version go1.11.4
[INF] Git commit [ce2df36]
$ docker run -d --name=nats-2 --link nats-main -p 4222:4222 -p 6222:6222 -p 8222:8222 %%IMAGE%% -c nats-server.conf --routes=nats-route://ruser:T0pS3cr3t@nats-main:6222 -DV
[INF] Starting nats-server version 2.0.0
[DBG] Go build version go1.11.10
[INF] Git commit [e12e56a]
[INF] Starting http monitor on 0.0.0.0:8222
[INF] Listening for client connections on 0.0.0.0:4222
[DBG] Server id is n82AYgh7RMsbfAsitmpXzk
[INF] Server id is NCYDIN2GGETVBJXVX6LOE254WJTJRHH4ORNTG4KCIVPI662YQR77KUH4
[INF] Server is ready
[DBG] Get non local IPs for "0.0.0.0"
[DBG] ip=172.17.0.3
[INF] Listening for route connections on 0.0.0.0:6222
[DBG] Trying to connect to route on nats-main:6222
[DBG] 172.17.0.2:6222 - rid:1 - Route connection created
[DBG] 172.17.0.2:6222 - rid:1 - Route connect msg sent
[DBG] 172.17.0.2:6222 - rid:1 - Registering remote route "cC1EkYhtbDovu0HYthjzHV"
[DBG] 172.17.0.2:6222 - rid:1 - Route sent local subscriptions
[INF] 172.17.0.2:6222 - rid:1 - Route connection created
[DBG] 172.17.0.2:6222 - rid:1 - Registering remote route "NAKXX5DI3LXIVEJI7HQJMIRU522YUM3I4RYMN4HYRM5EYUR2PQYKSHZZ"
[DBG] 172.17.0.2:6222 - rid:1 - Sent local subscriptions to route
```
The server will load the configuration file below. Any command line flags can override these values.
@ -89,7 +96,7 @@ cluster {
# Routes are actively solicited and connected to from this server.
# This Docker image has none by default, but you can pass a
# flag to the gnatsd docker image to create one to an existing server.
# flag to the nats-server docker image to create one to an existing server.
routes = []
}
```
@ -104,9 +111,10 @@ Server Options:
-m, --http_port <port> Use port for http monitoring
-ms,--https_port <port> Use port for https monitoring
-c, --config <file> Configuration file
-sl,--signal <signal>[=<pid>] Send signal to gnatsd process (stop, quit, reopen, reload)
<pid> can be either a PID (e.g. 1) or the path to a PID file (e.g. /var/run/gnatsd.pid)
-sl,--signal <signal>[=<pid>] Send signal to nats-server process (stop, quit, reopen, reload)
<pid> can be either a PID (e.g. 1) or the path to a PID file (e.g. /var/run/nats-server.pid)
--client_advertise <string> Client URL to advertise to other servers
-t Test configuration and exit
Logging Options:
-l, --log <file> File to redirect log output