In general, the preferred approach is denormalizing, but your description
suggests that you want to be able to query anything: actions, tasks, test
cases, etc. so I guess that the most natural approach would be to leverage
Lucene's support for index-time joins, see the documentation of the join
package
<https://lucene.apache.org/core/8_8_1/join/org/apache/lucene/search/join/package-summary.html>
.

On Thu, Jun 17, 2021 at 3:45 PM Amol Suryawanshi <
amol.suryawan...@qualitiasoft.com> wrote:

> Hi Team,
>
> We are using Lucene Java library in our organization to store JSON files
> data into to Lucene indexes.
>
> Our JSON file are structured in below format.
>
>
>   1.  Testcase has several Testcase steps
>   2.  Testcase has several Tasks
>   3.  Tasks has task step
>   4.  Task step has Actions and objects
>
> Testcase
> TCSteps
>                - Actions
>                - Objects
> TASK
>                 TaskSteps
>                                 - Actions
>                                 - Objects
>
>
> How should I store this tree like data where I can get any parent document
> or child document using Lucene query
>
> for eg: I want to get all the Testcases in which particular action is
> mapped.
>
> Thanks & Regards
> Amol A. Suryawanshi
>
> Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for
> Windows 10
>
>

-- 
Adrien

Reply via email to