Commit Graph

4864 Commits

Author SHA1 Message Date
Nik Everett c7c120c781 Remove PROTO from InnerHits
Relates to #17085
2016-04-19 10:17:49 -04:00
Nik Everett edf1c82007 Clean up serialization on some stats
Removes readFrom which is no longer required/actively discouraged and
replaces some instances of `Streamable` with `Writeable`.

Relates to #17085
2016-04-19 10:07:51 -04:00
Nik Everett 860559e543 Remove PROTOTYPE from ExtendedBounds
and make it implement Writeable because it is Writeable.

Relates to #17085
2016-04-19 09:58:37 -04:00
Nik Everett 65f6f6bc8d Normalize registration for SignificanceHeuristics
When I pulled on the thread that is "Remove PROTOTYPEs from
SignificanceHeuristics" I ended up removing SignificanceHeuristicStreams
and replacing it with readNamedWriteable. That seems like a lot at once
but it made sense at the time. And it is what we want in the end, I think.

Anyway, this also converts registration of SignificanceHeuristics to
use ParseFieldRegistry to make them consistent with Queries, Aggregations
and lots of other stuff.

Adds a new and wonderous hack to support serialization checking of
NamedWriteables registered by plugins!

Related to #17085
2016-04-19 09:47:37 -04:00
Nik Everett d62376ce33 Remove PROTOTYPE from KeyedFilter
Relates to #17085
2016-04-19 09:30:45 -04:00
Nik Everett c8af7edb24 Remove PROTOTYPE from AggregatorFactories
Relates to #17085
2016-04-19 09:29:06 -04:00
Daniel Mitterdorfer 0db3eaf7d7 Add additional assertions to IngestClientIT 2016-04-19 15:25:34 +02:00
Boaz Leskes 7cd128b372 Extract non-transport primary logic from TransportReplicationAction #16492
Extracts all the replication logic that is done on the Primary to a separated class called ReplicationOperation. The goal
here is to make unit testing of this logic easier and in the future allow setting up tests that work directly on IndexShards
without the need for networking.

Closes #16492
2016-04-19 15:45:59 +03:00
Nik Everett 7a2b923ad1 Remove deprecated registration methods
Removes deprecated registration methods from SearchModule and
NamedWriteableRegistry and removes the "shims" used to migrate
aggregations to the new registration methods.

Relates to #17085
2016-04-19 08:36:28 -04:00
Christoph Büscher bbe03c92c2 FiltersAggregatorBuilder: Don't create new context for inner parsing
We don't have to create new parse context for inner parsing.
2016-04-19 14:19:11 +02:00
Martijn van Groningen 1a55c073e8 added comment, why we fail here. 2016-04-19 11:32:00 +02:00
Martijn van Groningen 40c22fc654 percolator: removed .percolator type instead a field of type `percolator` should be configured before indexing percolator queries
* Added an extra `field` parameter to the `percolator` query to indicate what percolator field should be used. This must be an existing field in the mapping of type `percolator`.
* The `.percolator` type is now forbidden. (just like any type that starts with a `.`)

This only applies for new indices created on 5.0 and later. Indices created on previous versions the .percolator type is still allowed to exist.
The new `percolator` field type isn't active in such indices and the `PercolatorQueryCache` knows how to load queries from these legacy indices.
The `PercolatorQueryBuilder` will not enforce that the `field` parameter is of type `percolator`.
2016-04-19 11:20:31 +02:00
Jason Tedor ace83d9d2a Refactor UUID-generating methods out of Strings
This commit refactors the UUID-generating methods out of Strings into
their own class. The primary motive for this refactoring is to avoid a
chain of class initializers from loading this class earlier than
necessary. This was discovered when it was noticed that starting
Elasticsearch without any active network interfaces leads to some
logging statements being executed before logging had been
initailized. Thus:
 - these UUID methods have no place being on Strings
 - removing them reduces spooky action-at-distance loading of this class
 - removed the troublesome, logging statements from MacAddressProvider,
   logging using statically-initialized instances of ESLogger are prone
   to this problem

Relates #17837
2016-04-18 21:43:48 -04:00
Nik Everett 6941966b16 Remove PROTOs from TransportAddresses
We have this TransportAddressSerializers that works similarly to
NamedWriteables except it uses shorts instead of streams. I don't know
enough to propose removing it in favor of NamedWriteables to I just ported
it to using Writeable.Reader and left it alone.

Relates to #17085
2016-04-18 18:58:56 -04:00
Ryan Ernst 523b071836 Internal: Remove XContentBuilderString
This was previously used by xcontentbuilder to support camelCase.
However, it is no longer used, and can be replaced with just String.
2016-04-18 14:32:18 -07:00
Ryan Ernst 8ce71f8f25 Merge pull request #17774 from rjernst/camelcase1
Rest: Remove 'case' parameter from rest apis
2016-04-18 14:27:09 -07:00
Ryan Ernst 2739ee6c8f Merge branch 'master' into dots3 2016-04-18 14:24:37 -07:00
Ryan Ernst fbe1f50b18 Add check that no dynamic update was done with existing mappings and
dots
2016-04-18 14:24:11 -07:00
Nik Everett 23dc2d18a2 Fix javadoc for new methods 2016-04-18 16:21:50 -04:00
Nik Everett ff9b28d806 Deprecate remaining readXYZ|writeXYZ methods 2016-04-18 16:19:45 -04:00
Nik Everett 98fa71868c Replace (read|write)Rescorer with (read|write)NamedWriteable 2016-04-18 16:19:45 -04:00
Nik Everett d1722c9908 Replace (read|write)Shape with (read|write)NamedWriteable 2016-04-18 16:19:45 -04:00
Nik Everett d22603831d Replace (read|write)PipelineAggregatorBuilder with (read|write)NamedWriteable 2016-04-18 16:19:45 -04:00
Nik Everett 4ba8bce3fd Replace (read|write)AggregatorBuilder with (read|write)NamedWriteable 2016-04-18 16:19:44 -04:00
Nik Everett 70d55b36e1 Replace writeOptionalQuery with writeOptionalNamedWriteable 2016-04-18 16:19:44 -04:00
Nik Everett 8cffe0fc28 Remove readOptionalQuery
Replace it with readOptionalNamedWriteable
2016-04-18 16:19:44 -04:00
Nik Everett 68b4371bd9 Make readNamedWriteable and writeNamedWriteable public
Now anyone can read or write whatever, whenever.

Closes #17682
2016-04-18 16:19:44 -04:00
Nik Everett ed7b759a45 Cut max, min, stats, and extended stats aggregations over to registerAggregation
and remove their PROTOTYPEs.

Relates to #17085
2016-04-18 11:11:28 -04:00
Nik Everett f6d141a29c Cut percentiles and percentile_ranks to registerAggregation
and remove their PROTOTYPEs.

Relates to #17085
2016-04-18 11:05:39 -04:00
Nik Everett c5bad1d93f Cut remaining pipeline aggregations registerPipelineAggregation
Relates to #17085
2016-04-18 10:56:40 -04:00
Christoph Büscher 36622ecb59 Merge pull request #17822: Use try-with-resource when creating new parser instances where possible
We should wrap newly created XContent parser in a try-with-resources block so it gets properly closed after it has been used.
2016-04-18 16:38:56 +02:00
Christoph Büscher e06e122f9f Wrap xcontent parser creation in try-with-resource statement where possible 2016-04-18 16:13:56 +02:00
Nik Everett 08d3bf937d Cut moving_avg aggregation to registerPipelineAggregation
and remove its PROTOTYPE.

Relates to #17085
2016-04-18 09:37:07 -04:00
Nik Everett b8003de409 Cut bucket_script and bucket_selector to registerPipelineAggregation
and remove their PROTOTYPEs.

Relates to #17085
2016-04-18 09:26:04 -04:00
Christoph Büscher cdb36a2b0c Merge pull request #17417
Clean up QueryParseContext and don't hold it inside QueryRewrite/ShardContext
2016-04-18 15:13:53 +02:00
Nik Everett a9e85182f1 Cut serial_diff and cumulative_sum to registerPipelineAggregation
and remove their PROTOTYPEs.

Relates to #17085
2016-04-18 08:44:49 -04:00
Nik Everett e9fa53b87f Cut global, missing, cardinality, and value_count to registerAggregation
and remove their PROTOTYPEs.

Related to #17085
2016-04-18 08:32:24 -04:00
Christoph Büscher e7cbc55592 Cleaning up query shard context creation in AbstractQueryTestCase 2016-04-18 14:27:50 +02:00
Nik Everett 070b78517e Cut stats_bucket and extended_stats_bucket to registerPipelineAggregation
and remove their PROTOTYPE.

Relates to #17085
2016-04-18 08:19:08 -04:00
Jim Ferenczi 6e4273ae0b Merge pull request #17818 from jimferenczi/search_slow_log
Add missing index name to search slow log.
2016-04-18 12:40:53 +02:00
Danilo Vaz 2e2d8c1442 Updated copyright years to include 2016 (#17808) 2016-04-18 12:39:23 +02:00
Christoph Büscher 478b5024f2 Wrap parser creation in try-with-resources 2016-04-18 12:30:57 +02:00
Jim Ferenczi 3dc21e780b Add missing index name to search slow log.
This commits adds the index name as part of the logging message.
Closes #17025
2016-04-18 12:13:10 +02:00
Daniel Mitterdorfer b84a192884 Honor invariant Suggest.suggestions != null 2016-04-18 10:18:23 +02:00
Daniel Mitterdorfer b9faa13274 Balance request sizes in NettyHttpRequestSizeLimitIT
This test should demonstrate that a single (larger)
request is processed but on of multiple large concurrent requests
is rejected. This test broke too early under some circumstances in
network mode as the limit is quite low.

With this commit we reduce the size of the individual large
requests but issue more concurrent ones thus increasing stability
of this test.
2016-04-18 09:31:48 +02:00
Jim Ferenczi 4575d79522 Merge pull request #17776 from jimferenczi/simple_query_string_wildcard
Apply the default operator on analyzed wildcard in simple_query_string builder
2016-04-15 22:22:55 +02:00
Jim Ferenczi b4e6b63088 Apply the default operator on analyzed wildcard in simple_query_string builder:
* This is a followup from https://github.com/elastic/elasticsearch/pull/17711 where we now apply the default operator on analyzed wildcard query in query_string builder.
2016-04-15 21:56:50 +02:00
Christoph Büscher f7e79f4981 Pass down parse context instead of just parser in completion context suggester. 2016-04-15 20:51:05 +02:00
Nik Everett 65803f8abd Cut significant_terms to registerAggregation
and remove its PROTOTYPE.

Relates to #17085
2016-04-15 14:23:43 -04:00
Nik Everett d223090d7d Cut top_hits aggregation to registerAggregation
and remove its PROTOTYPE.

Relates to #17085
2016-04-15 14:15:12 -04:00