Document that online reindexing is currently not supported

In the current implementation online reindexing is not yet supported.
This was not clearly documented.

This change sets the corresponding configuration in Gerrit and adds the
missing documentation.

Note: Support of online-reindexing is planned for the future.

Change-Id: Ia5a5f5dab6ed61d7695c2ca59c61d7ffb0b13a48
diff --git a/container-images/gerrit-init/tools/gerrit_reindex.py b/container-images/gerrit-init/tools/gerrit_reindex.py
index a201ca6..8f3e6b0 100755
--- a/container-images/gerrit-init/tools/gerrit_reindex.py
+++ b/container-images/gerrit-init/tools/gerrit_reindex.py
@@ -46,6 +46,8 @@
             options = config.list()
             for opt in options:
                 name, version = opt["subsection"].rsplit("_", 1)
+                # TODO (Thomas): Properly handle multiple versions of the same index,
+                # which may be present due to online-reindexing in progress.
                 indices[name] = {
                     "version": int(version),
                     "ready": opt["value"].lower() == "true",
diff --git a/helm-charts/gerrit/README.md b/helm-charts/gerrit/README.md
index 0cb0264..8220917 100644
--- a/helm-charts/gerrit/README.md
+++ b/helm-charts/gerrit/README.md
@@ -212,6 +212,13 @@
 
     The canonical web URL has to be set to the Ingress host.
 
+- `index.onlineUpgrade`
+
+    Online reindexing is currently **NOT** supported. An offline reindexing will
+    be enforced upon Gerrit updates. Online reindexing might under some circum-
+    stances interfere with the Gerrit pod startup procedure and thus has to be
+    deactivated.
+
 - `httpd.listenURL`
 
     This has to be set to `proxy-http://*:8080/` or `proxy-https://*:8080`,
diff --git a/helm-charts/gerrit/templates/gerrit.stateful-set.yaml b/helm-charts/gerrit/templates/gerrit.stateful-set.yaml
index 35ebe63..bdef9c3 100644
--- a/helm-charts/gerrit/templates/gerrit.stateful-set.yaml
+++ b/helm-charts/gerrit/templates/gerrit.stateful-set.yaml
@@ -81,6 +81,8 @@
             FLAGS="$FLAGS --force"
           {{- end }}
 
+          # TODO (Thomas): Do not enforce offline-reindexing, when online-reindexing
+          # is configured.
           /var/tools/gerrit_reindex.py $FLAGS \
             -s /var/gerrit
         volumeMounts:
diff --git a/helm-charts/gerrit/values.yaml b/helm-charts/gerrit/values.yaml
index f033fbf..c9add68 100644
--- a/helm-charts/gerrit/values.yaml
+++ b/helm-charts/gerrit/values.yaml
@@ -169,6 +169,7 @@
           disableReverseDnsLookup = true
         [index]
           type = LUCENE
+          onlineUpgrade = false # FIXED
         [auth]
           type = DEVELOPMENT_BECOME_ANY_ACCOUNT
         [httpd]