4742 Commits

Author SHA1 Message Date
uboness
f430953ca1 Changed hunspell token filter factory to use "dedup = true" by default 2013-05-01 23:57:14 +02:00
Martijn van Groningen
0d3b7871df Added support for sort_mode avg for sorting by geo_distance.
Closes #2962
2013-05-01 12:53:31 +02:00
Martijn van Groningen
c21ab1a9cf Return proper response code for delete by query api in the case of failures.
Closes #2963
2013-05-01 11:53:40 +02:00
Igor Motov
6437c51501 Improve stability of SimpleRecoveryLocalGatewayTests
Fixed testX and testSingleNodeNoFlush by specifying mapping on index creation instead of using dynamic mapping. Dynamic mapping is updated on the cluster level asynchronously and if mapping changes are not applied to the cluster state before node is closed, these changes are not be available after node restart. While data added in the test is preserved, due to absence of mapping, the test still fails. This is a known issue that we are not planning to fix at the moment.
2013-04-30 12:11:30 -04:00
Alexander Reelsen
a694e97ab9 Support source include/exclude for realtime GET
Currently realtime GET does not take source includes/excludes into account.
This patch adds support for the source field mapper includes/excludes
when getting an entry from the transaction log. Even though it introduces
a slight performance penalty, it now adheres to the defined configuration
instead of returning all source data when a realtime get is done.
2013-04-30 17:48:03 +02:00
Alexander Reelsen
d5f4c8230d XContentMapValues.filter now works with nested arrays
The filter method of XContentMapValues actually filtered out nested
arrays/lists completely due to a bug in the filter method, which threw
away all data inside of such an array.

Closes #2944
This bug was a follow up problem, because of the filtering of nested arrays
in case source exclusion was configured.
2013-04-30 17:33:09 +02:00
Simon Willnauer
773ea0306b Fail will IAE if a numeric field is used for the anaysis endpoint.
Analysing a numeric field will return UTF-16 representations of
of Lucenes numeric prefix terms. Those terms are meaningless in general
unless used for lookups in the lucene index. Passing a numeric field
to the analysis action is most likely a bug.

Closes #2953 #2952
2013-04-30 16:07:11 +02:00
Simon Willnauer
8c6ba59b83 Upgrade Lucene Version to 4.2. The latest Elasticsearch version must
use the latest Lucene version as specified in o.e.common.lucene.Lucene
and must be upgraded with each lucene release.

This commit adds an assert that fails once the actual lucene version
that is used is higher than the current releases version.
2013-04-30 14:06:57 +02:00
Simon Willnauer
42b9674d0c added simple test for numeric match query 2013-04-30 13:53:49 +02:00
Shay Banon
6c3bb4dcdd move to 1.0.0.Beta1 snap 2013-04-29 13:51:09 +02:00
Shay Banon
cb75ce0caa release 0.90.0 GA 2013-04-29 13:41:43 +02:00
Shay Banon
9ded2405a0 Use Lucene Version that was used to create the index in Analysis
Lucene ships with a version constant that is mainly used to provide consistent behaviour across lucene release versions. Lucene's Analysis capabilities are commonly applied at index and search time such that the search-time behaviour should be identical to the index-time behaviour in most of the cases. Currently ElasticSearch always uses the latest version from Lucene which can break backwards compatibility with the index for users that rely on behaviour that changed in new Lucene version.

Users should always use the version the index was created with unless it's explicitly configured.

closes #2945
2013-04-29 13:18:51 +02:00
Simon Willnauer
bd7ff6946e Added X Versions of NGramTokenFilter and NGramTokenizer to ElasticSearch. These versions
don't produce broken positions anymore and prevent certain highlighter bugs that fail with
StringArrayOutOfBoundsExceptions as in #2931

This commit breaks backwards compatibility in terms of highlighting when NGramTokenFilter is used.
The highlighter will highlight the entire terms as produced by the tokenizer instead of the individual
sub-gram. To do sub-gram highlighting, the ngram tokenizer should be used. This behavior was based on
broken NGramTokenFilter behavior which will be fixed in Lucene 4.4 but was ported in this commit
to elasticsearch 0.90. The broken behavior can still be used if a version < LUCENE_42 is used
in the token filter mapping.

Closes #2931
2013-04-27 16:48:25 +02:00
Shay Banon
f09ad507a4 open context stats
- rename to open_contexts from open, we might have other open stats in the future related to search (lucene index searchers?)
- add a test to verify it works
2013-04-27 15:09:47 +02:00
Simon Willnauer
8a7f81104f Remove XSimpleFragmentsBuilder and XScoreOrderFragmentsBuilder since the only difference
to the lucene version is that `discreteMultiValueHighlighting` does default to `true`. Yet
we set this anyway in the HighlightingPhase such that the classes are obsolet.
2013-04-26 20:04:38 +02:00
Simon Willnauer
355f80adc9 Added temporary fix for LUCENE-4899 where FastVectorHighlihgter failed with StringIndexOutOfBoundsException
if a single highlight phrase or term was greater than the fragCharSize producing negative string offsets

The fixed BaseFragListBuilder was added as XSimpleFragListBuilder which triggers an assert once Elasticsearch
upgrades to Lucene 4.3
2013-04-26 19:48:48 +02:00
Simon Willnauer
2ed2fab904 Add assert that fails one Elasticsearch upgrades to Lucene 4.3 in order to remove the duplicated class 2013-04-26 19:16:21 +02:00
Alexander Reelsen
90353ceb79 Fixing possible NoClassDefFoundError when trying to load nonexisting classes
In order to handle exceptions correctly, when classes are not found, one
needs to handle ClassNotFoundException as well as NoClassDefFoundError
in order to be sure to have caught every possible case. We did not cater
for the latter in ImmutableSettings yet.

This fix is just executing the same logic for both exceptions instead of
simply bubbling up NoClassDefFoundError.
2013-04-26 10:34:10 +02:00
Alexander Reelsen
22e25cc165 Added stolen time to OsStats output 2013-04-25 10:46:24 +02:00
Shay Banon
c4968d7d65 no longer support snappy... 2013-04-25 09:38:58 +02:00
Igor Motov
982b570037 Fix serialization of sync/async replication type 2013-04-25 08:25:31 +02:00
Martijn van Groningen
dd12e0b86c If searchContext not set, abort parsing and throw ISE 2013-04-24 10:24:15 +02:00
Simon Willnauer
c884304753 Fall back to local statistics if global statistics are not availalbe for a field or term
Closes #2926
2013-04-23 13:32:35 +02:00
Simon Willnauer
f372f7c109 Cut over StringScriptDataComparator to use BytesRef instead of Strings
Closes #2920
2013-04-23 13:29:19 +02:00
Simon Willnauer
7a36bed031 Remove per-doc ord collector callback infavor of an iterator 2013-04-23 10:35:40 +02:00
Martijn van Groningen
c390f9b1a9 Added more test assertions 2013-04-19 22:16:42 +02:00
Simon Willnauer
7ea6cd6888 use Double/Float.compare for stable and correct float sort order 2013-04-19 21:40:01 +02:00
Clinton Gormley
1483a3a0e5 Added tests for multi_match with minimum_should_match 2013-04-19 21:40:01 +02:00
Clinton Gormley
e508b27203 Apply minimum_should_match to inner clauses of multi_match query
When specifying minimum_should_match in a multi_match query it was being applied
to the outer bool query instead of to each of the inner field-specific bool queries.

Closes #2918
2013-04-19 21:39:54 +02:00
Simon Willnauer
3ab56e16b7 Support empty string in FSTBytesAtomicFieldData 2013-04-19 12:49:06 +02:00
Simon Willnauer
a1c62759c9 remove size bound from cache recycler for performance reasons 2013-04-19 12:36:12 +02:00
Simon Willnauer
2d13aa29f8 s/ES.RECYCLE/es.cache.recycle 2013-04-19 11:48:28 +02:00
Simon Willnauer
05b6c46bec allow CacheRecycler to be cleared via the REST API 2013-04-19 11:45:33 +02:00
Simon Willnauer
79db1bfbf0 make object caching optional 2013-04-18 19:14:19 +02:00
Florian Schilling
54cb4b9615 # Response for Cluster Settings Update API
If cluster settings are update the REST API returns the accepted values. For
example, updating the `cluster.routing.allocation.disable_allocation` via
cluster settings:

```curl -XPUT http://localhost:9200/_cluster/settings -d '{
    "transient":{
        "cluster.routing.allocation.disable_allocation":"true"
    }
}'```

will respond:

```{
    "persistent":{},
    "transient":{
        "cluster.routing.allocation.disable_allocation":"true"
    }
}```

Closes #2907
2013-04-18 11:34:58 +02:00
Lucas Ward
99c101c37e If a value/field is a Calendar, it will be converted to a Date using getTime()
Closes #2911
2013-04-18 10:57:08 +02:00
Shay Banon
0eb298fe64 use more aggressive concurrency levels for CHM
- long running ones with high update rates
- also expose a *system* property of es.useConcurrentHashMapV8 to use the new non blocking Java8 CHM impl
2013-04-17 14:28:38 -07:00
Shay Banon
271305d5eb Search Stats: Add current open searches
closes #2906
2013-04-16 18:08:57 -07:00
Simon Willnauer
efc9e8fe7b only return primary if it is active in PlainOperationRounting
Closes #2896
2013-04-16 17:20:22 +02:00
Martijn van Groningen
bcc16654d2 Better error messaging when postings_format can be resolved or when a custom postings_format type can't be instantiated.
Relates to #2893
2013-04-16 16:29:54 +02:00
Martijn van Groningen
9a1c03408b Added support for the _cache and _cache_key options to the has_child and has_parent filters.
Closes #2900
2013-04-16 14:42:45 +02:00
Florian Schilling
ef5b7412e6 Allow PolygonBuilder to create polygons with hole
Closes #2899
2013-04-16 11:22:48 +02:00
Simon Willnauer
30f9f278c3 Added UNICODE_CHARACTER_CLASS support to Regex flags. This flag is only supported in Java7 and is ignored if set on a java 6 JVM
Closes #2895
2013-04-16 10:06:53 +02:00
uboness
eb21526552 Added missing support for lat, lats, lon, lons for doc notation in scripts 2013-04-13 13:58:30 -07:00
uboness
20e6df9f34 Optimization in fielddata cache where ordinals are used instead of flat arrays when number of unique values is low 2013-04-13 12:42:53 -07:00
Igor Motov
e7b49d8936 Add more dynamic settings validation 2013-04-12 20:55:45 -04:00
Shay Banon
d385e1b356 Clear Cache API: Streamline option names
closes #2890
2013-04-12 15:58:24 -07:00
Shay Banon
a2d72697eb Expose field level field data statistics
closes #2889
2013-04-12 15:51:08 -07:00
David Pilato
3b7a195f6f Add toString() for FilterBuilders
Closes #2887.
2013-04-12 22:27:51 +02:00
Martijn van Groningen
bf21466291 CacheTests test fix. 2013-04-12 19:14:38 +02:00