Commit Graph

9191 Commits

Author SHA1 Message Date
Simon Willnauer a9f42e7176 [BUILD] Randomize JVM heapsize between 512 and 1024m 2014-08-22 09:40:09 +02:00
Simon Willnauer 3b51342515 Use empty BytesRef if we read from <= 1.4.0 2014-08-21 22:13:06 +02:00
Shay Banon ffcc78ca04 Add back string op type to IndexRequest
This was removed by accident I think, and it breaks backward comp. on the Java API in minor 1.3 version
closes #7387
2014-08-21 12:04:09 -07:00
Greg Marzouka 887bd0a9c2 [DOCS] Update to the new {index}/_mapping/{type} format 2014-08-21 13:56:11 -04:00
Igor Motov 80887e8113 [TEST] Trigger random flushes while snapshot is created 2014-08-21 12:48:38 -04:00
Simon Willnauer 058a02b7aa [STORE] Improve recovery / snapshot restoring file identity handling
This commit changes the way how files are selected for retransmission
on recovery / restore. Today this happens on a per-file basis where the
rather weak checksum and the file length in bytes is compared to check if
a file is identical. This is prone to fail in the case of a checksum collision
which can happen under certain circumstances.
The changes in this commit move the identity comparsion to a per-commit / per-segment
level where files are only treated as identical iff all the other files in the
commit / segment are the same. This "all or nothing" strategy is reducing the chance for
a collision dramatically since we also use a strong hash to identify commits / segments
based on the content of the ".si" / "segments.N" file.

Closes #7351
2014-08-21 18:00:41 +02:00
Simon Willnauer 4c1bc3ae4f [STORE] Remove unnecessary deduplication 2014-08-21 17:50:04 +02:00
Simon Willnauer 4d3f761d3d [STORE] Ignore segments.gen on metadata snapshots
The segments.gen file is optional and might even change while we
read it. It's safer to just ignore that file in the snapshot instead.
2014-08-21 17:50:04 +02:00
Shay Banon 4af1a29057 [TEST] filter out keep alive timer thread name
Keep-Alive-Timer is an internal Java thread that might be started, make sure to filter it out
2014-08-21 08:40:43 -07:00
Shay Banon 39a64cf4dd [TEST] only reset clients on nightly tests
resetting the clients on each test (in after test) makes the tests running, especially in network mode, much slower, since transport client needs to be created each time when randmized to be used. Also, on OSX, the excessive connections causes bind exceptions eventually which makes running the network tests much harder on it.
closes #7329
2014-08-21 07:34:26 -07:00
Britta Weber ab9e33e38d _ttl: Report conflict when trying to disable _ttl
_ttl could never be disabled once it was enabled.
But when trying to, no conflict was reported.

relates to #777 and #7293

closes #7316
2014-08-21 16:16:08 +02:00
Britta Weber 2a32cf338e Docs: _ttl ignores all parameters except for enabled and default.
Also, add a line about that it can never be disabled after it was enabled.
2014-08-21 16:16:02 +02:00
Simon Willnauer 99ef3408fb [STORE] Allow to get metadata from arbitrary commit points
Today we always use the latest commit point to return the metadata from
the store. This might cause problems for snapshot and restore since in
contrast to recovery it won't prevent concurrent flushes (lucene commits).
This can lead to all kinds of interesting effects if we are snapshotting
while flushing. This change uses the IndexCommit to open the metadata snapshot
from the store which is consistent with what we snapshot.

Closes #7376
2014-08-21 16:09:12 +02:00
Britta Weber 5bfd75e489 Test: write heap dump per default
The heap dump is always interesting in case a test causes an OOM.
Per default is is written to target/JX/pidXYZ.hprof
2014-08-21 15:59:32 +02:00
Britta Weber 2f9eaae863 Testing doc: describe -Dtests.heap.size and -Dtests.jvm.argline 2014-08-21 15:59:31 +02:00
Colin Goodheart-Smithe 8550b9e84b Aggregations: Fixes pre and post offset serialisation for histogram aggs
Changes the serialisation of pre and post offset to use Long instead of VLong so that negative values are supported.  This actually only showed up in the case where minDocCount=0 as the rounding is only serialised in this case.

Closes #7312
2014-08-21 14:19:53 +01:00
javanna f956920acc Internal: make sure that multi_search request hands over its context and headers to its corresponding search requests
Closes #7374
2014-08-21 15:09:27 +02:00
javanna b6cdaff30c Internal: make sure that multi_percolate request hands over its context and headers to its corresponding shard requests
Closes #7371
2014-08-21 13:45:11 +02:00
Martijn van Groningen 9dd3597f1f [TEST] Sort by the _id field instead of _uid field and also assert the sort value. 2014-08-21 13:30:09 +02:00
javanna c89f941ffa [TEST] added debug lines to bw comp testDeleteByQuery and testDeleteRoutingRequired 2014-08-21 13:11:05 +02:00
Alex Ksikes f1a6b4e9fe More Like This Query: Switch to using the multi-termvectors API
The term vector API can now generate term vectors on the fly, if the terms are
not already stored in the index. This commit exploits this new functionality
for the MLT query. Now the terms are directly retrieved using multi-
termvectors API, instead of generating them from the texts retrieved using the
multi-get API.

Closes #7014
2014-08-21 12:18:21 +02:00
Simon Willnauer c4bed91262 [PARSER] Clarify XContentParser/Builder interface for binary vs. utf8 values
Today we have very confusing naming since some methods names claim to
read binary but in fact read utf-16 and convert to utf-8 under the hood.
This commit clarifies the interfaces and adds additional documentation.

Closes #7367
2014-08-21 11:46:50 +02:00
Adrien Grand b5b1960a2b Internal: Remove CacheRecycler.
The main consumer of this API was the faceting module. Now that it's gone,
let's remove CacheRecycler as well.

Close #7366
2014-08-21 11:21:04 +02:00
javanna 269a6dfb40 [TEST] bw comp testMultiGet should wait for yellow, not for green 2014-08-21 11:14:48 +02:00
javanna 5709a11d23 [TEST] fixed concurrency issue in IndicesRequestTests 2014-08-21 10:43:58 +02:00
Adrien Grand ea96359d82 Facets: Removal from master.
Close #7337
2014-08-21 10:34:39 +02:00
Adrien Grand ded30e95de Aggregations: Remove the logic to optionally sort/dedup values on the fly.
These options are not used anymore. Instead numeric values can now contain dups
and it is the responsibility of the aggregation to deal with it (eg. terms).
And otherwise all values sources are now sorted, which is the contract of the
interfaces that they implement.

Close #7276
2014-08-21 10:25:50 +02:00
Alex Ksikes 62ef4a30dc Term vector API: return 'found: false' for docs between index and refresh
Closes #7121
2014-08-21 09:58:49 +02:00
Igor Motov 150df5f1c5 [TEST] Improve robustness of restoreIndexWithMissingShards test 2014-08-20 21:11:04 -04:00
Shay Banon 9dc4f3861a Query Cache: Add hit and miss count
closes #7355
2014-08-20 14:39:16 -07:00
Shay Banon 2f3a041070 NPE in ShardStats when routing entry is not set yet on IndexShard
closes #7356
2014-08-20 12:48:52 -07:00
javanna abdbfe768b Internal: adjusted internal requests visibility from public to package private (redo)
was just reverted by mistake in the failed attempt of isolating the change and taking it out of #7319
2014-08-20 21:12:37 +02:00
javanna 441c1c8268 Internal: make sure that all shard level requests hold the original indices
A request that relates to indices (`IndicesRequest` or `CompositeIndicesRequest`) might be converted to some other internal request(s) (e.g. shard level request) that get distributed over the cluster. Those requests contain the concrete index they refer to, but it is not known which indices (or aliases or expressions) the original request related to.

This commit makes sure that the original indices are available as part of the shard level requests and makes them implement `IndicesRequest` as well.

Also every internal request should be created passing in the original request, so that the original headers, together with the eventual original indices and options, get copied to it. Corrected some places where this information was lost.

NOTE: As for the bulk api and other multi items api (e.g. multi_get), their shard level requests won't keep around the whole set of original indices, but only the ones that related to the bulk items sent to each shard, the important bit is that we keep the original names though, not only the concrete ones.

Closes #7319
2014-08-20 21:05:01 +02:00
Colin Goodheart-Smithe 0234b5b9b4 fix to compile issue caused by scripted metric aggregation change 2014-08-20 19:25:57 +01:00
Colin Goodheart-Smithe 7f943f0296 Aggregations: Scriptable Metrics Aggregation
A metrics aggregation which runs specified scripts at the init, collect, combine, and reduce phases

Closes #5923
2014-08-20 18:17:27 +01:00
Shay Banon 3a52296358 Warmer (search) to support query cache
allow for search based warmer to support query cache flag on the search request, and use the index level query caching flag if set.
closes #7326
2014-08-20 09:31:29 -07:00
Colin Goodheart-Smithe f7ae4d9d86 Geo: fixes circle radius calculation
This change fixes the creation circle shapes o it calculates it correctly instead of essentially using the diameter as the radius.  The radius has to be converted into degrees but calculating the ratio of the desired radius to the circumference of the earth and then multiplying it by 360 (number of degrees around the earths circumference).  This issue here was that it was only multiplied by 180 making the result out by a factor of 2.  Also made the test for circles actually check to make sure it has the correct centre and radius.

Closes #7301
2014-08-20 16:23:21 +01:00
uboness e2311d5da4 opened up getting the template name from DeleteIndexTemplateRequest 2014-08-20 07:11:15 -07:00
javanna 61da463dd0 Internal: adjusted internal requests visibility from public to package private 2014-08-20 12:11:57 +02:00
javanna 3450e82855 [TEST] UnicastBackwardsCompatibilityTest should not copy internal node settings to external nodes
Recent test failures triggered by #7289 were caused by this, simply because internal node settings (transport type key) that are not supported by the external older nodes were copied to them by mistake.
2014-08-20 12:01:41 +02:00
Alexander Reelsen 357ab3a9d8 Test: Prevent use of transport client when testing changed transports
This makes sure, that the transport client is not used, as it would use
a different than the configured local transport mechanism in this test.
2014-08-20 08:46:03 +02:00
Igor Motov 45ca7771ee Snapshot checksum verification
Adds automatic verification of all files that are being snapshotted. Closes #5593
2014-08-19 20:58:43 -04:00
Igor Motov 0e5332f86c Fix NPE in SnapshotsService on node shutdown
Fixes #6506
2014-08-19 18:48:39 -04:00
Shay Banon 3da5773dd9 Upgrade to Jackson Smile 2.4.1.1
This fixes issue 18 in Smile (https://github.com/FasterXML/jackson-dataformat-smile/issues/18)

closes #7327
2014-08-19 11:10:54 -07:00
Shay Banon fc405f6f8a Upgrade to Netty 3.9.3.Final
closes #7328
2014-08-19 11:09:35 -07:00
Alexander Reelsen 247ff7d801 Transport: Refactor guice startup
* Removed & refactored unused module code
* Allowed to set transports programmatically
* Allow to set the source of the changed transport

Note: The current implementation breaks BWC as you need to specify a concrete
transport now instead of a module if you want to use a different
Transport or HttpServerTransport

Closes #7289
2014-08-19 18:03:06 +02:00
javanna 7aa2d11cdd Internal: auto create index to keep around headers and context of the request that caused it
Closes #7331
2014-08-19 17:04:13 +02:00
javanna a279f2e8c6 Internal: made it possible to disable the main transport handler in TransportShardSingleOperationAction
TransportShardSingleOperationAction is currently subclassed by different transport actions. Some of them are internal only, meaning that their execution will take place only in the same node where their parent execution took place. That means that their main transport handler doesn't need to be registered, the only transport handler that's needed is the shard level one.

Added `isSubAction` method (defaults to false) to the parent class that tells whether the action is a main one or a subaction, used to decide whether we need to register the main transport handler.

Closes #7285
2014-08-19 17:04:13 +02:00
Martijn van Groningen 9c63abde04 [TEST] Added more assertions 2014-08-19 16:34:54 +02:00
Adrien Grand 0f63e0a8da Aggregations: Merge LongTermsAggregator and DoubleTermsAggregator.
These two aggregators basically do exactly the same thing, they just interpret
bytes differently. This refactoring found an (unreleased) bug in the long terms
aggregator which didn't work correctly with duplicate values.

Close #7279
2014-08-19 15:33:05 +02:00