zacharymorn commented on a change in pull request #25:
URL: https://github.com/apache/lucene/pull/25#discussion_r598397987
##########
File path: lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java
##########
@@ -372,7 +403,10 @@ private void processFacetFields(
// Drill down:
Review comment:
Updated to use the new `DrillDownTermsIndexing.NONE` option to denote
the all drill down disabled condition. Also refactored a bit more there to
support the `DrillDownTermsIndexing.DIMENSION_AND_FULL_PATH` option that was
previously commented out.
##########
File path: lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java
##########
@@ -65,6 +65,38 @@
// int/float/bytes in a single indexed field:
private final Map<String, String> assocDimTypes = new ConcurrentHashMap<>();
+ /**
+ * Drill down terms indexing option to control whether dimension and
sub-path terms should be
+ * indexed.
+ */
+ public enum DrillDownTermsIndexing {
+ /**
+ * Index only full-path drill down terms. No dimension nor sub-path
indexing. e.g. for
+ * FacetField("a", "foo/bar/baz"), we would only index value "a foo bar
baz".
Review comment:
Updated. I used `a foo bar baz` before as that's the format computed by
`pathToString(cp.components, i)` and fed into the value of `StringField`, but
yeah given that is actually internal drill down term indexing format, we should
probably not expose that in java doc and favor `a/foo/bar/baz` instead.
##########
File path: lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java
##########
@@ -65,6 +65,38 @@
// int/float/bytes in a single indexed field:
private final Map<String, String> assocDimTypes = new ConcurrentHashMap<>();
+ /**
+ * Drill down terms indexing option to control whether dimension and
sub-path terms should be
+ * indexed.
+ */
+ public enum DrillDownTermsIndexing {
+ /**
+ * Index only full-path drill down terms. No dimension nor sub-path
indexing. e.g. for
+ * FacetField("a", "foo/bar/baz"), we would only index value "a foo bar
baz".
+ */
+ FULL_PATH_ONLY,
+
+ /**
+ * Index sub-path and full-path down terms. No dimension indexing. e.g.
for FacetField("a",
Review comment:
Ops. Updated.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]