mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-07 05:28:34 +00:00
Backport of #47374 Changed the Grok class to use searchInterruptible(...) instead of search(...) otherwise we can't interrupt long running matching via the thread watch dog. Joni now also provides another way to interrupt long running matches. By invoking the interrupt() method on the Matcher. We need then to refactor the watch thread dog to keep track of Matchers instead of Threads, but it is a better way of doing this, since interrupting would be more direct (not every 30k iterations) and efficient (checking a volatile field). This work needs to be done in a follow up.
33 lines
1.1 KiB
Groovy
33 lines
1.1 KiB
Groovy
/*
|
|
* Licensed to Elasticsearch under one or more contributor
|
|
* license agreements. See the NOTICE file distributed with
|
|
* this work for additional information regarding copyright
|
|
* ownership. Elasticsearch licenses this file to you under
|
|
* the Apache License, Version 2.0 (the "License"); you may
|
|
* not use this file except in compliance with the License.
|
|
* You may obtain a copy of the License at
|
|
*
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
*
|
|
* Unless required by applicable law or agreed to in writing,
|
|
* software distributed under the License is distributed on an
|
|
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
* KIND, either express or implied. See the License for the
|
|
* specific language governing permissions and limitations
|
|
* under the License.
|
|
*/
|
|
|
|
dependencies {
|
|
compile 'org.jruby.joni:joni:2.1.29'
|
|
// joni dependencies:
|
|
compile 'org.jruby.jcodings:jcodings:1.0.44'
|
|
|
|
testCompile(project(":test:framework")) {
|
|
exclude group: 'org.elasticsearch', module: 'elasticsearch-grok'
|
|
}
|
|
}
|
|
|
|
forbiddenApisMain {
|
|
replaceSignatureFiles 'jdk-signatures'
|
|
}
|