Document options monger.collection/ensure-index takes

This commit is contained in:
Michael S. Klishin 2012-06-29 10:57:17 +04:00
parent 723ac2503b
commit f14227dbc0

View file

@ -454,7 +454,12 @@
(defn ensure-index (defn ensure-index
"Creates an index on a set of fields, if one does not already exist. "Creates an index on a set of fields, if one does not already exist.
This operation is optimized in the Java driver and is inexpensive in the case when an index already exists. This operation is inexpensive in the case when an index already exists.
Options are:
:unique (boolean) to create a unique index
:name (string) to specify a custom index name and not rely on the generated one
EXAMPLES EXAMPLES