Get an exception when I try to get the specific document in es with indexId, type and documentId


(Yang) #1

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang


(Yang) #2

Could anybody give me a hand?

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang


(Igor Motov) #3

It looks like you have more than one es node and they have problems
communicating to each other. Do you see any errors in the log files?

On Tuesday, June 5, 2012 8:46:47 PM UTC-4, Yang wrote:

Could anybody give me a hand?

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just combine

them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang


(Yang) #4

Dear Motov,

Thanks for your replying.
I checked $es_home$/logs, no other exception.
But what you said remind me.

Actually, I used the code below to get a client and do "index" and "search"
via java API:

NodeBuilder nb = NodeBuilder.nodeBuilder();

node = nb.client(true).node();

esClient = node.client();

Then I try to get a specific document via java API, but I meet the problem
which is the same as I talked before.
So I change the code to "rest", it works.
But these days, it fails again, I don't even change anything.

On Wednesday, June 6, 2012 9:36:30 AM UTC+8, Igor Motov wrote:

It looks like you have more than one es node and they have problems
communicating to each other. Do you see any errors in the log files?

On Tuesday, June 5, 2012 8:46:47 PM UTC-4, Yang wrote:

Could anybody give me a hand?

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and documentId
via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang


(Igor Motov) #5

I think you should start with figuring out how many nodes you are running
and making sure that they all have the same version. Run

curl -XGET 'http://localhost:9200/_cluster/health?pretty=true'

and

curl -XGET 'http://localhost:9200/_cluster/nodes?pretty=true'

to check how many data nodes you actually have in your cluster.

On Wednesday, June 6, 2012 2:15:07 AM UTC-4, Yang wrote:

Dear Motov,

Thanks for your replying.
I checked $es_home$/logs, no other exception.
But what you said remind me.

Actually, I used the code below to get a client and do "index" and
"search" via java API:

NodeBuilder nb = NodeBuilder.nodeBuilder();

node = nb.client(true).node();

esClient = node.client();

Then I try to get a specific document via java API, but I meet the problem
which is the same as I talked before.
So I change the code to "rest", it works.
But these days, it fails again, I don't even change anything.

On Wednesday, June 6, 2012 9:36:30 AM UTC+8, Igor Motov wrote:

It looks like you have more than one es node and they have problems
communicating to each other. Do you see any errors in the log files?

On Tuesday, June 5, 2012 8:46:47 PM UTC-4, Yang wrote:

Could anybody give me a hand?

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang

On Wednesday, June 6, 2012 1:24:17 AM UTC+8, Yang wrote:

Dear all,

I'm playing with ES, but meet a problem, after I spent my whole day, I
couldn't get it done.
I just want to get the specific document by indexId, type and
documentId via the code below:
(all the classes come from org.apache.commons.httpclient)

String docURL = genDocumentURL(indexId, type, documentId);// just

combine them as an url.
HttpClient http = new HttpClient();
GetMethod get = new GetMethod(docURL);
int status = http.executeMethod(get);
log.info("the status of request a document: [" + status + "]");
String body = get.getResponseBodyAsString();
log.info("resopnse body is: [" + body + "]");

After I run the code above, I got the exception below:

the status of request a document: [500]
resopnse body is: [{"error":"RemoteTransportException[Failed to
deserialize response of type [org.elasticsearch.action.get.GetResponse]];
nested: TransportSerializationException[Failed to deserialize response of
type [org.elasticsearch.action.get.GetResponse]]; nested:
IOException[Expected handle header, got [79]]; ","status":500}]

ES version: 0.19.4
All config of ES are default. I don't change anything.

Could anyone give me a hint or a reference, that would be very helpful~~

Thanks very much~

Yang


(system) #6