I have included all the jars. Elastic search as well as lucene. What else could be the issue? Or did i miss any of the jars?
On Sunday, February 1, 2015, David Pilato <da...@pilato.fr> wrote: > > I have included all the required libraries. > > *java.lang.NoClassDefFoundError: > org.elasticsearch.common.settings.ImmutableSettings* > > > Sounds like you did not include elasticsearch jar. > > -- > David ;-) > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs > > Le 1 févr. 2015 à 17:41, 4m7u1 <amtulnazne...@gmail.com > <javascript:_e(%7B%7D,'cvml','amtulnazne...@gmail.com');>> a écrit : > > I have a custom method for indexing data into elasticsearch. When i run > this, i get the error as :* java.lang.NoClassDefFoundError: > org.elasticsearch.common.settings.ImmutableSettings* > I have included all the required libraries. > > public void insertIntoElasticsearch(String JsonString, String idAttribute) > { > Settings settings = > ImmutableSettings.settingsBuilder().put("http.enabled", > "false").put("transport.tcp.port", > "9300-9400").put("discovery.zen.ping.multicast.enabled", "false") > > .put("discovery.zen.ping.unicast.hosts", "localhost").build(); > > TransportClient client = new TransportClient(settings); > client.addTransportAddress(new > InetSocketTransportAddress("localhost",9300)); > IndexResponse response = client.prepareIndex("dbdata", > "type",idAttribute ).setSource(JsonString).execute().actionGet(); > String _id = response.getId(); > System.out.println("-----id-----" + _id + "---------"); > System.out.println("-----Insert Into Elasticsearch-----"); > } > > > Thanks. > > -- > 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 elasticsearch+unsubscr...@googlegroups.com > <javascript:_e(%7B%7D,'cvml','elasticsearch%2bunsubscr...@googlegroups.com');> > . > To view this discussion on the web visit > https://groups.google.com/d/msgid/elasticsearch/0557a204-ca5d-477b-8fb7-f86e8bcaf1c7%40googlegroups.com > <https://groups.google.com/d/msgid/elasticsearch/0557a204-ca5d-477b-8fb7-f86e8bcaf1c7%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > > -- > You received this message because you are subscribed to a topic in the > Google Groups "elasticsearch" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/elasticsearch/0ZXIsmo8AwQ/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > elasticsearch+unsubscr...@googlegroups.com > <javascript:_e(%7B%7D,'cvml','elasticsearch%2bunsubscr...@googlegroups.com');> > . > To view this discussion on the web visit > https://groups.google.com/d/msgid/elasticsearch/BD9D86C7-E176-41D3-9B1B-0E355738474C%40pilato.fr > <https://groups.google.com/d/msgid/elasticsearch/BD9D86C7-E176-41D3-9B1B-0E355738474C%40pilato.fr?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- Regards, Amtul Nazneen -- 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 elasticsearch+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CA%2BEOwQ%3D%2B3R9jzPtoiYHp1T0bB4r2_uTzA3C3D0zu5FHjchHtsw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.