how to apply localization and Internationalization approach using spring framework with elasticsearch backend?

87 views Asked by At

I am using Spring framework with elasticsearch as the backend to store results such as item description, price, expert notes, etc. It is working perfectly for the English domain. I need to add additional language support for this. I have added the properties file for button labels and all the HTML markup except for the data in elasticsearch. I have the corresponding translation for the elasticsearch data. My question is how can I use this translated data? So far I have come up with the following options:

  1. Create separate elasticsearch index for the translated data and query the required field from this index for showing the translated text.
  2. Store the translated data in database and query that data at runtime for translation.
  3. Store the translated data in properties file and read these properties for translation.

Has anyone done this before? Are there any other options I didn't mention? What approach did you take?

0

There are 0 answers