New elasticsearch-java client needs to initialize in springboot?

Do we always need to initialize elasticsearch-java to use port 9200 or other custom ports and other setings?

Previous high level REST client(HLRC) does not need the initialization in springboot. You just declare it and you can use it right away.

Is this possible in the new es client

elasticsearch-java and HLRC use the exact same lower-level client (LLRC) where host names and ports must be configured. So there must be some Spring magic involved that fetches those settings somewhere.

Can you provide a code snippet showing your HLRC injection? What SpringBoot modules are you using?

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