Commit Graph

9107 Commits

Author SHA1 Message Date
Adrien Grand bc41190dba [Build] @Nullable annotation is not applied to primitive types. 2014-08-11 15:28:41 +02:00
Colin Goodheart-Smithe 5349ecdb77 Mapping: fixes dynamic mapping of geo_point fields
If a dynamic mapping for a geo_point field is defined and the first document specifies the value of the field as a geo_point array, the dynamic mapping throws an error as the array is broken into individual number before consulting the dynamic mapping configuration.  This change adds a check of the dynamic mapping before the array is split into individual numbers.

Closes #6939
2014-08-11 13:08:32 +01:00
Adrien Grand 1210b08ecb [TEST] Fix SimpleQueryTests.testRangeQuery assumptions.
This test assumed that the `num` field was mapped as an integer on all shards
and thus that all of them should fail when providing a timezone. However, since
it used dynamic mappings, some shards might have this field not mapped, as a
consequence they didn't fail.
2014-08-11 14:00:49 +02:00
Colin Goodheart-Smithe 36083cb27f [DOCS] Added section describing how to return only agg results
Closes #5875
2014-08-11 11:31:01 +01:00
javanna a03860970b Internal: refactored TransportSingleCustomOperationAction, subclasses and requests
TransportSingleCustomOperationAction is subclassed by two similar, yet different transport action: TransportAnalyzeAction and TransportGetFieldMappingsAction. Made their difference and similarities more explicit by sharing common code and moving specific code to subclasses:
- moved index field to the parent SingleCustomOperationAction class
- moved the common check blocks code to the parent transport action class
- moved the main transport handler to the TransportAnalyzeAction subclass as it is only used to receive external requests through clients. In the case of the TransportGetFieldMappingsIndexAction instead, the action is internal and executed only locally as part of the user facing TransportGetFieldMappingsAction. The corresponding request gets sent over the transport though as part of the related shard request
- removed the get field mappings index action from the action names mapping as it is not a transport handler anymore. It was before although never used.

Closes #7214
2014-08-11 11:08:38 +02:00
olivier bourgain ac40eae3e3 Core: Improve XContentBuilder API. 2014-08-11 10:40:10 +02:00
javanna c7a9b3da5b Internal: removed needless serialization code from TransportIndexReplicationAction and corresponding request object
TransportIndexReplicationAction is always executed locally, as an internal action that is part of either delete by query or delete (when routing is required but not specified). Only the corresponding shard level requests get sent over the transport, hence no transport endpoint is needed for the index version, nor the index request itself is supposed to be sent over the transport.

Moved classes from org.elasticsearch.action.delete.index to org.elasticsearch.action.delete and adjusted visibility so that internal requests are not public anymore.

Also removed serialization code from IndexDeleteResponse as it never gets sent over transport either.

Closes #7211
2014-08-11 10:02:04 +02:00
Alexander Reelsen fbd337921f Test: Improved CLI testing infrastructure
Added a CaptureOutputTerminal class to the infrastructure, which can be used
in tests, to make sure that CLI commands write out the right data
2014-08-11 09:52:55 +02:00
javanna d01e79429a [TEST] moved testUpdateRequest unit test method to a proper unit test class 2014-08-08 23:26:06 +02:00
Areek Zillur 99ae3066de Suggester: add suggestRequest to Requests and fix broken javadocs in client
closes #7206
2014-08-08 12:09:28 -04:00
mikemccand 5335e3d22d Test: make sure mappings are on all shards to prevent false test failures 2014-08-08 10:51:23 -04:00
Robert Muir 1a09e7180a vary offset/length (i hope) in compressed stream test 2014-08-08 09:54:46 -04:00
Clinton Gormley 34830368d9 Update clearcache.asciidoc
Changed `field_data` to `fielddata` to be consistent with the indices stats output

Closes #2888
2014-08-08 13:03:59 +02:00
javanna 6d3bcc4451 Java API: add index, type and id to ExplainResponse
Index, type and id were returned as part of the REST explain api response, but not through java api. That info was read out of the request, relying on the fact that the index would get overridden with the concrete one within that same request.

Closes #7201
2014-08-08 12:52:03 +02:00
Clinton Gormley f28ada6416 Docs: Made config comment about min_master_nodes more explicit
Closes #2818
2014-08-08 12:44:01 +02:00
javanna 7f2b18864c Java API: fixed warnings in TermVectorRequest, also called super.validate for index not null check 2014-08-08 12:05:29 +02:00
Britta Weber d49ed93488 Docs: md -> asciidoc 2014-08-08 11:25:14 +02:00
Robert Muir 5377d03173 Fix BytesStreamInput(BytesReference) ctor with nonzero offset 2014-08-08 03:22:34 -04:00
Ryan Ernst 1386232e1f Test: Add test with mix of ints/longs/strings/bytes to compress. 2014-08-08 00:21:41 -07:00
Alexander Reelsen 724b14cef6 Mapping API: Improve IP address validation
Until now, IP addresses were only checked for four dots, which
allowed invalid values like 127.0.0.111111

This adds an additional check for validation.

Closes #7131
2014-08-08 08:48:38 +02:00
Alexander Reelsen 9e4064a9ba Dependencies: Version bump HPPC to 0.6.0 2014-08-08 08:20:07 +02:00
Robert Muir 4e16258648 add multithreaded compressed streams tests 2014-08-08 01:49:00 -04:00
Robert Muir 3f13967c36 remove dead unused code 2014-08-07 20:13:10 -04:00
Robert Muir e8e71e323a move unused code to src/test 2014-08-07 19:36:58 -04:00
Robert Muir 87670c613f ensure we exceed 65k in size sometimes in test 2014-08-07 18:40:47 -04:00
Robert Muir 59aabf30f8 add more evilness to compressed streams test 2014-08-07 18:30:27 -04:00
Martijn van Groningen e4d35c458a [TEST] Associate type with percolate query 2014-08-07 23:51:18 +02:00
Robert Muir d341274457 test some linedocs data with compressed streams 2014-08-07 17:20:41 -04:00
Robert Muir 975327775a test some random bytes with compressed streams 2014-08-07 16:47:36 -04:00
Ryan Ernst 90d2cb7dd5 Internal: Remove (mostly) unused 'failure' member from ShardSearchFailure.
closes #6837
closes #6861
2014-08-07 13:12:54 -07:00
Robert Muir 197ef0b205 test random strings in CompressedStringTests 2014-08-07 15:45:41 -04:00
baldurh 700e50fc6c Update update.asciidoc
Closes #6577
2014-08-07 21:07:04 +02:00
uboness 1f9bceb5c5 Cleaned up TransportMessage and added transient context to it
- The context enables setting arbitrary transient data on the message (this data is not serialized with the request)
 - Changed header accessors/mutators so header manipulation will be done directly on the request (to void NPE with transport message headers when dealing with maps that can potentially be null)
2014-08-07 17:00:53 +02:00
Elie A e1a2d76626 Fixing typo in the first JSON example
Closes #7172
2014-08-07 14:06:09 +02:00
javanna dbb513f5b0 Java api: remove operationThreaded setter from ExplainRequestBuilder, already available in base class SingleShardOperationRequestBuilder
It also didn't follow the setter convention that we adopted for request builders.
Fixed also javadocs warning caused byt missing descriptions for tag.

Closes #7186
2014-08-07 13:41:57 +02:00
Adrien Grand a242a63817 [DOCS] Remove the section about codecs.
This documentation was dangerous because it felt like it was possible to gain
substantial performance by just switching the codec of the index.

However, non-default codecs are dangerous to use since they are not supported
in terms of backward compatibility, and most improvements that they bring have
been folded into the default codec anyway (for example, the default codec
"pulses" postings lists that contain a single document).
2014-08-07 11:24:44 +02:00
Colin Goodheart-Smithe e6632ec63e [DOCS] fixed title for filters aggregation documentation 2014-08-07 08:37:43 +01:00
Clinton Gormley 7b0b315b71 Tidied up the filters agg docs and added a coming[] tag 2014-08-07 09:03:23 +02:00
Clinton Gormley 9d65db4dba Test: Trimmed trailing whitespace to make valid YAML 2014-08-06 15:05:46 +02:00
Clinton Gormley 11f8edd74a REST spec: Added missing query_cache param to clear_cache, nodes.stats and indices.stats
Relates to #7167 and #7161
2014-08-06 13:32:33 +02:00
javanna b73b37a8f0 Internal: fixed typo in NodeService s/disovery/discovery 2014-08-06 13:31:11 +02:00
javanna feb3839f0f [TEST] fixed unicast bw comp test configuration
The second internal node, when present, wasn't able to join the existing cluster due ti misconfigured unicast hosts, thus it would form its own cluster.
2014-08-06 13:31:11 +02:00
Adrien Grand 584d2c32dd [TEST] Assert that put mappings requests are acked in GeoMappingTests. 2014-08-06 11:56:20 +02:00
Clinton Gormley e7f1aa4f4f Documented the query cache module
Related to #7161 and #7167
2014-08-06 11:55:11 +02:00
javanna 6f09eb1b06 [TEST] simplified unicast bw comp test
also fixed unchecked warning in CompositeTestCluster
2014-08-06 09:54:53 +02:00
uboness 6f73c93692 Added an option to add arbitrary headers to the client requests
The headers are key/value pairs defined in the settings under the `request.headers` namespace.
2014-08-06 03:33:08 +02:00
mikemccand 06709faff2 Fix false assert trip 2014-08-05 15:47:21 -04:00
Shay Banon f216dc4ab8 [TEST] make sure all shards have docs
we need that in order for refresh to be effective and actually refresh in the second round of indexing, otherwise, it caches a 0 docs shard and a refresh won't expire anything there
2014-08-05 20:28:47 +02:00
Shay Banon e6e2781ee7 [Query Cache] Add a request level flag to control query cache
A request level flag, defaults to be unset, to control the query cache. When not set, it defaults to the index level settings, when explicitly set, will override the index level setting
closes #7167
2014-08-05 18:28:49 +02:00
markharwood e6b459cb9f Update API enhancement - add support for scripted upserts.
In the case of inserts the UpdateHelper class will now allow the script used to apply updates to run on the upsert doc provided by clients. This allows the logic for managing the internal state of the data item to be managed by the script and is not reliant on clients performing the initialisation of data structures managed by the script.

Closes #7143
2014-08-05 16:52:44 +01:00