From d268d82d85e1c82e4b4248b37c6bb9d34d2df3c3 Mon Sep 17 00:00:00 2001 From: Rabi Panda Date: Thu, 11 Mar 2021 12:45:20 -0800 Subject: [PATCH] [Rename] refactor `o.e.usage` package in server module. (#269) Refactor the `org.elasticsearch.usage` package in the server module to rename it to `org.opensearch.usage`. Signed-off-by: Rabi Panda --- server/src/main/java/org/opensearch/action/ActionModule.java | 2 +- .../admin/cluster/node/usage/TransportNodesUsageAction.java | 2 +- server/src/main/java/org/opensearch/rest/RestController.java | 2 +- .../org/{elasticsearch => opensearch}/usage/UsageService.java | 2 +- .../src/test/java/org/opensearch/rest/RestControllerTests.java | 2 +- .../java/org/opensearch/rest/RestHttpResponseHeadersTests.java | 2 +- .../rest/action/admin/indices/RestValidateQueryActionTests.java | 2 +- .../{elasticsearch => opensearch}/usage/UsageServiceTests.java | 2 +- .../java/org/elasticsearch/test/rest/RestActionTestCase.java | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) rename server/src/main/java/org/{elasticsearch => opensearch}/usage/UsageService.java (99%) rename server/src/test/java/org/{elasticsearch => opensearch}/usage/UsageServiceTests.java (99%) diff --git a/server/src/main/java/org/opensearch/action/ActionModule.java b/server/src/main/java/org/opensearch/action/ActionModule.java index 3c1317c9c92..4de1cd2f6d5 100644 --- a/server/src/main/java/org/opensearch/action/ActionModule.java +++ b/server/src/main/java/org/opensearch/action/ActionModule.java @@ -395,7 +395,7 @@ import org.opensearch.rest.action.search.RestSearchAction; import org.opensearch.rest.action.search.RestSearchScrollAction; import org.opensearch.tasks.Task; import org.opensearch.threadpool.ThreadPool; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import java.util.ArrayList; import java.util.Collections; diff --git a/server/src/main/java/org/opensearch/action/admin/cluster/node/usage/TransportNodesUsageAction.java b/server/src/main/java/org/opensearch/action/admin/cluster/node/usage/TransportNodesUsageAction.java index 10b4ea9fc65..0d32dbf740c 100644 --- a/server/src/main/java/org/opensearch/action/admin/cluster/node/usage/TransportNodesUsageAction.java +++ b/server/src/main/java/org/opensearch/action/admin/cluster/node/usage/TransportNodesUsageAction.java @@ -30,7 +30,7 @@ import org.elasticsearch.common.io.stream.StreamOutput; import org.elasticsearch.search.aggregations.support.AggregationUsageService; import org.opensearch.threadpool.ThreadPool; import org.elasticsearch.transport.TransportService; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import java.io.IOException; import java.util.List; diff --git a/server/src/main/java/org/opensearch/rest/RestController.java b/server/src/main/java/org/opensearch/rest/RestController.java index 4c361ad21e6..7865168ce07 100644 --- a/server/src/main/java/org/opensearch/rest/RestController.java +++ b/server/src/main/java/org/opensearch/rest/RestController.java @@ -38,7 +38,7 @@ import org.elasticsearch.common.xcontent.XContentType; import org.elasticsearch.core.internal.io.Streams; import org.elasticsearch.http.HttpServerTransport; import org.elasticsearch.indices.breaker.CircuitBreakerService; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import java.io.ByteArrayOutputStream; import java.io.IOException; diff --git a/server/src/main/java/org/elasticsearch/usage/UsageService.java b/server/src/main/java/org/opensearch/usage/UsageService.java similarity index 99% rename from server/src/main/java/org/elasticsearch/usage/UsageService.java rename to server/src/main/java/org/opensearch/usage/UsageService.java index 8567866e909..9f914d52081 100644 --- a/server/src/main/java/org/elasticsearch/usage/UsageService.java +++ b/server/src/main/java/org/opensearch/usage/UsageService.java @@ -36,7 +36,7 @@ * under the License. */ -package org.elasticsearch.usage; +package org.opensearch.usage; import org.opensearch.action.admin.cluster.node.usage.NodeUsage; import org.opensearch.rest.BaseRestHandler; diff --git a/server/src/test/java/org/opensearch/rest/RestControllerTests.java b/server/src/test/java/org/opensearch/rest/RestControllerTests.java index 3cabf375072..d3212166306 100644 --- a/server/src/test/java/org/opensearch/rest/RestControllerTests.java +++ b/server/src/test/java/org/opensearch/rest/RestControllerTests.java @@ -43,7 +43,7 @@ import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService; import org.elasticsearch.test.ESTestCase; import org.elasticsearch.test.client.NoOpNodeClient; import org.elasticsearch.test.rest.FakeRestRequest; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import org.junit.After; import org.junit.Before; diff --git a/server/src/test/java/org/opensearch/rest/RestHttpResponseHeadersTests.java b/server/src/test/java/org/opensearch/rest/RestHttpResponseHeadersTests.java index 2496acb270d..78e410a7c7a 100644 --- a/server/src/test/java/org/opensearch/rest/RestHttpResponseHeadersTests.java +++ b/server/src/test/java/org/opensearch/rest/RestHttpResponseHeadersTests.java @@ -29,7 +29,7 @@ import org.elasticsearch.indices.breaker.HierarchyCircuitBreakerService; import org.elasticsearch.test.ESTestCase; import org.elasticsearch.test.rest.FakeRestChannel; import org.elasticsearch.test.rest.FakeRestRequest; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import java.util.ArrayList; import java.util.Arrays; diff --git a/server/src/test/java/org/opensearch/rest/action/admin/indices/RestValidateQueryActionTests.java b/server/src/test/java/org/opensearch/rest/action/admin/indices/RestValidateQueryActionTests.java index 7dc329d85e7..b8b0abb4985 100644 --- a/server/src/test/java/org/opensearch/rest/action/admin/indices/RestValidateQueryActionTests.java +++ b/server/src/test/java/org/opensearch/rest/action/admin/indices/RestValidateQueryActionTests.java @@ -41,7 +41,7 @@ import org.elasticsearch.test.rest.FakeRestChannel; import org.elasticsearch.test.rest.FakeRestRequest; import org.opensearch.threadpool.TestThreadPool; import org.opensearch.threadpool.ThreadPool; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import org.junit.AfterClass; import org.junit.Before; import org.junit.BeforeClass; diff --git a/server/src/test/java/org/elasticsearch/usage/UsageServiceTests.java b/server/src/test/java/org/opensearch/usage/UsageServiceTests.java similarity index 99% rename from server/src/test/java/org/elasticsearch/usage/UsageServiceTests.java rename to server/src/test/java/org/opensearch/usage/UsageServiceTests.java index 99dc6376d68..3cbbb5152ad 100644 --- a/server/src/test/java/org/elasticsearch/usage/UsageServiceTests.java +++ b/server/src/test/java/org/opensearch/usage/UsageServiceTests.java @@ -17,7 +17,7 @@ * under the License. */ -package org.elasticsearch.usage; +package org.opensearch.usage; import org.elasticsearch.client.node.NodeClient; import org.opensearch.rest.BaseRestHandler; diff --git a/test/framework/src/main/java/org/elasticsearch/test/rest/RestActionTestCase.java b/test/framework/src/main/java/org/elasticsearch/test/rest/RestActionTestCase.java index 77c37684883..affade02538 100644 --- a/test/framework/src/main/java/org/elasticsearch/test/rest/RestActionTestCase.java +++ b/test/framework/src/main/java/org/elasticsearch/test/rest/RestActionTestCase.java @@ -32,7 +32,7 @@ import org.opensearch.tasks.Task; import org.opensearch.tasks.TaskListener; import org.elasticsearch.test.ESTestCase; import org.elasticsearch.test.client.NoOpNodeClient; -import org.elasticsearch.usage.UsageService; +import org.opensearch.usage.UsageService; import org.junit.After; import org.junit.Before;