I reported this a while ago, but have new information that may help. I have
a cluster of 3 Linux VMs with ES 0.90.3 running and an older Oracle Java 6.
My driver creates a TransportClient,. Then a writer thread pool creates a
series of unique objects, serializes each to JSON, sends an update to the
cluster, then queues it. A separate reader thread pool reads each unique
object and attempts to query by ID to verify that it's in the database.
This test driver is run on a laptop; the 3-node cluster is remote (in the
lab).
Consistently, I get failures if I add all 3 of the host names to the
TransportClient. It works OK if I add only two of them. Here is the
relevant area of the log, along with a message that the driver pulls out
and writes to stdout:
434 [main] DEBUG org.elasticsearch.client.transport - [Martinex]
node_sampler_interval[5s]
453 [elasticsearch[Martinex][transport_client_worker][T#1]{New I/O worker
#1}] DEBUG netty.channel.socket.nio.SelectorUtil - Using select timeout of
500
453 [elasticsearch[Martinex][transport_client_worker][T#1]{New I/O worker
#1}] DEBUG netty.channel.socket.nio.SelectorUtil - Epoll-bug workaround
enabled = false
476 [main] DEBUG org.elasticsearch.client.transport - [Martinex] adding
address [[#transport#-1][inet[projdev12/192.168.200.222:9300]]]
587 [main] DEBUG org.elasticsearch.transport.netty - [Martinex] connected
to node [[#transport#-1][inet[projdev12/192.168.200.222:9300]]]
701 [main] DEBUG org.elasticsearch.client.transport - [Martinex] adding
address [[#transport#-2][inet[projdev29/192.168.200.241:9300]]]
871 [main] DEBUG org.elasticsearch.transport.netty - [Martinex] connected
to node [[#transport#-2][inet[projdev29/192.168.200.241:9300]]]
955 [main] DEBUG org.elasticsearch.client.transport - [Martinex] adding
address [[#transport#-3][inet[projdev33/192.168.200.133:9300]]]
1209 [main] DEBUG org.elasticsearch.transport.netty - [Martinex] connected
to node [[#transport#-3][inet[projdev33/192.168.200.133:9300]]]
Cluster available...
1396 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl -
Mapped page for /tmp/rtcomm/rtc-driver/meta_data/page-0.dat was just
created and cached.
1437 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl -
Mapped page for /tmp/rtcomm/rtc-driver/index/page-0.dat was just created
and cached.
1452 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl -
Mapped page for /tmp/rtcomm/rtc-driver/front_index/page-0.dat was just
created and cached.
1455 [main] DEBUG com.leansoft.bigqueue.page.MappedPageImpl - Mapped page
for /tmp/rtcomm/rtc-driver/index/page-0.dat was just unmapped and closed.
1456 [main] INFO com.leansoft.bigqueue.page.MappedPageFactoryImpl - Page
file /tmp/rtcomm/rtc-driver/index/page-0.dat was just deleted.
1456 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl - All
page files in dir /tmp/rtcomm/rtc-driver/index/ have been deleted.
1456 [main] INFO com.leansoft.bigqueue.page.MappedPageFactoryImpl - Page
file /tmp/rtcomm/rtc-driver/data/page-0.dat was just deleted.
1456 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl - All
page files in dir /tmp/rtcomm/rtc-driver/data/ have been deleted.
1457 [main] DEBUG com.leansoft.bigqueue.page.MappedPageImpl - Mapped page
for /tmp/rtcomm/rtc-driver/meta_data/page-0.dat was just unmapped and
closed.
1457 [main] INFO com.leansoft.bigqueue.page.MappedPageFactoryImpl - Page
file /tmp/rtcomm/rtc-driver/meta_data/page-0.dat was just deleted.
1457 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl - All
page files in dir /tmp/rtcomm/rtc-driver/meta_data/ have been deleted.
1458 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl -
Mapped page for /tmp/rtcomm/rtc-driver/meta_data/page-0.dat was just
created and cached.
1458 [main] DEBUG com.leansoft.bigqueue.page.MappedPageFactoryImpl - Hit
mapped page /tmp/rtcomm/rtc-driver/front_index/page-0.dat in cache.
STARTING: run=1s threads=1 connection-limit=1 refresh=eventual
1606 [Thread-3] DEBUG com.acme.proj.database.UpdateAction -
UpdateAction.index:
{"index":{"_index":"rtctest","_type":"connection","_id":"30303230303030303032407777772E63656C65626F726E2E636F6D"}}
::
{"onet":"celeborn","orig":"0010000001@celeborn.com","term":"0020000002@www.celeborn.com"}
FAILURE[1] when writing connnection[1]:
{"index":{"_index":"rtctest","_type":"connection","_id":"30303230303030303032407777772E63656C65626F726E2E636F6D"}}
->
{"onet":"celeborn","orig":"0010000001@celeborn.com","term":"0020000002@www.celeborn.com"}
:: class com.acme.proj.database.DatabaseException ElasticSearch index
request:
{"index":{"_index":"rtctest","_type":"connection","_id":"30303230303030303032407777772E63656C65626F726E2E636F6D"}}
::
{"onet":"celeborn","orig":"0010000001@celeborn.com","term":"0020000002@www.celeborn.com"}
: org.elasticsearch.transport.TransportSerializationException: Failed to
deserialize exception response from stream
This was originally chalked up to using an older Java version. But
recently, I updated my driver to optionally create a client-only NodeClient
instead of a TransportClient. Using Zen unicast, I add all 3 host names to
the unicast host list, create a client-only data-less NodeClient, and the
rest of the code is the same from there on. Start-up takes a little longer,
as the NodeClient has to join the cluster and whatever else it does. But
updates are twice as fast, and... there are NO ERRORS!
I am just guessing, but it appears from the outside looking in as if the
NodeClient is the primary way that ES is tested, and perhaps the
TransportClient isn't so extensively tested? I'm not sure what else I can
offer, but the fact that the NodeClient doesn't fail seems to point to the
TransportClient and not the underlying Lucene/Java interaction; the fact
that the NodeClient performs better is icing on the cake.
Regards,
Brian
--
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+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/331ec0b9-ddba-4a6c-80dd-1dbbddd8655c%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.