Commit Graph

24251 Commits

Author SHA1 Message Date
Mike McCandless 5eb66e3378 Mark Scandinavian analysis components as multi term aware 2016-08-24 19:50:25 -04:00
Mike McCandless 7492300544 Remove now unused Store.renameFile, and obsolete commented out code 2016-08-24 18:20:30 -04:00
Jack Conradson 3deea3dbde Made for/each break tests more robust in Painless. 2016-08-24 15:17:18 -07:00
Mike McCandless 0ccfe69789 Upgrade to Lucene 6.2.0 2016-08-24 17:26:28 -04:00
Jack Conradson c60885b5d4 Fix break bug in for/foreach loops. 2016-08-24 14:25:54 -07:00
Igor Motov b36fbc4452 Add support for parameters to the script ingest processor
The script processor should support `params` to be consistent with all other script consumers.
2016-08-24 16:49:48 -04:00
Jim Ferenczi 9bedbbaa6a Fixed doc links 2016-08-24 22:37:59 +02:00
Nicholas Knize 9eb63fb885 Refactor GeoPointFieldMapperLegacy and Legacy BBox query helpers
This is a house cleaning commit that refactors GeoPointFieldMapperLegacy to LegacyGeoPointFieldMapper for consistency with Legacy Numerics and IP field mappers.

IndexedGeoBoundingBoxQuery and InMemoryGeoBoundingBoxQuery are also deprecated and refactored as Legacy classes.
2016-08-24 14:40:25 -05:00
Jim Ferenczi 50b47aa930 Merge pull request #20026 from jimferenczi/disable_stored_fields
Add the ability to disable the retrieval of the stored fields entirely
2016-08-24 21:30:47 +02:00
Ryan Ernst acbece5b55 Merge pull request #20134 from rjernst/plugin_run_config
Build: Allow plugin to set run configuration distro to zip
2016-08-24 08:49:13 -07:00
Jim Ferenczi 4682fc34ae Add the ability to disable the retrieval of the stored fields entirely
This change adds a special field named _none_ that allows to disable the retrieval of the stored fields in a search request or in a TopHitsAggregation.

To completely disable stored fields retrieval (including disabling metadata fields retrieval such as _id or _type) use _none_ like this:

````
POST _search
{
   "stored_fields": "_none_"
}
````
2016-08-24 16:40:08 +02:00
Clinton Gormley 9cce45d4af Add cloud to S3/EC2 plugin docs 2016-08-24 15:38:43 +02:00
Simon Willnauer c499427166 Use _refresh instead of reading from Translog in the RT GET case (#20102)
Today we do a lot of accounting inside the engine to maintain locations
of documents inside the transaction log. This is only needed to ensure
we can return the documents source from the engine if it hasn't been refreshed.
Aside of the added complexity to be able to read from the currently writing translog,
maintainance of pointers into the translog this also caused inconsistencies like different values
of the `_ttl` field if it was read from the tlog or not. TermVectors are totally different if
the document is fetched from the tranlog since copy fields are ignored etc.

This chance will simply call `refresh` if the documents latest version is not in the index. This
streamlines the semantics of the `_get` API and allows for more optimizations inside the engine
and on the transaction log. Note: `_refresh` is only called iff the requested document is not refreshed
yet but has recently been updated or added.

#Relates to #19787
2016-08-24 15:30:08 +02:00
Clinton Gormley abc025e18b Fixed the reindex_rethrottle REST tests
The API was renamed from reindex.rethrottle to reindex_rethrottle
2016-08-24 14:55:02 +02:00
Clinton Gormley 336ec0ac9a Renamed REST spec reindex.rethrottle to reindex_rethrottle
There is already a reindex method, so reindex can't
also be used as a namespace.
2016-08-24 13:30:48 +02:00
Simon Willnauer 1b1a1acad8 Don't index the `_version` field (#20132)
The `_version` field doesn't allow to be searched anyway since it's
set `IndexOptions#NONE` for it instead.
2016-08-24 10:04:27 +02:00
Adrien Grand 5d6c9b0745 Fix RAM usage estimation of LiveVersionMap. #20123
I was writing tests for RAM usage estimation of LiveVersionMap and found a
couple issues:
 - The BytesRef objects used as uids were oversized since they were created
   via `new BytesRef(CharSequence)` which creates a `byte[]` whose size is 3x
   the length of the provided char sequence. Given that our uids are most of
   times ASCII sequences, this is a waste of memory.
 - `VersionValue` was using `translogLocation.size` instead of
   `translogLocation.ramBytesUsed()` for RAM estimation, which is completely
   unrelated to the memory footprint of the `Translog.Location` object.

In particular, the latter issue could cause RAM usage estimation to be
significantly overestimated, especially on large documents.

I also added tests for ram accounting.
2016-08-24 09:54:06 +02:00
Jason Tedor 5e6eb987bc Correct Vagrant boxes memory allocation
This commit corrects the memory allocation to the boxes uses for the
Vagrant tests to actually be 3 GB (really, this is just an OCD-driven
commit).
2016-08-23 23:12:24 -04:00
Ryan Ernst 81aa67f9d5 Build: Allow plugin to set run configuration distro to zip
This was previously broken because run and integTest used the same
configuration name. This change makes the configuration name prefixed by
the task the cluster is created for.
2016-08-23 16:12:35 -07:00
Nik Everett e55581bb67 Give vagrant test boxes 3gb of ram
Now that Elasticsearch defaults to 2gb heaps those boxes need more ram,
especially opensuse-13 for some reason. It has failed to run the
packaging tests ever since the change.....
2016-08-23 14:54:40 -04:00
Jason Tedor 90c2aae28b Remove minimum master nodes bootstrap docs
The minimum master nodes bootstrap check was removed in
069fc22696 but the docs were left behind.
This commit removes these stale docs.

Relates #20127
2016-08-23 14:31:58 -04:00
ddddn 6228b002c5 Update index_.asciidoc (#20125) 2016-08-23 20:08:52 +02:00
Nik Everett 5b34bec92a Add deprecation warnings to docs for geohash
Relates to #20126
2016-08-23 13:43:35 -04:00
Nik Everett 3b8701199f Fix packaging tests to test upgrading on disk groovy script 2016-08-23 11:55:11 -04:00
Lee Hinman 3298a4ed38 Revert "Merge remote-tracking branch 'dakrone/exclude-numerics-from-all'"
This reverts commit 514585290c, reversing
changes made to 8563c8d897.
2016-08-23 09:24:33 -06:00
Nicholas Knize 8234fad9ca Deprecate geohash parameters for geo_point parser
This commit deprecates all geohash parameters in the geo_point field parser.
2016-08-23 09:19:21 -05:00
Nicholas Knize 28ed0e7abf Deprecate optimize_bbox on geodistance queries
Deprecates the optimize_bbox parameter on geodistance queries. This has no longer been needed since version 2.2 because lucene geo distance queries (postings and LatLonPoint) already optimize by bounding box.
2016-08-23 09:14:54 -05:00
Nik Everett e22074c97f Add description to task in vagrant build 2016-08-23 09:58:32 -04:00
Daniel Mitterdorfer c13513ed61 Allow to enable annotation processing explicitly (#20117)
In 1e91f3b we disabled annotation processors globally. However, some
project like JMH need annotation processing, so we add an ability to
selectively enabled annotation processing for certain projects by
setting an external property in the corresponding Gradle build script.

Note that `javac` would allow to set a specific annotation processor
with the command line option `-processor`. However, due to a bug in
Gradle we we cannot use this option and need to enable all annotation
processors.
2016-08-23 15:15:22 +02:00
Simon Willnauer d685847b73 Use `refresh=true` in mapping/fields examples (#20120)
Fix field examples to make documents actually visible

This commit adds refresh calls to field examples an removes not working
`_routing` and `_field_names` script access.

Closes #20118
2016-08-23 13:32:14 +02:00
Michael McCandless 668dac722a Don't suppress AlreadyClosedException (#19975)
Catching and suppressing AlreadyClosedException from Lucene is dangerous because it can mean there is a bug in ES since ES should normally guard against invoking Lucene classes after they were closed.

I reviewed the cases where we catch AlreadyClosedException from Lucene and removed the ones that I believe are not needed, or improved comments explaining why ACE is OK in that case.

I think (@s1monw can you confirm?) that holding the engine's readLock means IW will not be closed, except if disaster strikes (failEngine) at which point I think it's fine to see the original ACE in the logs?

Closes #19861
2016-08-23 12:37:38 +02:00
Masaru Hasegawa f3cddef61e Merge pull request #20046 from masaruh/same_shard_host_setting
Move cluster.routing.allocation.same_shard.host setting to new settings infrastructure
2016-08-23 11:34:59 +09:00
Jack Conradson 131e370a16 Make Painless the default scripting language.
Closes #20017
2016-08-22 17:38:02 -07:00
Lee Hinman 514585290c Merge remote-tracking branch 'dakrone/exclude-numerics-from-all' 2016-08-22 12:36:25 -06:00
Thiago Souza 8563c8d897 Merge pull request #20042 from tsouza/fix/issue-19364
Use internal from/to when creating InternalDateRange.Bucket
2016-08-22 14:38:13 -03:00
Munish Goyal f9c17dd976 Correct sentence (#20088) 2016-08-22 16:20:14 +02:00
Simon Willnauer 29336b231b Add ref-counting to SearchContext to prevent accessing already closed readers (#20095)
When a SearchContext is closed it's reader / searcher reference is closed too.
If this happens while a search is accessing it's reader reference it can lead
to an unexpected `AlreadyClosedException` or worst case, an already closed MMapDirectory
is access causing a `SIGSEV` like in #20008 (even though the window for this is very small).

SearchContext can be closed concurrently if:
 * an index is deleted / removed from the node
 * a search context is idle for too long and is cleaned by the reaper
 * an explicit freeContext message is received

This change adds reference counting to the SearchContext base class and it's used
inside SearchService each time the context is accessed.

Closes #20008
2016-08-22 15:41:05 +02:00
Ali Beyad 3d7daa1a5a Removes the whitespace between the # (to comment out) and (#20094)
the setting in elasticsearch.yml, so that when a user uncomments
out a setting by just removing the #, the setting actually
takes effect. Before, it was very easy to uncomment out a
setting by just removing the #, leaving a single whitespace
character before the setting name, which would cause the
setting to not get picked up by Elasticsearch.

Closes #20090
2016-08-22 09:03:34 -04:00
Jim Ferenczi 8136c91cf0 Merge pull request #20096 from jimferenczi/index_mapper_dynamic
Fix docs stating that index.mapper.dynamic can be set for all node in the elasticsearch.yml file.
2016-08-22 10:51:12 +02:00
Jim Ferenczi 4bee565535 Fix docs stating that index.mapper.dynamic can be set for all nodes in the elasticsearch.yml file. This is not supported in 5.x (index settings cannot be set at the cluster level) and should be replace with a template for all indices. 2016-08-22 10:20:43 +02:00
Masaru Hasegawa c7e36536f6 Move cluster.routing.allocation.same_shard.host setting to new settings infrastructure
Fixes #20045
2016-08-22 11:07:42 +09:00
Ryan Ernst 6ed83ce36a Merge pull request #20072 from rjernst/remove_index_template_filter
Plugins: Remove IndexTemplateFilter
2016-08-19 21:13:20 -07:00
Ryan Ernst e7393529b1 Merge branch 'master' into remove_index_template_filter 2016-08-19 21:14:12 -07:00
Ryan Ernst 1a7a9d3c62 Merge pull request #20071 from rjernst/pull_shards_allocator
Plugins: Switch custom ShardsAllocators to pull based model
2016-08-19 20:55:31 -07:00
Ryan Ernst 3a9055b55d Merge pull request #20073 from rjernst/deguice_indices_service
Deguice IndicesService
2016-08-19 20:47:07 -07:00
Lee Hinman b6ec1ae6eb Rework documentation example for _all to be less ambigious with numerics 2016-08-19 16:44:38 -06:00
Lee Hinman d7e516c0b4 Default `include_in_all` for numeric-like types to false
This includes:

- All regular numeric types such as int, long, scaled-float, double, etc
- IP addresses
- Dates
- Geopoints and Geoshapes

Relates to #19784
2016-08-19 15:50:38 -06:00
Jason Tedor 6cda12871c Merge pull request #20083 from jasontedor/improve-startup-exception
Improve startup exception
2016-08-19 16:44:41 -04:00
Ali Beyad 1c9b64e09a Adds ignoreUnavailable option to the snapshot status API (#20066)
Adds ignoreUnavailable to the snapshot status API to be consistent
with the get snapshots API which has a similar parameter. If
ignoreUnavailable is set to true, then the snapshot status request
will ignore any snapshots that were not found in the repository,
instead of throwing a SnapshotMissingException.

Closes #18522
2016-08-19 16:19:56 -04:00
Jason Tedor c3849d9e7d Add print stack trace override to StartupException
StartupException overrides Throwable#printStackTrace(PrintStream) but
not Throwable#printStackTrace(PrintWriter). The former override is used
when the JVM terminates with an exception, but the latter override can
be used in some logging frameworks when rendering an exception (e.g.,
log4j). This commit adds an override for the latter, with the behavior
for the two overrides being the same.
2016-08-19 15:10:54 -04:00