From e7de3ee662184dfbb05168c3e599f8ab3e071336 Mon Sep 17 00:00:00 2001 From: WalkerWatch Date: Thu, 9 Mar 2017 11:26:59 -0500 Subject: [PATCH] Resolves #856 and updates exisitng doco. Signed-off-by: WalkerWatch --- .../session-configuration-file-system.adoc | 10 ++--- .../session-configuration-infinispan.adoc | 14 ++++--- .../sessions/session-configuration-jdbc.adoc | 9 ++-- .../session-configuration-mongodb.adoc | 41 ++++++++++++++----- 4 files changed, 49 insertions(+), 25 deletions(-) diff --git a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-file-system.adoc b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-file-system.adoc index 3cfd2c9faf0..f23ef4d68ab 100644 --- a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-file-system.adoc +++ b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-file-system.adoc @@ -26,11 +26,11 @@ $ java -jar ../start.jar --create-startd INFO : Base directory was modified $ java -jar ../start.jar --add-to-start=session-store-file -INFO : server initialised (transitively) in ${jetty.base}/start.d/server.ini -INFO : sessions initialised (transitively) in ${jetty.base}/start.d/sessions.ini -INFO : session-store-file initialised in ${jetty.base}/start.d/session-store-file.ini -MKDIR: ${jetty.base}/sessions -INFO : Base directory was modified +INFO : server transitively enabled, ini template available with --add-to-start=server +INFO : sessions transitively enabled, ini template available with --add-to-start=sessions +INFO : session-store-file initialized in ${jetty.base}/start.d/session-store-file.ini +MKDIR : ${jetty.base}/sessions +INFO : Base directory was modified ---- //TODO - Callout default Session file location - note it is configurable diff --git a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-infinispan.adoc b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-infinispan.adoc index 98c833b7e96..eebd9937726 100644 --- a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-infinispan.adoc +++ b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-infinispan.adoc @@ -39,12 +39,14 @@ The following 1 module(s): + http://www.apache.org/licenses/LICENSE-2.0.html Proceed (y/N)? y -INFO : server initialised (transitively) in ${jetty.base}/start.d/server.ini -INFO : sessions initialised (transitively) in ${jetty.base}/start.d/sessions.ini -INFO : session-store-infinispan-remote initialised in ${jetty.base}/start.d/session-store-infinispan-remote.ini -DOWNLOAD: https://raw.githubusercontent.com/eclipse/jetty.project/master/jetty-infinispan/src/main/infinispan-resources/hotrod-client.properties?id=master to ${jetty.base}/resources/hotrod-client.properties -DOWNLOAD: http://central.maven.org/maven2/org/infinispan/infinispan-remote/7.1.1.Final/infinispan-remote-7.1.1.Final.jar to ${jetty.base}/lib/infinispan/infinispan-remote-7.1.1.Final.jar -INFO : Base directory was modified +INFO : server transitively enabled, ini template available with --add-to-start=server +INFO : sessions transitively enabled, ini template available with --add-to-start=sessions +INFO : session-store-infinispan-remote initialized in ${jetty.base}/start.d/session-store-infinispan-remote.ini +MKDIR : ${jetty.base}/lib/infinispan +DOWNLD: http://central.maven.org/maven2/org/infinispan/infinispan-remote/7.1.1.Final/infinispan-remote-7.1.1.Final.jar to ${jetty.base}/lib/infinispan/infinispan-remote-7.1.1.Final.jar +MKDIR : ${jetty.base}/resources +COPY : ${jetty.home}/modules/session-store-infinispan-remote/resources/hotrod-client.properties to ${jetty.base}/resources/hotrod-client.properties +INFO : Base directory was modified ---- Doing this enables the remote Infinispan Session module and any dependent modules or files needed for it to run on the server. diff --git a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-jdbc.adoc b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-jdbc.adoc index 2e705c83054..101618e0b96 100644 --- a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-jdbc.adoc +++ b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-jdbc.adoc @@ -26,10 +26,11 @@ $ java -jar ../start.jar --create-startd INFO : Base directory was modified $ java -jar ../start.jar --add-to-start=session-store-jdbc -INFO : server initialised (transitively) in ${jetty.base}/start.d/server.ini -INFO : sessions initialised (transitively) in ${jetty.base}/start.d/sessions.ini -INFO : session-store-jdbc initialised in ${jetty.base}/start.d/session-store-jdbc.ini -INFO : Base directory was modified +INFO : server transitively enabled, ini template available with --add-to-start=server +INFO : sessions transitively enabled, ini template available with --add-to-start=sessions +INFO : sessions/jdbc/datasource dynamic dependency of session-store-jdbc +INFO : session-store-jdbc initialized in ${jetty.base}/start.d/session-store-jdbc.ini +INFO : Base directory was modified ---- Doing this enables the JDBC Session module and any dependent modules or files needed for it to run on the server. diff --git a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-mongodb.adoc b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-mongodb.adoc index 362e073117d..3e605f945b5 100644 --- a/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-mongodb.adoc +++ b/jetty-documentation/src/main/asciidoc/administration/sessions/session-configuration-mongodb.adoc @@ -39,11 +39,13 @@ The following 1 module(s): + http://www.apache.org/licenses/LICENSE-2.0.html Proceed (y/N)? y -INFO : server initialised (transitively) in ${jetty.base}/start.d/server.ini -INFO : sessions initialised (transitively) in ${jetty.base}/start.d/sessions.ini -INFO : session-store-mongo initialised in ${jetty.base}/start.d/session-store-mongo.ini -DOWNLOAD: http://central.maven.org/maven2/org/mongodb/mongo-java-driver/2.6.1/mongo-java-driver-2.6.1.jar to ${jetty.base}/lib/nosql/mongo-java-driver-2.6.1.jar -INFO : Base directory was modified +INFO : server transitively enabled, ini template available with --add-to-start=server +INFO : sessions transitively enabled, ini template available with --add-to-start=sessions +INFO : session-store-mongo initialized in ${jetty.base}/start.d/session-store-mongo.ini +INFO : sessions/mongo/address dynamic dependency of session-store-mongo +MKDIR : ${jetty.base}/lib/nosql +DOWNLD: http://central.maven.org/maven2/org/mongodb/mongo-java-driver/2.13.2/mongo-java-driver-2.13.2.jar to ${jetty.base}/lib/nosql/mongo-java-driver-2.13.2.jar +INFO : Base directory was modified ---- Doing this enables the MongoDB Session module and any dependent modules or files needed for it to run on the server. @@ -70,18 +72,37 @@ Opening the `start.d/session-store-mongo.ini` will show a list of all the config #jetty.session.mongo.dbName=HttpSessions #jetty.session.mongo.collectionName=jettySessions +#jetty.session.gracePeriod.seconds=3600 + +connection-type=address #jetty.session.mongo.host=localhost #jetty.session.mongo.port=27017 -#jetty.session.gracePeriod.seconds=3600 + +#connection-type=uri +#jetty.session.mongo.connectionString=mongodb://localhost ---- jetty.session.mongo.dbName:: Name of the database in Mongo used to store the Session collection. jetty.session.mongo.collectionName:: Name of the collection in Mongo used to keep all of the Sessions. -jetty.session.mongo.host:: -Host name or address for the remote Mongo instance. -jetty.session.mongo.port:: -Port number for the remote Mongo instance. jetty.session.gracePeriod.seconds:: Amount of time, in seconds, to wait for other nodes to be checked to verify an expired session is in fact expired throughout the cluster before closing it. +connection-type=address:: +Used when utilizing a direct connection to the Mongo server. +jetty.session.mongo.host;; +Host name or address for the remote Mongo instance. +jetty.session.mongo.port;; +Port number for the remote Mongo instance. +connection-type=uri:: +Used when utilizing MongoURI for secured connections. +jetty.session.mongo.connectionString;; +The string defining the MongoURI value, such as `mongodb://[username:password@]host1[:port1][,host2[:port2],...[,hostN[:portN]]][/[database][?options]]`. +More information on how to format the MongoURI string can be found in the https://docs.mongodb.com/manual/reference/connection-string/[official documentation for mongo.] ++ +____ +[NOTE] +You will only use *one* `connection-type` at a time, `address` or `uri`. +If both are utilized in your `session-store-mongo.ini`, only the last `connection-type` configured in the file will be used. +By default, the `connection-type` of `address` is used. +____