I felt the documentation for the Java API wasn't as clear at the REST
API documentation, which is very good.
Next, I couldn't find a Javadoc to answer my question below ... (I'm
sure I can checkout the source and generate my own, I know but I'm
Finally, the code examples keep making mysterious method invocations:
import static org.elasticsearch.client.Requests.;
import static org.elasticsearch.util.xcontent.XContentBuilder.;
IndexResponse response = client.index(indexRequest("twitter")
.field("postDate", new Date())
.field("message", "trying out Elastic Search")
Where does the "jasonBuilder()" method come from? Am I missing
There's also the client variable, which was not defined in this
example but I imagine it is defined on the Client doc page.
On Jul 15, 4:05 pm, Shay Banon shay.ba...@elasticsearch.com wrote:
If you are using Java, why not use the Java API directly? You get static
typing, discovery, and better performance than pure HTTP.
On Fri, Jul 16, 2010 at 2:01 AM, David Jensen djense...@gmail.com wrote:
- I'm running 3 nodes
- I'm indexing the data with the REST API over HTTP; I'm not using
keep alive. I'm usng the Java Jersey library so I'll see if there is a
keep alive setting.
On Jul 15, 3:53 pm, Shay Banon shay.ba...@elasticsearch.com wrote:
Some notes on the cloud gateway, it basically provides long term
using s3. A word of caution, its a bit shaky in 0.8, I am working on
it for 0.9 (actually, thats the last issue remaining for 0.9).
The main reason why this slowdown might happen (putting aside amazon
is some sort of a leak in elasticsearch (usually memory). 0.9 is much
better compared to 0.8, though you should not see it with such small
test, so it leads me back to amazon... .
Few more questions:
- How many nodes are you running?
- How do you index the data? I assume HTTP, do you make sure you use
alive with it?
On Fri, Jul 16, 2010 at 1:47 AM, David Jensen djense...@gmail.com
Here are the answers to your questions:
- I have one index and one type
- No cloud gateway ... I'll read the docs on that right now
On Jul 15, 3:37 pm, Shay Banon shay.ba...@elasticsearch.com wrote:
There are many reasons why this might happen, one of them if what
suggested. Let me ask a few more questions:
- Which version are you using?
- How many indices do you create?
- Do you use the cloud gateway?
If you know your way around the JVM, then monitoring the JVM using
visualvm for example for memory usage or GC activity might be a good
On Fri, Jul 16, 2010 at 1:12 AM, Paul Loy ketera...@gmail.com
I would highly recommend that you do not use small instances.
probably got yourself a 'noisy neighbour'. You should use the
instance types to avoid this.
On Thu, Jul 15, 2010 at 10:55 PM, David Jensen <
Yesterday, I started loading about 14M records into ElasticSearch
running on 3 small EC2 instances.
Yesterday, I have two machines with 10 threads each loading
was getting a throughput of about 2.5M records per day. I only
up 1M records so when I came in this morning, it was done.
I queued up another 500k records this morning, when I checked this
afternoon, the throughput dropped to 250k per day. Based on my
timings, it was previously taking 250ms to 350ms for ElasticSearch
take in the record. Now it is taking 3500ms.
I'm not sure what is going on.
So I have a few questions ...
- Besides the REST API docs, is there any other documentation
how ES works behind the scenes and how shards, node, and
is set up?
2. How would you recommend that I debug this issue?
3. How can I accidentally make my index go away? Since I already
1.1M records indexed, I don't want to do something wrong to make
that work disappear.