[
https://issues.apache.org/jira/browse/SOLR-12362?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16526338#comment-16526338
]
David Smiley commented on SOLR-12362:
-------------------------------------
[~janhoy] mentioned that it would be brittle if we differentiated a sub-json
structure as a child doc if we were to do it by looking for the special values
"add" or "set" (partial update commands) since child doc could conceivably want
fields named as-such.
See JsonLoader's {{parseExtendedFieldValue()}}. Today, line 597, it calls
isChildDoc to differentiate, where we check for uniqueKey field.
Proposal: look at the SolrInputField parameter to look at the field we're
adding this to (i.e. what key is this sub-json structure associated with?). Is
that a field in the schema? If it is, then we have an "extended field value
(partial update most likely). If it is not, then we have a child document.
This proposal of course requires that the field already exist, and in a "data
driven mode", that might not be the case. But in a "data driven mode", we
shouldn't see "extended field values" at all until at least there is some data
to partially update?
> JSON loader should save the relationship of children
> ----------------------------------------------------
>
> Key: SOLR-12362
> URL: https://issues.apache.org/jira/browse/SOLR-12362
> Project: Solr
> Issue Type: Sub-task
> Security Level: Public(Default Security Level. Issues are Public)
> Reporter: mosh
> Assignee: David Smiley
> Priority: Major
> Fix For: 7.5
>
> Time Spent: 6.5h
> Remaining Estimate: 0h
>
> Once _childDocuments in SolrInputDocument is changed to a Map, JsonLoader
> should add the child document to the map while saving its key name, to
> maintain the child's relationship to its parent.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]