You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by dk...@apache.org on 2020/10/21 03:44:03 UTC

[sling-org-apache-sling-app-cms] 01/03: Aligning indexes

This is an automated email from the ASF dual-hosted git repository.

dklco pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-app-cms.git

commit d86558c7980a27cbcd0956b093a0a5e0daf9a248
Author: Dan Klco <dk...@apache.org>
AuthorDate: Tue Oct 20 23:42:08 2020 -0400

    Aligning indexes
---
 .../jcr_root/oak%3Aindex/ntBaseLucene.json         | 76 +++++++++++-----------
 .../jcr_root/oak%3Aindex/slingFileLucene.json      | 23 +++++--
 .../jcr_root/oak%3Aindex/slingPageLucene.json      |  8 ++-
 .../jcr_root/oak%3Aindex/slingTaxonomy.json        |  8 ++-
 4 files changed, 68 insertions(+), 47 deletions(-)

diff --git a/ui/src/main/resources/jcr_root/oak%3Aindex/ntBaseLucene.json b/ui/src/main/resources/jcr_root/oak%3Aindex/ntBaseLucene.json
index 12fbf2f..2a8ba54 100644
--- a/ui/src/main/resources/jcr_root/oak%3Aindex/ntBaseLucene.json
+++ b/ui/src/main/resources/jcr_root/oak%3Aindex/ntBaseLucene.json
@@ -1,40 +1,40 @@
 {
-	"jcr:primaryType": "oak:QueryIndexDefinition",
-	"compatVersion": 2,
-	"indexPath": "/oak:index/ntBaseLucene",
-	"name": "ntBaseLucene",
-	"type": "lucene",
-	"async": [
-		"async",
-		"nrt"
-	],
-	"evaluatePathRestrictions": false,
-	"excludedPaths": [
-		"/jcr:system"
-	],
-	"reindex": false,
-	"reindexCount": 1,
-	"indexRules": {
-		"jcr:primaryType": "nt:unstructured",
-		"nt:base": {
-			"jcr:primaryType": "nt:unstructured",
-			"properties": {
-				"jcr:primaryType": "nt:unstructured",
-				"slingTaxonomy": {
-					"jcr:primaryType": "nt:unstructured",
-					"ordered": false,
-					"propertyIndex": true,
-					"name": "sling:taxonomy",
-					"type": "String"
-				},
-				"slingResource": {
-					"jcr:primaryType": "nt:unstructured",
-					"ordered": false,
-					"propertyIndex": true,
-					"name": "sling:resource",
-					"type": "String"
-				}
-			}
-		}
-	}
+    "jcr:primaryType": "oak:QueryIndexDefinition",
+    "compatVersion": 2,
+    "indexPath": "/oak:index/ntBaseLucene",
+    "name": "ntBaseLucene",
+    "type": "lucene",
+    "async": [
+        "async",
+        "nrt"
+    ],
+    "evaluatePathRestrictions": false,
+    "excludedPaths": [
+        "/jcr:system"
+    ],
+    "reindex": false,
+    "reindexCount": 1,
+    "indexRules": {
+        "jcr:primaryType": "nt:unstructured",
+        "nt:base": {
+            "jcr:primaryType": "nt:unstructured",
+            "properties": {
+                "jcr:primaryType": "nt:unstructured",
+                "slingTaxonomy": {
+                    "jcr:primaryType": "nt:unstructured",
+                    "ordered": false,
+                    "propertyIndex": true,
+                    "name": "sling:taxonomy",
+                    "type": "String"
+                },
+                "slingResource": {
+                    "jcr:primaryType": "nt:unstructured",
+                    "ordered": false,
+                    "propertyIndex": true,
+                    "name": "sling:resource",
+                    "type": "String"
+                }
+            }
+        }
+    }
 }
\ No newline at end of file
diff --git a/ui/src/main/resources/jcr_root/oak%3Aindex/slingFileLucene.json b/ui/src/main/resources/jcr_root/oak%3Aindex/slingFileLucene.json
index d88b6aa..92861df 100644
--- a/ui/src/main/resources/jcr_root/oak%3Aindex/slingFileLucene.json
+++ b/ui/src/main/resources/jcr_root/oak%3Aindex/slingFileLucene.json
@@ -1,18 +1,21 @@
 {
     "jcr:primaryType": "oak:QueryIndexDefinition",
     "compatVersion": 2,
+    "indexPath": "/oak:index/slingFileLucene",
+    "name": "slingFileLucene",
     "type": "lucene",
-    "async": "async",
+    "async": [
+        "async",
+        "nrt"
+    ],
     "evaluatePathRestrictions": true,
-    "reindex": false,
-    "reindexCount": 1,
     "excludedPaths": [
         "/var",
         "/jcr:system"
     ],
     "aggregates": {
         "jcr:primaryType": "nt:unstructured",
-        "sling:Asset": {
+        "sling:File": {
             "jcr:primaryType": "nt:unstructured",
             "include0": {
                 "jcr:primaryType": "nt:unstructured",
@@ -36,6 +39,7 @@
                     "useInSuggest": true,
                     "propertyIndex": true,
                     "useInSpellcheck": true,
+                    "analyzed": true,
                     "name": "jcr:content/sling:taxonomy"
                 },
                 "jcrTitle": {
@@ -44,6 +48,7 @@
                     "useInSuggest": true,
                     "propertyIndex": true,
                     "useInSpellcheck": true,
+                    "analyzed": true,
                     "name": "jcr:content/jcr:title",
                     "boost": 2
                 },
@@ -53,7 +58,17 @@
                     "useInSuggest": true,
                     "propertyIndex": true,
                     "useInSpellcheck": true,
+                    "analyzed": true,
                     "name": "jcr:content/jcr:description"
+                },
+                "nodeName": {
+                    "jcr:primaryType": "nt:unstructured",
+                    "nodeScopeIndex": true,
+                    "useInSuggest": true,
+                    "propertyIndex": true,
+                    "useInSpellcheck": true,
+                    "name": ":nodeName",
+                    "type": "String"
                 }
             }
         }
diff --git a/ui/src/main/resources/jcr_root/oak%3Aindex/slingPageLucene.json b/ui/src/main/resources/jcr_root/oak%3Aindex/slingPageLucene.json
index 4162f6b..3f5f4d2 100644
--- a/ui/src/main/resources/jcr_root/oak%3Aindex/slingPageLucene.json
+++ b/ui/src/main/resources/jcr_root/oak%3Aindex/slingPageLucene.json
@@ -1,17 +1,18 @@
 {
     "jcr:primaryType": "oak:QueryIndexDefinition",
     "compatVersion": 2,
+    "indexPath": "/oak:index/slingPageLucene",
+    "name": "slingPageLucene",
     "type": "lucene",
     "async": [
-        "async"
+        "async",
+        "nrt"
     ],
     "evaluatePathRestrictions": true,
     "excludedPaths": [
         "/var",
         "/jcr:system"
     ],
-    "reindex": false,
-    "reindexCount": 1,
     "aggregates": {
         "jcr:primaryType": "nt:unstructured",
         "sling:Page": {
@@ -78,6 +79,7 @@
                     "useInSuggest": true,
                     "propertyIndex": true,
                     "useInSpellcheck": true,
+                    "analyzed": true,
                     "name": "jcr:content/jcr:title",
                     "type": "String"
                 }
diff --git a/ui/src/main/resources/jcr_root/oak%3Aindex/slingTaxonomy.json b/ui/src/main/resources/jcr_root/oak%3Aindex/slingTaxonomy.json
index b4ae506..fbae8a3 100644
--- a/ui/src/main/resources/jcr_root/oak%3Aindex/slingTaxonomy.json
+++ b/ui/src/main/resources/jcr_root/oak%3Aindex/slingTaxonomy.json
@@ -1,17 +1,18 @@
 {
     "jcr:primaryType": "oak:QueryIndexDefinition",
     "compatVersion": 2,
+    "indexPath": "/oak:index/slingTaxonomy",
+    "name": "slingTaxonomy",
     "type": "lucene",
     "async": [
         "async",
         "nrt"
     ],
+    "evaluatePathRestrictions": true,
     "excludedPaths": [
         "/var",
         "/jcr:system"
     ],
-    "reindex": false,
-    "reindexCount": 1,
     "indexRules": {
         "jcr:primaryType": "nt:unstructured",
         "sling:Taxonomy": {
@@ -20,7 +21,10 @@
                 "jcr:primaryType": "nt:unstructured",
                 "jcrTitle": {
                     "jcr:primaryType": "nt:unstructured",
+                    "nodeScopeIndex": true,
+                    "useInSuggest": true,
                     "propertyIndex": true,
+                    "useInSpellcheck": true,
                     "analyzed": true,
                     "name": "jcr:title",
                     "type": "String"