Commit Graph

22699 Commits

Author SHA1 Message Date
Robert Muir faee2323ab add array ctor refs 2016-06-12 12:53:37 -04:00
Robert Muir 5be9211761 cleanup grammar 2016-06-12 11:25:52 -04:00
Robert Muir 7c8eb184ee Merge pull request #18828 from rmuir/ownReferences
painless: method references to user functions
2016-06-12 02:23:15 -04:00
Uwe Schindler 60cc152caf Remove unused field 2016-06-11 22:34:17 +02:00
Robert Muir 5c352a063a need not be public, should not be public 2016-06-11 16:03:45 -04:00
Robert Muir 07baefac32 Add comments 2016-06-11 16:01:50 -04:00
Uwe Schindler fd9b0f9087 Remove some hardcoded strings, fix exception handling (remove rethrow), add some utility methods around the "handle$" fields 2016-06-11 21:53:15 +02:00
Robert Muir 454881eeb4 test interface default methods 2016-06-11 15:51:32 -04:00
Uwe Schindler c08b45a277 More cleanup 2016-06-11 21:20:39 +02:00
Robert Muir 65352face2 fix too long line 2016-06-11 15:04:49 -04:00
Robert Muir 592042601f def case working 2016-06-11 15:02:43 -04:00
Uwe Schindler 876f0a613e Unfuck the MethodWriter nesting. All MethodWriters should only live separately from each other, no nesting 2016-06-11 21:00:06 +02:00
Robert Muir e2f999b025 make this static final 2016-06-11 14:33:48 -04:00
Robert Muir 8d5a70200f write refs for functions 2016-06-11 14:29:15 -04:00
Robert Muir ab457be9d8 remove unnecessary semicolon and return 2016-06-11 13:48:04 -04:00
Robert Muir 0bfb166eeb merge master 2016-06-11 13:23:17 -04:00
Nik Everett 4a265d0279 Painless: Add } as a delimiter. Kindof.
Add `}` is statement delimiter but only in places where it is
otherwise a valid part of the syntax, specificall the end of a block.
We do this by matching but not consuming it. Antlr 4 doesn't have
syntax for this so we have to kind of hack it together by actually
matching the `}` and then seeking backwards in the token stream to
"unmatch" it. This looks reasonably efficient. Not perfect, but way
better than the alternatives.

I tried and rejected a few options:
1. Actually consuming the `}` and piping a boolean all through the
grammar from the last statement in a block to the delimiter. This
ended up being a rather large change and made the grammar way more
complicated.
2. Adding a semantic predicate to delimiter that just does the
lookahead. This doesn't work out well because it doesn't work (I
never figured out why) and because it generates an *amazing*
`adaptivePredict` which makes a super huge DFA. It looks super
inefficient.

Closes #18821
2016-06-11 12:51:25 -04:00
Jack Conradson c3bf3b34c2 Merge pull request #18824 from jdconrad/stubby
Add Lambda Stub Node
2016-06-10 17:43:14 -07:00
Jack Conradson e293000d8d Merge branch 'master' into stubby 2016-06-10 16:22:17 -07:00
Jack Conradson bd94c62adf Added a stub node for lambda expressions. 2016-06-10 16:18:36 -07:00
Nik Everett 387155559e Make TimeValue Writeable instead of Streamable
Writeable is better for immutable objects like TimeValue.

Switch to writeZLong which takes up less space than the original
writeLong in the majority of cases. Since we expect negative
TimeValues we shouldn't use
writeVLong.
2016-06-10 18:24:16 -04:00
Robert Muir 200af0c6a6 Merge pull request #18818 from rmuir/capturingReferences
painless: add capturing method references
2016-06-10 18:15:00 -04:00
Robert Muir 16d17351f7 don't use loadLocal, add new node to package-info 2016-06-10 17:37:57 -04:00
Robert Muir 9e0a70c4b2 Merge branch 'master' into capturingReferences 2016-06-10 17:10:56 -04:00
Jack Conradson f98be6fa06 Add functions to Painless.
Closes #18810
2016-06-10 13:59:59 -07:00
Jason Tedor 86f1bedaab Rename NettyTransportChannel#close
This commit renames the NettyTransportChannel#close method to
NettyTransportChannel#release to clarify the semantics.
2016-06-10 15:26:49 -04:00
Robert Muir edb0fd3b88 painless: add capturing method references 2016-06-10 14:24:58 -04:00
Nik Everett 25fde039fd [docs] Flow the refresh docs
They were making multiple pages but that is silly. They should all
be one page.
2016-06-10 10:42:56 -04:00
Jason Tedor 6d8692576e Mark field in ReindexSameIndexTests as final
This commit restores a final modifier on the field
AutoCreateIndex#AUTO_CREATE_INDEX that was inadvertently removed in
a25b8ee1bf.
2016-06-10 10:20:45 -04:00
Adrien Grand 44c653f5a8 Upgrade to lucene-6.1.0-snapshot-3a57bea. 2016-06-10 16:18:12 +02:00
Jason Tedor a25b8ee1bf Make random UUIDs reproducible in tests
Today we use a random source of UUIDs for assigning allocation IDs,
cluster IDs, etc. Yet, the source of randomness for this is not
reproducible in tests. Since allocation IDs end up as keys in hash maps,
this means allocation decisions and not reproducible in tests and this
leads to non-reproducible test failures. This commit modifies the
behavior of random UUIDs so that they are reproducible under tests. The
behavior for production code is not changed, we still use a true source
of secure randomness but under tests we just use a reproducible source
of non-secure randomness.

It is important to note that there is a test,
UUIDTests#testThreadedRandomUUID that relies on the UUIDs being truly
random. Thus, we have to modify the setup for this test to use a true
source of randomness. Thus, this is one test that will never be
reproducible but it is intentionally so.

Relates #18808
2016-06-10 10:18:06 -04:00
Ali Beyad 43e07c0c88 Better handling of an empty shard's segments_N file
When trying to restore a snapshot of an index created in a previous
version of Elasticsearch, it is possible that empty shards in the
snapshot have a segments_N file that has an unsupported Lucene version
and a missing checksum.  This leads to issues with restoring the
snapshot.  This commit handles this special case by avoiding a restore
of a shard that has no data, since there is nothing to restore anyway.

Closes #18707
2016-06-10 09:57:09 -04:00
Nik Everett d733fb689b Better error message when mapping configures null
Closes #18803
2016-06-10 09:43:18 -04:00
Yannick Welsch a2c506acd3 Fix sync flush total shards statistics (#18766) 2016-06-10 13:39:47 +02:00
Yannick Welsch 6ea89004cd Make IndicesClusterStateService unit testable (#17270)
Testability of ICSS is achieved by introducing interfaces for IndicesService, IndexService and IndexShard. These interfaces extract all relevant methods used by ICSS (which do not deal directly with store) and give the possibility to easily mock all the store behavior away in the tests (and cuts down on dependencies).
2016-06-10 12:47:41 +02:00
javanna 777d438f48 [TEST] use jdk-internal bundled signature (rather than the previously removed jdk-non-portable) 2016-06-10 12:46:33 +02:00
javanna 656422cff6 move shutdownNow within try block 2016-06-10 11:42:25 +02:00
javanna 3d7186c81f make DeadHostState final 2016-06-10 11:40:35 +02:00
javanna 6db90da25e [TEST] Remove usage of @SuppressForbidden due to sun HttpServer usage, resolve some violations that were hidden by it 2016-06-10 11:40:13 +02:00
javanna 432efc75fb catch Exception rather than Throwable 2016-06-10 11:39:08 +02:00
javanna 9cbfa984fa Merge branch 'master' into feature/http_client 2016-06-10 11:18:21 +02:00
Colin Goodheart-Smithe 62025d39d3 #18414 Adds aggregation profiling to the profile API
Adds aggregation profiling to the profile API
2016-06-10 09:41:29 +01:00
javanna a5e329e563 [TEST] use animalsniffer annotation @IgnoreJRERequirement (similar to @SuppressForbidden) rather than exclusion pattern 2016-06-10 10:11:21 +02:00
Colin Goodheart-Smithe 1d76177510 Adds aggregation profiling (not including reduce phase)
Add Aggregation profiling initially only be for the shard phases (i.e. the reduce phase will not be profiled in this change)

This change refactors the query profiling class to extract abstract classes where it is useful for other profiler types to share code.
2016-06-10 09:02:07 +01:00
javanna 0af9d2c767 Build: add animalsniffer to detect usage of java8 apis in client and client-sniffer 2016-06-10 09:51:47 +02:00
Jim Ferenczi 39a7bec481 Merge pull request #18782 from jimferenczi/max_slices_per_scroll
Add an index setting to limit the maximum number of slices allowed in a scroll request.
2016-06-10 09:49:03 +02:00
Jim Ferenczi 439b2a96e5 Add an index setting to limit the maximum number of slices allowed in a scroll request (default to 1024). 2016-06-10 09:43:32 +02:00
Daniel Mitterdorfer 7229c91289 Remove trace logging from NettyHttpRequestSizeLimitIT
With this commit we revert back to normal behavior as the
underlying issue has been fixed with #18627.
2016-06-10 07:46:04 +02:00
javanna 2856ab07de Build: enable dependency licenses check for client-sniffer, exclude org.elasticsearch jars from checks 2016-06-09 23:48:49 +02:00
javanna f38ce72004 make forbiddenApisTest work for client and client-sniffer 2016-06-09 23:44:34 +02:00