You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-commits@jackrabbit.apache.org by ch...@apache.org on 2014/05/19 14:02:54 UTC
svn commit: r1595855 - in /jackrabbit/oak/trunk/oak-doc/src/site/markdown:
documentmk.md osgi_config.md
Author: chetanm
Date: Mon May 19 12:02:54 2014
New Revision: 1595855
URL: http://svn.apache.org/r1595855
Log:
OAK-301 : oak docu
Details related to mongo uri config
Modified:
jackrabbit/oak/trunk/oak-doc/src/site/markdown/documentmk.md
jackrabbit/oak/trunk/oak-doc/src/site/markdown/osgi_config.md
Modified: jackrabbit/oak/trunk/oak-doc/src/site/markdown/documentmk.md
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-doc/src/site/markdown/documentmk.md?rev=1595855&r1=1595854&r2=1595855&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-doc/src/site/markdown/documentmk.md (original)
+++ jackrabbit/oak/trunk/oak-doc/src/site/markdown/documentmk.md Mon May 19 12:02:54 2014
@@ -414,6 +414,7 @@ or a random uuid if this is not availabl
The `info` contains the same info as a string, plus additionally the process id
and the uuid.
+<a name="rw-preference"></a>
### Specifying the Read Preference and Write Concern
With `MongoDocumentStore` you can specify the the [read preference][1] and [write concern][2].
Modified: jackrabbit/oak/trunk/oak-doc/src/site/markdown/osgi_config.md
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-doc/src/site/markdown/osgi_config.md?rev=1595855&r1=1595854&r2=1595855&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-doc/src/site/markdown/osgi_config.md (original)
+++ jackrabbit/oak/trunk/oak-doc/src/site/markdown/osgi_config.md Mon May 19 12:02:54 2014
@@ -80,7 +80,26 @@ Example config file
mongouri=mongodb://localhost:27017
db=oak
+
+##### Mongo Configuration
+All the configuration related to Mongo can be specified via [Mongo URI][1]
+
+* **Authentication** - Username and password should be specified as part of uri e.g. the following
+ connects and logs in to the admin database as user sysop with the password moon:
+
+ mongodb://sysop:moon@localhost
+
+* **Read Preferences and Write Concern** - These also can be spcified as part of Mongo URI. Refer to
+ [Read Preference and Write Concern](documentmk.html#rw-preference) section for more details. For
+ e.g. following would set _readPreference_ to _secondary_ and prefer replica with tag _dc:ny,rack:1_.
+ It would also specify the write timeout to 10 sec
+
+ mongodb://db1.example.net,db2.example.com?readPreference=secondary&readPreferenceTags=dc:ny,rack:1&readPreferenceTags=dc:ny&readPreferenceTags=&w=1&wtimeoutMS=10000
+
+One can also specify the connection pool size, socket timeout etc. For complete details about various
+possible option refer to [Mongo URI][1]
+
### Configuring DataStore/BlobStore
BlobStores are used to store the binary content. Support for Jackrabbit 2 `DataStore` is also provided via
a `DataStoreBlobStore` wrapper. To use a specific BlobStore implementation following two steps need to be