Commit Graph

8089 Commits

Author SHA1 Message Date
Simon Willnauer e60ca8d8d7 [Test] Speed up RandomAllocationDeciderTests 2014-04-01 12:03:57 +02:00
Shay Banon 6e12584018 [TEST] delegate to the original transport 2014-04-01 11:52:18 +02:00
javanna 38dd501ab5 [TEST] added ExternalTestCluster that allows to run tests against an external cluster
All the ordinary test operations happen based on the ImmutableTestCluster base class and are executed via transport client. Will be used especially for the REST tests once migrated to the standard randomized runner.

Added new httpAddresses method to ImmutableTestCluster to be able to retrieve the http addresses to connect to for the REST tests. Both versions will look inside the cluster to figure out which nodes are available for http calls and their addresses.

The external cluster is used as global cluster if the tests.cluster system property is available. The property needs to contain a comma separated list of available elasticsearch nodes that will be used to connect to the cluster (e.g. localhost:9300,localhost:9301).

Only a subset of the integration tests can currently be run successfully against the external cluster, for more precision the ones that don't modify the cluster layout (don't require cluster() functionalities but rely only on immutableCluster()). Also at least two data nodes are required otherwise the ensureGreen calls cannot succeed.

Closes #5630
2014-04-01 11:45:35 +02:00
Chris Earle 70c089de0a Replaces usage of `StringBuffer` with `StringBuilder` and fixes stray
single quote in the same `PluginInfo#toString()` method.

Closes #5605
2014-04-01 10:40:07 +02:00
Adrien Grand a34378f852 Do not propagate errors from onResult to onFailure.
The way that SearchServiceTransportAction executes actions on a local node
today would propagate exceptions thrown in onResult to onFailure.

Close #5629
2014-04-01 10:02:29 +02:00
Bill Hwang fac4da822d [BUILD] Switch 1x to JDK7 download
Changed download URL for 1x build to point to JDK7 latest
2014-03-31 19:28:27 -07:00
Boaz Leskes 350fd8e30b Added trace logging in TransportSearchTypeAction and a delayed verification of test failures in MinDocCountTests.testMinDocCountOnTerms 2014-03-31 23:23:46 +02:00
Shay Banon cc4cae3ba0 Mock Transport: Allow to simulate network failures
An infrastructure that allows to simulate different network topologies failures, including 2 basic ones in failure to send requests, and unresponsive nodes
closes #5631
2014-03-31 22:49:10 +02:00
Boaz Leskes 62b850f52d InternalEngine - back to set dirty=false just *before* a refresh is done
reverting: 5553c383bc
2014-03-31 20:57:58 +02:00
Simon Willnauer c7b1f9946f Discard new cluster state if the clustername doesn't match
Closes #5622
2014-03-31 20:23:49 +02:00
Simon Willnauer df7474b9fc Add cluster_name to cluster_state
Today the clusterstate is not asssociated with the cluster_name which is odd
since it's pretty much it's only valid identifier. Any node can send a cluster
state to another node today even if it's not the same cluster. These situations
can happen rarely during tests or even in the wild by accident.
2014-03-31 20:23:49 +02:00
Nik Everett 1df942b463 [docs] Indices stats groups in nodes api
Closes #5349
2014-03-31 19:54:48 +02:00
javanna d570d588a8 [TEST] moved dataNodes method to ImmutableTestCluster base class, replaced cluster().dataNodes() calls with immutableCluster().dataNodes() 2014-03-31 19:09:53 +02:00
javanna bae3203e3b [TEST] replaced cluster().size() calls with immutableCluster().size 2014-03-31 19:07:30 +02:00
javanna 8fe6fe638d [DOCS] fixed transport client link in java api docs 2014-03-31 18:35:57 +02:00
javanna 8aea3a2f7d [TEST] fixed TestCluster size() javadocs 2014-03-31 18:34:26 +02:00
javanna 015c21c395 [TEST] move SuggestSearchTests to make use of default number of replicas randomization (based on number of data nodes) 2014-03-31 18:34:25 +02:00
javanna aac1374c76 [TEST] replaced cluster().wipeIndices|wipeTemplates calls with immutableCluster().wipeIndices|wipeTemplates 2014-03-31 18:34:25 +02:00
uboness d6636fc50c Aggregations cleanup
- removed an abstraction layer that handles the values source (consolidated values source with field data source)
- better handling of value parser/formatter in range & histogram aggs
- the buckets key will now be shown by default in range agg
2014-03-31 18:06:48 +02:00
Simon Willnauer 2cd6772329 [TEST] Set minimum_master_nodes for new node as well to make sure all ndoes have the same settings 2014-03-31 18:01:03 +02:00
Boaz Leskes 5553c383bc InternalEngine - only set dirty=false after a refresh happened 2014-03-31 17:39:57 +02:00
Boaz Leskes 1aac41e0d1 InternalEngine - added an assert to verify refresh was performed by lucene 2014-03-31 17:28:38 +02:00
Shay Banon f19f729498 Cleanup Rest Response
simplify rest response class hierarchy, by using BytesReference for content, and handling JSONP internally in the respective channel that sends the response.
Also, handle the future case where bytes might be releasable, when we start to potentially recycle bytes output stream.
2014-03-31 17:24:02 +02:00
Alexander Reelsen 0ff30ade69 ContextSuggester: Adding couple of tests to catch more bugs
A bunch of minor fixes have been included here, especially due
to wrongly parsed mappings. Also using assertions resulted in an
NPE because they were disabled in the distribution.

Closes #5525
2014-03-31 16:16:21 +02:00
Shay Banon f424319f9a Fix visibility in buffered translog
- fix visiblity of last written position in translog
- while there, make sure to properly propagate the exception from sync()
2014-03-31 15:23:23 +02:00
Clinton Gormley a809bfbcb2 [TEST] Fixed TTL tests for create, index, update
Were failing on faster boxes
2014-03-31 15:13:14 +02:00
javanna 2e26dc328e [TEST] introduced ImmutableTestCluster abstract base class for TestCluster
The new base class contains all the immutable methods for a cluster, which will be extended by the future ExternalCluster impl that relies on an external cluster and won't be adding nodes etc. but only sending requests to an existing cluster whose layout never changes

Closes #5620
2014-03-31 14:41:05 +02:00
Alexander Reelsen 056ad0a8d3 Bulk API: Ensure that specific failures do not affect whole request
Before a bulk request is executed, missing indices are being created by default.
If this fails, the whole request is failed.

This patch changes the behaviour to not fail the whole request, but rather all
requests using the index where the creation has failed.

Closes #4987
2014-03-31 14:11:28 +02:00
Boaz Leskes 3f37a0ff5c TransportMasterNodeOperationAction: tighter postAdded change check
If a node fails to forward a master node operation to the current master, it will schedule a retry using a listener for cluster state changes. Once the listener is in place (and future changes are guaranteed to be observed) it will double check nothing has change during the addition of the listener. This check has previously been change to use cluster state versions (see: #5499). This is however not reliable solution as master elections (which change the master) do not increment the cluster state version and thus could be missed. This commit changes the check to use reference equality making it stricter.

Closes #5548
2014-03-31 13:57:47 +02:00
Simon Willnauer 5007bf7aa0 [Test] remove timeout from deleteWarmer call with many shards that might just take a while 2014-03-31 13:53:38 +02:00
Hannes Korte c11293ad78 Fix some typos in documentation. 2014-03-31 13:48:17 +02:00
Kevin Wang 3338750f14 check "store" for binary mapper and check "index_name" for all mappers
closes #5474
2014-03-31 12:44:00 +02:00
Adrien Grand 04c16b7ba5 Fix some warnings reported by Findbugs.
Although high-severity bugs were mostly static variables that were not final,
it also found potential NPEs and bugs like `x ^= x;` or equality checks on
objects that don't share a common interface.

Close #5571
2014-03-31 12:37:04 +02:00
javanna 31ecf1db98 [TEST] Test sending the request body as source parameter with GET method through REST tests
For around 10% of the calls that support the GET method, the request body gets now sent as `source` parameter with GET method (no randomized method in this case).

This way we can find bugs like #5556 (missing support for source param).
2014-03-31 12:36:03 +02:00
Adrien Grand 7f640dbcc6 Refactor common code for unmapped aggregators into `NonCollectingAggregator`.
Our aggregators that are dedicated to unmapped fields all look more or less
the same so this hopefully helps remove some spaghetti code.

Close #5528
2014-03-31 11:46:13 +02:00
Alexander Reelsen fdcc843627 Search template: Fix support for source parameter
If a search template was created using the source parameter, the
content of the parameter was put as source instead of sourceTemplate

Fixes #5556
2014-03-31 11:40:44 +02:00
Alex Brasetvik cd8ed388d9 Document http.cors-settings 2014-03-31 11:34:46 +02:00
javanna 84770c7d33 [TEST] decreased number of replicas to 0 in refresh tests
Some tests disable refresh and verify that documents cannot be found without an explicit refresh. With at least one replica and waiting for yellow though, it can happen that we start indexing docs when the replicas are not ready yet, and as soon as they become ready they get refreshed, causing the newly added docs to be unexpectedly found. Solution is to disable replicas for these specific tests.
2014-03-31 11:28:34 +02:00
Martijn van Groningen 3b73209123 An improvement to unicast discovery to also ping nodes the node itself received a ping from.
Also moved the unicast tests all in a single package.

Closes #5508
2014-03-31 10:51:25 +07:00
Andrew O'Brien bd9c1bc8d9 Update has-parent-filter.asciidoc
"This filter return child..." => This filter returns child...
2014-03-31 00:06:35 +02:00
Simon Willnauer c84f975ff3 [TEST] Wait for shards to allocate before cleaning caches 2014-03-29 21:06:29 +01:00
javanna 5665ea9dad Fixed highlighting inconsistencies between REST and Java api
Exposed HighlightBuilder missing global options in Java API: fragmentSize, numOfFragments, highlightFilter, boundaryMaxScan and boundaryChars
Exposed SearchRequestBuilder missing global options shortcuts: setHighlighterFragmentSize, setHighlighterNumOfFragments, setHighlighterFilter, setHighlighterBoundaryMaxScan, setHighlighterBoundaryChars, setHighlighterFragmenter, setHighlighterPhraseLimit & setHighlighterForceSource

Closes #5281
2014-03-28 18:01:03 +01:00
Clinton Gormley 73547648ef [TEST] Update TTL test can fail on faster boxes - improve range of valid vals 2014-03-28 17:23:17 +01:00
Kevin Wang 8ab22a53fe fix dynamic_type in dynamic_template
closes #5256
2014-03-28 14:54:55 +01:00
javanna 34e9f8e83b [TEST] Removed skip regex sections as all the runners implemented the feature 2014-03-28 12:19:46 +01:00
Kevin Wang 5a2d195eb7 add human readable start_time and refresh_interval
closes #5280
2014-03-28 12:05:08 +01:00
Kevin Wang ceed22fe00 Add suggest stats
closes #4032
2014-03-28 11:13:54 +01:00
Holger Hoffstätte 0c1b9a6670 Restore streamInput() performance over PagedBytesReference.
Closes #5589
2014-03-28 11:02:53 +01:00
Kevin e78bbbf3ec add CBOR data format support 2014-03-28 20:30:39 +11:00
Simon Willnauer 68bc785de8 Update .gitignore to ignore the execution hints files 2014-03-28 10:01:08 +01:00