Can elasticsearch handle data with many relations or do I need a relational database?

Dear All

I am building an application which has to show data from the legal industry (e.g. laws, verdicts etc). The data is characterized by having many relations/links. E.g., paragraphs x in law y refers to other paragraph z in law w etc.

My first idea was to combine a relational database (RD)(postresql) with elasticsearch. The RD is then supposed to be the primary data source and elasticsearch is used for text search. The RD data is denormalized and migrated to elasticsearch. From the Elastic search results I retrieve the lnked data from the RD and pass that to the frontend. The reason for this design is that I find it a bit cumbersome to handle the relations in elastic (parent/child).

My questions are (I am a newbie):

  1. Is my current design (combination of RD and elastic) a common/clever approach?
  2. If I was to do it in Elastic only would parent child be the way to go ?

Best regards

Jens

  1. It's a good idea.
  2. That's tough as you'd end up with a whole bunch of parent child, due to the referential nature of the data. But yes.

Dear Mark

Thank you for your reply. I guess then that my current options are 1) to handle the relations by myself (frontend) or, 2) leave to the RD

Best

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.