Re: DIH: Create Child Documents in ScriptTransformer

2019-09-19 Thread Jörn Franke
Hi, thanks for all the feedback. The context parameter in the ScriptTransformer is new to me - thanks for this insight. I could not find it in any docs. So just for people that also did not know it: you can have the ScriptTransformer with 2 parameters, e.g. function mytransformer(row,context){ ...

Re: DIH: Create Child Documents in ScriptTransformer

2019-09-18 Thread Mikhail Khludnev
Hello, Jörn. Have you tried to find a parent doc in the context which is passed as a second argument into ScriptTransformer? On Wed, Sep 18, 2019 at 9:56 PM Jörn Franke wrote: > > Hi, > > I load a set of documents. Based on these documents some logic needs to be > applied to split them into chapt

Re: DIH: Create Child Documents in ScriptTransformer

2019-09-18 Thread Jörn Franke
I fully agree. However, I am just curious to see the limits. > Am 18.09.2019 um 23:33 schrieb Erick Erickson : > > When it starts getting complex, I usually move to SolrJ. You say > you're loading documents, so I assume Tika is in the mix too. > > Here's a blog on the topic so you an see how to

Re: DIH: Create Child Documents in ScriptTransformer

2019-09-18 Thread Erick Erickson
When it starts getting complex, I usually move to SolrJ. You say you're loading documents, so I assume Tika is in the mix too. Here's a blog on the topic so you an see how to get started... https://lucidworks.com/post/indexing-with-solrj/ Best, Erick On Wed, Sep 18, 2019 at 2:56 PM Jörn Franke

DIH: Create Child Documents in ScriptTransformer

2019-09-18 Thread Jörn Franke
Hi, I load a set of documents. Based on these documents some logic needs to be applied to split them into chapters (this is done). One whole document is loaded as a parent. Chapters of the whole document + metadata should be loaded as child documents of this parent. I want to now collect informati