Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NullPointerexception at org.elasticsearch.action.get.GetResponse.sourceAsString #68

Closed
sbtourist opened this issue Mar 18, 2010 · 3 comments

Comments

@sbtourist
Copy link

When getting a response with null body, org.elasticsearch.action.get.GetResponse.sourceAsString throws NullPointerException, here's the relevant call stack:

at org.elasticsearch.util.Unicode.fromBytes(Unicode.java:70)
at org.elasticsearch.action.get.GetResponse.sourceAsString(GetResponse.java:96)

@kimchy
Copy link
Member

kimchy commented Mar 18, 2010

I will fix the NPE, which is nasty. But you will get a null back since there is no body. You should probably check the GetResponse#exists method first in any case.

@kimchy
Copy link
Member

kimchy commented Mar 18, 2010

NullPointerexception at org.elasticsearch.action.get.GetResponse.sourceAsString, closed by fc3a805

@sbtourist
Copy link
Author

That's absolutely fine.
Thanks much.

rmuir pushed a commit to rmuir/elasticsearch that referenced this issue Nov 8, 2015
 When we want to force a language instead of using Tika language detection, we set `language` field in documents.

 To be consistent with other forced fields, `_content_type` and `_name`, we should prefix `language` field by an underscore `_`.

 So `language` become `_language`.

 We first deprecate `language` in version 2.1.0 and we remove it in 2.3.0.

 Closes elastic#68.

(cherry picked from commit 2f46343)
rmuir pushed a commit to rmuir/elasticsearch that referenced this issue Nov 8, 2015
With elastic#68 we replaced `language`field with `_language`.

We can now remove the old deprecated name.

Closes elastic#69.
(cherry picked from commit e39f144)
ClaudioMFreitas pushed a commit to ClaudioMFreitas/elasticsearch-1 that referenced this issue Nov 12, 2019
path meta/main.yml for fix problem(KeyError) in ansible 1.9.4=< :
henningandersen pushed a commit to henningandersen/elasticsearch that referenced this issue Jun 4, 2020
williamrandolph pushed a commit to williamrandolph/elasticsearch that referenced this issue Jun 4, 2020
williamrandolph pushed a commit to williamrandolph/elasticsearch that referenced this issue Jun 4, 2020
mindw pushed a commit to mindw/elasticsearch that referenced this issue Sep 5, 2022
…est elastic#68)

support transcoding with CloudFront CDN

* support transcoding with cdn

* fixed typo

* Merged master into dev/nikita/support_transcoding_with_cdn_03032021

Approved-by: Rich Nessel
Approved-by: Gideon Avida
Approved-by: Alan Nuchnoi
cbuescher pushed a commit to cbuescher/elasticsearch that referenced this issue Oct 2, 2023
With this commit we enforce a runtime JDK in benchmarks. This is
necessary because Rally will choose the JDK at runtime based on the
allowed / installed JDK versions. By default we stick to JDK 8 (as is).

Relates elastic/rally#518
Relates elastic#68
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants