From dfac4fc725c1f3e9875d9cd4463d040c1cf48170 Mon Sep 17 00:00:00 2001 From: Tianli Feng Date: Tue, 18 Aug 2020 12:19:40 -0700 Subject: [PATCH 1/4] Support Elasticsearch 7.9.0 --- build.gradle | 2 +- gradle.properties | 2 +- ...for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md | 4 ++++ .../jobscheduler/JobSchedulerPlugin.java | 5 ++--- 4 files changed, 8 insertions(+), 5 deletions(-) create mode 100644 release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md diff --git a/build.gradle b/build.gradle index dc8437e..4e2e090 100644 --- a/build.gradle +++ b/build.gradle @@ -15,7 +15,7 @@ buildscript { ext { - es_version = System.getProperty("es.version", "7.8.0") + es_version = System.getProperty("es.version", "7.9.0") } repositories { diff --git a/gradle.properties b/gradle.properties index 2d065e3..02ae399 100644 --- a/gradle.properties +++ b/gradle.properties @@ -13,4 +13,4 @@ # permissions and limitations under the License. # -version = 1.9.0 +version = 1.10.0 diff --git a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md new file mode 100644 index 0000000..5f58e09 --- /dev/null +++ b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md @@ -0,0 +1,4 @@ +## 2020-08-18, version 1.10.0.0 + +### New Features +* Adds support for Elasticsearch 7.9.0 - [PR #63](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/63) \ No newline at end of file diff --git a/src/main/java/com/amazon/opendistroforelasticsearch/jobscheduler/JobSchedulerPlugin.java b/src/main/java/com/amazon/opendistroforelasticsearch/jobscheduler/JobSchedulerPlugin.java index 43ce7ee..4a013b4 100644 --- a/src/main/java/com/amazon/opendistroforelasticsearch/jobscheduler/JobSchedulerPlugin.java +++ b/src/main/java/com/amazon/opendistroforelasticsearch/jobscheduler/JobSchedulerPlugin.java @@ -53,7 +53,6 @@ import java.util.HashSet; import java.util.List; import java.util.Map; -import java.util.ServiceLoader; import java.util.Set; import java.util.function.Supplier; @@ -124,9 +123,9 @@ public void onIndexModule(IndexModule indexModule) { } @Override - public void reloadSPI(ClassLoader loader) { + public void loadExtensions(ExtensionLoader loader) { - for (JobSchedulerExtension extension : ServiceLoader.load(JobSchedulerExtension.class, loader)) { + for (JobSchedulerExtension extension : loader.loadExtensions(JobSchedulerExtension.class)) { String jobType = extension.getJobType(); String jobIndexName = extension.getJobIndex(); ScheduledJobParser jobParser = extension.getJobParser(); From 656ec2c497eeb0ad8ce7ad5cddd4c4c1ad4bbe20 Mon Sep 17 00:00:00 2001 From: Tianli Feng Date: Tue, 18 Aug 2020 13:21:03 -0700 Subject: [PATCH 2/4] Update the release note --- ...ro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md index 5f58e09..cad2e6e 100644 --- a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md +++ b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md @@ -1,4 +1,4 @@ ## 2020-08-18, version 1.10.0.0 ### New Features -* Adds support for Elasticsearch 7.9.0 - [PR #63](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/63) \ No newline at end of file +* Adds support for Elasticsearch 7.9.0 - [PR #67](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/67) \ No newline at end of file From 53102e884085a325765d72677a9fed9946074785 Mon Sep 17 00:00:00 2001 From: Tianli Feng Date: Wed, 19 Aug 2020 17:20:37 -0700 Subject: [PATCH 3/4] Update the release note for 1.10.0.0 to satisfy the unified format --- ...-elasticsearch.job-scheduler.release-notes-1.10.0.0.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md index cad2e6e..5776982 100644 --- a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md +++ b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md @@ -1,4 +1,6 @@ -## 2020-08-18, version 1.10.0.0 +## 2020-08-18 Version 1.10.0.0 -### New Features -* Adds support for Elasticsearch 7.9.0 - [PR #67](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/67) \ No newline at end of file +Supported Elasticsearch version 7.9.0 + +### Maintenance +* Adds support for Elasticsearch 7.9.0 ([#67](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/67)) \ No newline at end of file From 1a3c9f94102e5ee44c831d2e9a0bf11e6d088291 Mon Sep 17 00:00:00 2001 From: Tianli Feng Date: Wed, 19 Aug 2020 17:28:15 -0700 Subject: [PATCH 4/4] Change the PR title in the release note --- ...ro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md index 5776982..55ab968 100644 --- a/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md +++ b/release-notes/opendistro-for-elasticsearch.job-scheduler.release-notes-1.10.0.0.md @@ -3,4 +3,4 @@ Supported Elasticsearch version 7.9.0 ### Maintenance -* Adds support for Elasticsearch 7.9.0 ([#67](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/67)) \ No newline at end of file +* Update JobSchedulerPlugin to conform with changes to ExtensiblePlugin interface in Elasticsearch 7.9.0 ([#67](https://github.com/opendistro-for-elasticsearch/job-scheduler/pull/67)) \ No newline at end of file