Commit Graph

15467 Commits

Author SHA1 Message Date
Simon Willnauer ed5f6e5a0c Remove cyclic dependencies between IndexService and FieldData / BitSet caches
Adds a listeners to each of the caches that allows us to remove the dependency on IndexService which is cyclic since
the IndexService depends on both of these caches. This cyclic dependency makes
testing the indiviual parts very hard and is only added for the sake of
incrementing some stats.
2015-09-08 13:06:32 +02:00
Boaz Leskes a2f94f2e2f move ZenDiscovery.rejoin to protected
So we can override it from tests and plugins.
2015-09-08 11:02:29 +02:00
Ryan Ernst 6b88093f78 Add back filtering for build properties, and remove unused resource
file.
2015-09-08 01:15:46 -07:00
Ryan Ernst 1b99b1d8b4 Remove unnecessary maven resources config 2015-09-07 22:50:01 -07:00
Ryan Ernst bcc4175b53 Build: Move resources to their proper location
We have a a number of resources in the java source tree, mostly for
tests. This change moves them to their proper location.
2015-09-07 19:45:08 -07:00
Ryan Ernst 1ff49eb8de Settings: Remove environment from transport client
Transport clients run embedded within external applications, so
elasticsearch should not be doing anything with the filesystem, as there
is not elasticsearch home.

This change makes a number of cleanups to the internal API for loading
settings and creating an environment. The loadFromConfig option was
removed, since it was always true except for tests. We now always
attempt to load settings from config a file when an environment is
created. The prepare methods were also simplified so there is now
prepareSettingsAndEnvironment which nodes use, and prepareSettings which
the transport client uses. I also attempted to improve the tests, but
there is a still a lot of follow up work to do there.

closes #13155
2015-09-07 17:26:41 -07:00
Clinton Gormley 2c20658204 Docs: Added deprecation notice for _timestamp and _ttl 2015-09-07 21:16:19 +02:00
Clinton Gormley 8aba6ce93a Docs: Improved the date histogram docs for time_zone and offset 2015-09-07 19:54:00 +02:00
Martijn van Groningen 11c87106ce docs: inner hits is no longer experimental 2015-09-07 16:58:46 +02:00
Adrien Grand 4173b00241 Merge pull request #13310 from jpountz/remove/count_scan
Remove the scan and count search types.
2015-09-07 16:21:14 +02:00
Jason Tedor a6ffe8f6d5 Remove and forbid use of com.google.common.base.Strings
This commit removes and now forbids all uses of
com.google.common.base.Strings across the codebase.

For uses of com.google.common.base.Strings.isNullOrEmpty, use
org.elasticsearch.common.Strings.isNullOrEmpty.

For uses of com.google.common.base.Strings.padStart use
org.elasticsearch.common.Strings.padStart.

For uses of com.google.common.base.Strings.nullToEmpty use
org.elasticsearch.common.Strings.coalesceToEmpty.

Relates #13224
2015-09-07 09:40:14 -04:00
David Pilato ab904059c8 [build] move heapdump to target/heapdump dir
Each time you run mvn test, you end up creating a `.logs` empty dir.

Instead of writing for each plugin in the `./logs` dir, I'd recommend writing this in `./target/heapdump`.

This dir is cleanup automatically when you run `mvn clean`.
2015-09-07 15:26:45 +02:00
Adrien Grand 0c26e7cd83 Remove the scan and count search types.
These search types have been deprecated in 2.1 and 2.0 respectively, and will
be removed in 3.0.
2015-09-07 15:18:45 +02:00
Nik Everett 8d3df330ff [test] Add test for package reinstall after remove
Closes #13286
2015-09-07 09:07:07 -04:00
Britta Weber c5cb559014 Merge pull request #13341 from brwe/shard-not-available-broadcast-replication
fix exception handling for unavailable shards in broadcast replicatio…
2015-09-07 14:47:55 +02:00
Britta Weber 41a2375c9e fix exception handling for unavailable shards in broadcast replication action
Before #13068 refresh and flush ignored all exceptions that matched
TransportActions.isShardNotAvailableException(e) and this should not change.
In addition, refresh and flush which are based on broadcast replication
might now get UnavailableShardsException from TransportReplicationAction if a shard
is unavailable and this is not caught by TransportActions.isShardNotAvailableException(e).
This must be ignored as well.
2015-09-07 14:47:28 +02:00
Britta Weber 972c1cc398 [test] remove timeout test 0s for flush and refresh - we decided we use 1m timeout
see #13238
2015-09-07 14:39:59 +02:00
Jason Tedor 5e36c91e8c Merge pull request #13349 from jasontedor/predicate-out-with-the-old-in-with-the-new
Remove and forbid the use of com.google.common.base.Predicate(s)?
2015-09-06 07:24:26 -04:00
Jason Tedor 8a3411e5e4 Remove and forbid the use of com.google.common.base.Predicate(s)?
This commit removes and now forbids all uses of
com.google.common.base.Predicate and com.google.common.base.Predicates
across the codebase. This is one of the many steps in the eventual
removal of Guava as a dependency. This was enabled by #13314.

Relates #13224
2015-09-06 07:20:24 -04:00
xuzha e69551d8df This commit remove the block for user to set invalid Signer Type.
Instead of throw an exception, this change log a warning message
and accept any signer type.
2015-09-05 22:57:05 -07:00
Jason Tedor 4be8b3f429 Merge pull request #13355 from jasontedor/objects-out-with-the-old-in-with-the-new
Remove and forbid use of com.google.common.base.Objects
2015-09-05 09:12:23 -04:00
Jason Tedor 14e4882425 Remove and forbid use of com.google.common.base.Objects
This commit removes and now forbids all uses of
com.google.common.base.Objects across the codebase. This is a small
step in the eventual removal of Guava as a dependency.

Relates #13224
2015-09-05 08:52:30 -04:00
Lee Hinman 8a06fef019 Merge remote-tracking branch 'dakrone/delete-closed-shadow-indices' 2015-09-04 15:39:40 -06:00
Lee Hinman 701dc340a8 Allow deleting closed indices with shadow replicas
Previously we skip deleting the index store for indices on a shared
filesystem, because we don't want to delete the data when the shard is
relocating around the cluster. This adds a flag to the
`deleteIndexStore` method signifying that the index is closed and that
we should allow deleting the contents even if it is on a shared
filesystem.

Includes a unit test for the IndicesService.canDeleteIndexContents and
integration tests ensure a closed shadow replica index deletes files
correctly.

Resolves #13297
2015-09-04 15:28:18 -06:00
Martijn van Groningen ac951e86d1 fix npe 2015-09-04 22:03:25 +02:00
Zachary Tong 5aa9639034 Add missing License header 2015-09-04 15:50:02 -04:00
Nik Everett 72ea5327aa Merge pull request #13287 from nik9000/package_upgrade_test
Test upgrading from an older version
2015-09-04 15:35:36 -04:00
Nik Everett 04d254e571 [test] Documentation for packaging tests 2015-09-04 15:34:10 -04:00
Zachary Tong 1f8702e38e Merge pull request #13128 from polyfractal/feature/stats_pipeline
Aggregations: Add stats_bucket / extended_stats_bucket pipeline aggs
2015-09-04 15:25:43 -04:00
Zachary Tong 397d5beae1 Aggregations: Add stats_bucket / extended_stats_bucket pipeline aggregations
These are the complements to the stats/extended_stats metric aggregations, and can be used
to calculate a variety of statistics over buckets
2015-09-04 15:23:48 -04:00
Jason Tedor 242c8c0465 Merge pull request #13353 from jasontedor/remove-use-of-underscore-as-an-identifier
Remove use of underscore as an identifier
2015-09-04 14:27:35 -04:00
Jason Tedor f4213614c3 Remove use of underscore as an identifier
As a refinement to Project Coin (JEP-213, JDK-8042880), Java 9 is going
to disallow the use of ‘_’ as a one-character identifier. This will be
done by adding ‘_’ as a keyword to the Java language (JDK-8065599).
Currently, uses of ‘_’ as a one-character identifier are warnings in
the Java 8 compiler. This commit removes all uses of ‘_’ as a
one-character identifier from the codebase.
2015-09-04 14:18:30 -04:00
Jason Tedor b98cd5f611 Should be asserting JVM plugins do not have a URL 2015-09-04 12:13:54 -04:00
javanna 873d69f157 Query DSL: span_containing and span_within override default boost coming from lucene
SpanContainingQueryParser and SpanWithinQueryParser always set the boost to the parsed lucene query, even if it is the default one. The default boost of the main query though is the boost coming from the inner little query, value that we end up overriding all the time. We should instead set the boost to the main query only if it differs from the default, to mimic lucene's behaviour.

Relates to #13272
Closes #13339
2015-09-04 17:31:49 +02:00
Adrien Grand 37c90b1047 Tests: Add back BitSetFilterCacheTests which was lost on #13308 2015-09-04 17:13:50 +02:00
javanna bd5613708e Query DSL: simple_query_string overrides boost coming from lucene
SimpleQueryStringParser applies whatever boost the query holds, even if the default 1, to the query obtained from parsing of the query string. that might contain its boost, for instance if it resolved to a simple query like term (single term query against a single field). We should rather multiply the existing boost with the boost set to the query, same as we do in query_string

Relates to #13272
Closes #13331
2015-09-04 16:07:38 +02:00
Jason Tedor cb12107123 Fix Javadoc for o.e.c.r.RoutingNodes.UnassignedIterator#remove 2015-09-04 09:08:12 -04:00
Zachary Tong ab2f295c16 Collect and pass unparsed params to buildFactory(), replacing doParse()
doParse() was supposed to allow aggs to perform extra parsing.  Unfortunately, this forced the
parser to carry instance-level state, which would carry-over and "corrupt" any other aggs of the
same type in the same query.

Instead, we are now collecting all unknown params and pasing them as a Map<String, Object>
to buildFactory().  The agg may then parse them and instantiate a factory.  Each param the
agg uses, it should unset from the unusedParams object.

After building the factory, the parser verifies that unusedParams is empty.  If it is not empty,
an exception is raised so the user knows they provided unknown params.

Fixes #13337
2015-09-04 08:35:13 -04:00
Tanguy Leroux 41aa1a7a71 Manually synchronize listeners when iterating on them in InternalClusterInfoService 2015-09-04 13:50:57 +02:00
Adrien Grand 216335abcf Tests: @AwaitsFix on PercentilesBucketIT.testNested. 2015-09-04 10:47:30 +02:00
Adrien Grand 42f178e8c2 Merge pull request #13308 from jpountz/fix/deprecations_5.3
Fix deprecations introduced by the upgrade to Lucene 5.3
2015-09-04 10:16:23 +02:00
Adrien Grand 4f5591be8d Fix deprecations introduced by the upgrade to Lucene 5.3
This changes construction of Phrase and Boolean queries to use the builder,
and replaces BitDocIdSetFilter with BitSetProducer for nested and parent/child
queries. I had to remove the ParentIdsFilter for the case when there was a
single parent as it was using the source of BitSets for parents as a regular
Filter, which is not possible anymore now. I don't think this is an issue since
this case rarely occurs, and the alternative logic for when there are several
matching parent ids should not be much worse.
2015-09-04 10:16:01 +02:00
Zachary Tong c5b39ce85e [DOCS] Fix broken inter-page link 2015-09-03 23:17:01 -04:00
Zachary Tong f8ad4da61c Merge pull request #13186 from polyfractal/feature/percentile_pipeline
Aggregations: Add percentiles_bucket pipeline aggregation
2015-09-03 22:36:40 -04:00
Zachary Tong 1016734b4c Aggregations: Add percentiles_bucket pipeline aggregations
This pipeline will calculate percentiles over a set of sibling buckets.  This is an exact
implementation, meaning it needs to cache a copy of the series in memory and sort it to determine
the percentiles.

This comes with a few limitations: to prevent serializing data around, only the requested percentiles
are calculated (unlike the TDigest version, which allows the java API to ask for any percentile).
It also needs to store the data in-memory, resulting in some overhead if the requested series is
very large.
2015-09-03 22:24:14 -04:00
Nicholas Knize 17460ae92d Refactor ignore_malformed and coerce from geo_point field type to mapper
This commit moves ignore_malformed and coerce options from the GeoPointFieldType to the Builder in GeoPointFieldMapper. This makes these options consistent with other types in 2.0.
2015-09-03 17:02:51 -05:00
David Pilato b2c584b21d Remove jmeter files
Follow up for #13317.
2015-09-03 22:36:50 +02:00
David Pilato 6319f383c4 Remove assembly files in core
Closes #13317.
2015-09-03 22:36:50 +02:00
Robert Muir 35aafdf7b7 Merge pull request #13328 from rmuir/remove_broadcast_check
Remove broadcast address check.
2015-09-03 16:15:26 -04:00
Robert Muir 529ad7fe79 Remove broadcast address check.
This was supposed to just help the user, in case they misconfigured something.
Broadcast is an ipv4 only thing, the only way you can really detect its a broadcast
address, is to look and see if an interface has that address as its broadcast address.

But we cannot trust that container interfaces won't have a crazy setup...

Closes #13327
2015-09-03 16:01:14 -04:00