TransportClient createInjector error while using inmemory es cluster

I have a unit test where i am creating an inmemory es cluster using node builder and having issues while accessing through es transport client. There are no issues while accessing through node client. Any one any ideas on accessing the inmemory es cluster created through node builder using transport client ?

It was throwing createInjector exception while using transport client and i am using es 1.3 and my constraint is i should not upgrade es ? please share any thoughts.

what errors are you seeing and what address are you using to connect to it. do you have sample code somewhere?

Hi Simon , thank you for getting on this ..Here is a sample gist you can use

And the exception is : None of the configured nodes available for the second test. In the test suite , First test always runs ok and the second test when it starts the first test shuts down the es cluster and for the second test it triggers the new in memory es again ..and during the phase of second es restart's having the issue that it can not start properly to serve the requests for second test ..that means for the first test ..its not shutting down the complete es cluster correctly. Please post your thoughts on shutting the transport client , node etc such that second start happens smoothly.

I just had a quick look and I think the problem is that you are hard-binding the transport client to connect to port 9300 which might not be available yet once the first test is done since you are still shutting down so your second test will try to use 9301 etc.

that said, I wonder why you don't use our testing framework and just subclass ESIntegTestCase it does everything for you

How can i do to completely shutdown the old one and available with port 9300 for second also ..any thoughts ?

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