From 33faf5ec70a29177eb50eccded4e2f103f938fc8 Mon Sep 17 00:00:00 2001 From: Andy Bristol Date: Thu, 7 Sep 2017 14:47:52 -0700 Subject: [PATCH] forbid ICU Collator creation with default locale (#26476) --- plugins/analysis-icu/build.gradle | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/plugins/analysis-icu/build.gradle b/plugins/analysis-icu/build.gradle index 2a8905e080f..123db9fc4a5 100644 --- a/plugins/analysis-icu/build.gradle +++ b/plugins/analysis-icu/build.gradle @@ -22,6 +22,12 @@ esplugin { classname 'org.elasticsearch.plugin.analysis.icu.AnalysisICUPlugin' } +forbiddenApis { + signatures += [ + "com.ibm.icu.text.Collator#getInstance() @ Don't use default locale, use getInstance(ULocale) instead" + ] +} + dependencies { compile "org.apache.lucene:lucene-analyzers-icu:${versions.lucene}" compile 'com.ibm.icu:icu4j:59.1'