Commit Graph

5926 Commits

Author SHA1 Message Date
Shay Banon d111e169a4 cleanup MetaData#Builder construction
have a better method name, and only allow to create a copy of the builder based on existing meta data when constructing the builder
2013-11-02 01:04:33 +01:00
Shay Banon acc5f584d4 fix test to not rely on execution of processed / ack order
also, make sure the order is consistent (as much as possible) when calling ack to processed
2013-11-02 00:04:12 +01:00
Andrew Raines 7d2c4afa98 _cat/nodes improvements.
* Handle info/stats null possibilities if cluster is in duress.

* Shorten node id.
2013-11-01 17:33:54 -05:00
Andrew Raines 928ac2e3b7 Ignore project tmp dir. 2013-11-01 16:42:51 -05:00
Andrew Raines f9a1726300 Add _cat/health.
% curl localhost:9200/_cat/health\?v=1\&ts=0
cluster  status nodeTotal nodeData shards pri relo init unassign
kluster green          1        1     20  20    0    0        0

% curl localhost:9200/_cat/health\?ts=0
kluster green 1 1 20 20 0 0 0

% curl localhost:9200/_cat/health\?v=1
epoch      time     cluster  status nodeTotal nodeData shards pri relo init unassign
1383341092 16:24:52 kluster green          1        1     20  20    0    0        0

% curl localhost:9200/_cat/health
1383341119 16:25:19 kluster green 1 1 20 20 0 0 0

Closes #4050.
2013-11-01 16:37:23 -05:00
Andrew Raines 48f4ba06c0 Add TimestampedTable subclass. 2013-11-01 16:37:22 -05:00
Andrew Raines 720edafa0d Disable RestTable headers by default. 2013-11-01 16:37:22 -05:00
Simon Willnauer caee7c8831 Stableize recoverWhileRelocating by expanding replicas at the end 2013-11-01 22:16:24 +01:00
Shay Banon f720531328 protect ImmutableOpenMap builder from using the built map after build has been called 2013-11-01 20:53:24 +01:00
Shay Banon 633e781204 remove unneeded check... 2013-11-01 19:44:25 +01:00
Luca Cavanna afa0ab6226 Fixed ack behaviour when no ack is expected from any node or timeout is set to 0
We now return acknowledged true when no wait is needed (mustAck always returns false). We do wait for the master node to complete its actions though. Previously it would try to timeout and hang due to a CountDown#fastForward call when the internal counter is set to 0

We now return acknowledged false without starting the timeout thread when the timeout is set 0, as starting the wait and immediately stopping the thread seems pointless.

Added coverage for ack in ClusterServiceTests
2013-11-01 18:24:45 +01:00
Shay Banon c63741db04 Introduce a new ImmutableOpenMap
this map is a "true" immutable map, encapsulating an open impl, and has a builder that allows it to be built easily.
the builder has the optimization of using clone if its being built based on an existing immutable map.
2013-11-01 18:20:25 +01:00
Luca Cavanna a021c1d4f2 Improved acknowledgement test for cluster reroute with dry_run flag
Usually acknowledged true means that all nodes have digested the change and are in sync. When no changes are made, there is no need to push a new cluster state, no need to wait for ack either, but can't guarantee that all nodes are in sync.

When using cluster reroute with dryRun flag no changes are made, this test was based on the wrong assumption that acknowledged meant all nodes were in sync, which is not the case here.

Changed the test to only read the cluster state from the master, to check that nothing changed there after processing the cluster state update.
2013-11-01 15:45:31 +01:00
Dan Everton 6df60b7271 [DOC] Improve documentation on search stats groups
Document the ability to return all search statistics groups and provide examples of returning search statistics for groups.
2013-11-01 13:53:39 +01:00
Simon Willnauer c78c5469e4 Randomize exceptions when file is deleted while still open.
This somehow emulates a behavior on windows but we should test the
other code paths as well.
2013-11-01 11:47:22 +01:00
Martijn van Groningen 30ab6f841d [DOCS] Fixed percolate docs errors 2013-11-01 11:44:07 +01:00
Martijn van Groningen d660b18298 Fixed bug (NPE) in mpercolate api, defaults from percolating existing documents where also applied for the regular percolate api, these defaults were none existing (null). 2013-11-01 11:17:16 +01:00
Martijn van Groningen 65fc90728e The mpercolate api rest endpoint should also support http get. 2013-11-01 11:09:17 +01:00
Luca Cavanna 29363d8139 Removed needless concreteIndices call, already called in doExecute and set to the request object 2013-10-31 20:58:52 +01:00
Clinton Gormley 4206cc988e [DOCS] Typo on shingle tokenfilter 2013-10-31 20:18:00 +01:00
Luca Cavanna 3ee9f27fbe Fixed delete mapping to return acknowledged false when ack times out 2013-10-31 16:28:44 +01:00
Martijn van Groningen 81089fb228 Fixed concurrency issue in simple id cache. The lget() of a map can only be used if the map isn't shared. 2013-10-31 16:20:29 +01:00
Shay Banon c68016bb83 better timeout handling waiting for primary to be active for indexing
take into account the correct delta timeout when scheduling it, since now we can retry again after removing a listener
2013-10-31 15:54:37 +01:00
Simon Willnauer fcfc41209b use Math.max rather than an if statement 2013-10-31 14:36:24 +01:00
Simon Willnauer 59588913b3 Evilize RecoveryWhileUnderLoadTests a bit more 2013-10-31 14:25:28 +01:00
Shay Banon 5f2b7dc266 improve moving from post_recovery to started
we need to move to started from post recovery on cluster level changes, we need to make sure we handle a global state change of relocating, which can happen (and not pass through started)
2013-10-31 14:23:58 +01:00
Opak Alex 6856cfc5e3 add reference for ember-data-elasticsearch-kit to integrations page 2013-10-31 11:40:01 +01:00
Shay Banon 5cd56e5cea Improve new field mapping introduction performance
Improve the introduction of new fields into the concrete parsed mappings by not relying on immutable maps and copying over entries, but instead using open maps (which will also use less memory), and using clone to perform the copy on write logic
2013-10-31 11:07:52 +01:00
Simon Willnauer f01d3a18ad Simplify FieldData API
Removing #getValue and #hasValue to have a simple and consistent API
for multiple values.
2013-10-31 10:10:35 +01:00
Shay Banon 75eda6e957 upgrade randomized testing to 2.0.12 2013-10-31 10:02:03 +01:00
Alexander Reelsen dfcb3ca2d4 RegexpQueryBuilder now implements MultiTermQueryBuilder
This allows the RegexpQueryBuilder to be used in span queries

Added tests for all span multi term queries.
Also updated the documentation and removed mentioning of numeric range
queries for span queries (they have to be terms).

Closes #3392
2013-10-31 09:12:57 +01:00
Igor Motov d43f3d83d8 The +index pattern without a wildcard in the index list is handled inconsistently
Fixes #3979
2013-10-30 16:36:55 -04:00
Igor Motov 3b4b05e2c9 Fix bug in TransportShardReplicationOperationAction retry mechanism
This issue was causing some index requests against shards in POST_RECOVERY state to hang.
2013-10-30 16:36:55 -04:00
Andrew Raines 5d46e69154 Add ES version to _cat/nodes. 2013-10-30 15:35:41 -05:00
Andrew Raines 256605f065 Add heap used percentage to _cat/nodes.
Closes #4020.
2013-10-30 13:50:29 -05:00
Andrew Raines b2e8ec2924 Add node name & ip to _cat/recovery.
Closes #4016.
2013-10-30 12:38:31 -05:00
Boaz Leskes 8819f91d47 Add a GetFieldMapping API
This new API allows to get the mapping for a specific set of fields rather than get the whole index mapping and traverse it.
The fields to be retrieved can be specified by their full path, index name and field name and will be resolved in this order.
In case multiple field match, the first one will be returned.

Since we are now generating the output (rather then fall back to the stored mapping), you can specify `include_defaults`=true on the request to have default values returned.

Closes #3941
2013-10-30 16:16:36 +01:00
Andrew Raines f16eb7a243 Add _cat/allocation/{nodes}.
Visualizes how shards distribute across the cluster.

% curl localhost:9200/_cat/allocation
shards diskUsed diskAvail diskRatio ip        node
     2   85.6gb   379.4gb     22.6% 127.0.0.1 MacTaggert, Moira
     2   85.6gb   379.4gb     22.6% 127.0.0.1 Jarvis, Edwin

% curl localhost:9200/_cat/allocation/Jar\*
shards diskUsed diskAvail diskRatio ip        node
     2   85.6gb   379.4gb     22.6% 127.0.0.1 Jarvis, Edwin
2013-10-30 10:09:45 -05:00
Shay Banon 8aa2ee7bac indices cluster state service should execute as one of the first listeners
its preferable to execute the indices cluster state service as quickly as possible, as one of the first listeners, so it will apply the cluster state to the local state
potentially, it should even execute before it state is "visible" (through the state call), but that's another change...
2013-10-30 15:53:31 +01:00
Clinton Gormley 8b2efd4849 [DOCS] Added a version flag to percolation 2013-10-30 13:59:03 +01:00
Clinton Gormley 0585890a5f [DOCS] Fixed a typo 2013-10-30 13:57:18 +01:00
Shay Banon 8a62619fb9 throw index already exists failure when it exists as alias on creation
make sure to throw the already exists exception, so when indexing into an alias, and it has not propagated yet through the cluster state, it will end up being ignored if it already exists
2013-10-30 13:47:31 +01:00
Boaz Leskes ed39e79d8f minor improvement to FullRollingRestartTests failure output 2013-10-30 12:08:54 +01:00
Simon Willnauer 454dc53483 Add back hashed BytesValues optimization that got lost in a previous commit.
Some FieldData consumers require hash values per byte. We provide an optimization
that allows to cache the hashes internally if the consumer knows that they are needed
this optimization got lost in a previous commit. This commit adds them back and folds
the dedicated method into AtomicFieldData#getBytesValues(true|false)
2013-10-30 11:48:00 +01:00
Boaz Leskes 542f021d6f Also resend shard started message if shard state is in POST_RECOVERY and master thinks it's initializing.
Closes #4009
2013-10-30 11:42:57 +01:00
Shay Banon 8f21d2831a explicitly enable http when running plugin tests
add an option to force a setting when building a node, overriding if its explicitly set as system property
2013-10-30 02:09:43 +01:00
Luca Cavanna 9cb54c0f2e Added getters for fs.path, fs.mount and fs.dev in node stats api
Closes #4004
2013-10-29 14:49:07 +01:00
Alexander Reelsen 2ec9742147 [DOCS] Extending setup as a service documentation
* Tell people to use ES_JAVA_OPTS for es.node.name or similar parameters
* Showing a simple way to install Oracle JDK on ubuntu/debian

Closes #3999
2013-10-29 13:58:06 +01:00
Alexander Reelsen b6d2be7a51 Improving test stability for CompletionTests
Randomized testing caught an issue showing that the test should
flush after indexing a document, as always the same document is
indexed.
2013-10-29 13:11:34 +01:00
Luca Cavanna 9e6fab3a6d Added support for acknowledgements to update cluster settings api
As a side note, the internal reroute call is now part of the ack mechanism. That means that if the response contains acknowledged flag, the internal reroute that was eventually issued was acknowledged too. Also, even if the request is not acknowledged, the reroute is issued before returning, which means that there is no need to manually call reroute afterwards to make sure the new settings are immediately applied.

Closes #3995
2013-10-29 11:45:59 +01:00