diff --git a/build.gradle b/build.gradle index 4c55216..6604dd6 100644 --- a/build.gradle +++ b/build.gradle @@ -16,33 +16,24 @@ buildscript { repositories { mavenCentral() - maven { - name 'sonatype-snapshots' - url "https://oss.sonatype.org/content/repositories/snapshots/" - } - jcenter() } dependencies { - classpath "org.elasticsearch.gradle:build-tools:7.12.1" - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4" + classpath "org.elasticsearch.gradle:build-tools:7.15.0" } } apply plugin: 'java' apply plugin: 'elasticsearch.esplugin' -apply plugin: 'com.jfrog.bintray' +apply plugin: 'elasticsearch.yaml-rest-test' repositories { - maven { - name 'bintray-babayotakun-russianmorphology' - url "https://dl.bintray.com/babayotakun/russianmorphology" - } flatDir { dirs 'libs' } + mavenCentral() } -version = '7.12.1' +version = '7.15.0' esplugin { description 'English and Russian Morphology for ElasticSearch.' @@ -53,43 +44,19 @@ esplugin { } esplugin.version = version -dependencies { - compile "org.apache.lucene.morphology:russian:1.5" - compile "org.apache.lucene.morphology:english:1.5" - compile "org.apache.lucene.morphology:morph:1.5" +configurations { + yamlRestTestRuntimeOnly.extendsFrom testRuntimeOnly + restTestSpecs } -// publishing { -// publications { -// DefaultPublication(MavenPublication) { -// groupId 'org.elasticsearch' -// artifactId 'elasticsearch-analysis-morphology' -// from components.java -// artifact javadocJar -// artifact sourcesJar -// artifact bundlePlugin -// } -// } -// } - - -// Only needed if we publish to bintray -if (project.hasProperty('bintrayUser')) { - - bintray { - user = project.property('bintrayUser') - key = project.property('bintrayApiKey') - pkg { - repo = 'elasticsearch-plugins' - name = 'elasticsearch-analysis-morphology' - } - publications = ['DefaultPublication'] - } +dependencies { + testRuntimeOnly 'org.apache.logging.log4j:log4j-core:2.11.1' + yamlRestTestRuntimeOnly 'org.apache.logging.log4j:log4j-core:2.11.1' + implementation "org.apache.lucene.morphology:russian:1.5" + implementation "org.apache.lucene.morphology:english:1.5" + implementation "org.apache.lucene.morphology:morph:1.5" } -// TODO: temporary workaround until it's fixed in elasticsearch -validateNebulaPom.enabled = false - project.licenseFile = project.rootProject.file('LICENSE.txt') project.noticeFile = project.rootProject.file('NOTICE.txt') diff --git a/gradle.properties b/gradle.properties new file mode 100644 index 0000000..e5ef272 --- /dev/null +++ b/gradle.properties @@ -0,0 +1 @@ +org.gradle.jvmargs='-Dfile.encoding=UTF-8' diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index e6fc1b1..36ea3d1 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,4 +1,4 @@ -distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStorePath=wrapper/dists diff --git a/src/test/java/org/elasticsearch/plugin/analysis/morphology/AnalysisMorphologyRestIT.java b/src/yamlRestTest/java/org/elasticsearch/plugin/analysis/morphology/AnalysisMorphologyRestIT.java similarity index 100% rename from src/test/java/org/elasticsearch/plugin/analysis/morphology/AnalysisMorphologyRestIT.java rename to src/yamlRestTest/java/org/elasticsearch/plugin/analysis/morphology/AnalysisMorphologyRestIT.java diff --git a/src/test/resources/rest-api-spec/test/analysis-morphology/10_analyze.yml b/src/yamlRestTest/resources/rest-api-spec/test/analysis-morphology/10_analyze.yml similarity index 100% rename from src/test/resources/rest-api-spec/test/analysis-morphology/10_analyze.yml rename to src/yamlRestTest/resources/rest-api-spec/test/analysis-morphology/10_analyze.yml diff --git a/src/test/resources/rest-api-spec/test/analysis-morphology/5_plugin_version.yml b/src/yamlRestTest/resources/rest-api-spec/test/analysis-morphology/5_plugin_version.yml similarity index 100% rename from src/test/resources/rest-api-spec/test/analysis-morphology/5_plugin_version.yml rename to src/yamlRestTest/resources/rest-api-spec/test/analysis-morphology/5_plugin_version.yml