Hi guys,

We are integrating ElasticSearch into our Akka framework. We are using 
Akka's Extensions (in case someone here is familiar with Akka) to create 
the client like below

public Client getClient() {
       return new TransportClient().addTransportAddress(new 
InetSocketTransportAddress("localhost", 9300));
}

Now in my unit test, I want to test the method getClient()...

Here are my thoughts to achieve this..

1. Start up an elastic search test server in my unit test class with a 
different cluster name and different port
2. Pass these modified configuration parameters to getClient()
3. Test whether the client is created or not..

I am stuck on step 1 itself..I am looking at documentation and various 
examples online...Most of them show the ability to create a test Node using 
NodeBuilder and getting the client in the test itself or creating a 
TransportClient in the test itself..But I need the ability to start the 
test elastic server in my unit test and then make my app code to use that 
server to get the client..

Any thoughts on how I can achieve this?

Thanks,
SD 

-- 
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/ff2f5a29-59ff-4668-ade2-fbe1091fc926%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to