imply-cheddar commented on code in PR #13672:
URL: https://github.com/apache/druid/pull/13672#discussion_r1070843375
##########
core/src/main/java/org/apache/druid/java/util/common/parsers/JSONPathParser.java:
##########
@@ -42,7 +42,11 @@ public class JSONPathParser implements Parser<String, Object>
public JSONPathParser(JSONPathSpec flattenSpec, ObjectMapper mapper, boolean
keepNullColumns)
{
this.mapper = mapper == null ? new ObjectMapper() : mapper;
- this.flattener = ObjectFlatteners.create(flattenSpec, new
JSONFlattenerMaker(keepNullColumns));
+ this.flattener = ObjectFlatteners.create(
+ flattenSpec,
+ new JSONFlattenerMaker(keepNullColumns),
+ false
Review Comment:
I'm not certain I know why this is hard-coding to false. Is that covered in
a comment or javadoc or something?
##########
indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/SeekableStreamSamplerSpec.java:
##########
@@ -115,7 +115,7 @@ public SamplerResponse sample()
);
}
- return inputSourceSampler.sample(inputSource, inputFormat, dataSchema,
samplerConfig);
+ return inputSourceSampler.sample(inputSource, inputFormat, dataSchema,
samplerConfig, tuningConfig != null ? tuningConfig.convertToTaskTuningConfig()
: null);
Review Comment:
can you invert the `!=` here pls.
##########
integration-tests-ex/cases/cluster/Common/dependencies.yaml:
##########
@@ -67,7 +67,7 @@ services:
# See https://hub.docker.com/_/mysql
# The image will intialize the user and DB upon first start.
metadata:
- # platform: linux/x86_64 - Add when running on M1 Macs
+ platform: linux/x86_64 #- Add when running on M1 Macs
Review Comment:
Should this be checked in?
##########
core/src/main/java/org/apache/druid/java/util/common/parsers/ObjectFlatteners.java:
##########
@@ -218,9 +219,9 @@ public Map<String, Object> toMap(T obj)
{
JsonProvider getJsonProvider();
/**
- * List all "root" primitive properties and primitive lists (no nested
objects, no lists of objects)
+ * List all "root" fields, optionally filtering to include only fields
that contain primitive and lists of primitive values
*/
- Iterable<String> discoverRootFields(T obj);
+ Iterable<String> discoverRootFields(T obj, boolean discoverNestedFields);
Review Comment:
I don't think you need to change the interface at all? Can't you add the
config as a property on the actual FlattenerMaker objects themselves? Doing
that will definitely shrink this PR down and avoid interface changes?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]