Skip to content

Commit bcdab8f

Browse files
Removing few lingering Elasticsearch strings in the repo (#6)
* Removing few lingering Elasticsearch strings in the repo Signed-off-by: Sarat Vemulapalli <vemulapallisarat@gmail.com>
1 parent f97f5d0 commit bcdab8f

File tree

8 files changed

+16
-16
lines changed

8 files changed

+16
-16
lines changed

.eclipseformat.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
22
<profiles version="17">
3-
<profile kind="CodeFormatterProfile" name="Elasticsearch" version="17">
3+
<profile kind="CodeFormatterProfile" name="OpenSearch" version="17">
44
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_ellipsis" value="insert"/>
55
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations" value="insert"/>
66
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression" value="do not insert"/>

.github/draft-release-notes-config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# The overall template of the release notes
22
template: |
3-
Compatible with Elasticsearch (**set version here**).
3+
Compatible with OpenSearch (**set version here**).
44
$CHANGES
55
66
# Setting the formatting and sorting for the release notes body

.github/workflows/CI.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ jobs:
5252
5353
## The ESRestTest Client uses http by default.
5454
## Need to disable the security plugin to call the rest api over http.
55-
echo "RUN if [ -d /usr/share/elasticsearch/plugins/opendistro-anomaly-detection ]; then /usr/share/elasticsearch/bin/elasticsearch-plugin remove opendistro-anomaly-detection; fi" >> Dockerfile
55+
echo "RUN if [ -d /usr/share/opensearch/plugins/opendistro-anomaly-detection ]; then /usr/share/elasticsearch/bin/elasticsearch-plugin remove opendistro-anomaly-detection; fi" >> Dockerfile
5656
echo "ADD anomaly-detection/build/distributions/opendistro-anomaly-detection-$plugin_version.zip /tmp/" >> Dockerfile
57-
echo "RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch file:/tmp/opendistro-anomaly-detection-$plugin_version.zip" >> Dockerfile
57+
echo "RUN /usr/share/opensearch/bin/elasticsearch-plugin install --batch file:/tmp/opendistro-anomaly-detection-$plugin_version.zip" >> Dockerfile
5858
5959
docker build -t odfe-ad:test .
6060
echo "imagePresent=true" >> $GITHUB_ENV

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ The Open Distro for Elasticsearch Anomaly Detection plugin enables you to levera
1212

1313
Anomaly detection is using [Random Cut Forest (RCF) algorithm](https://github.com/aws/random-cut-forest-by-aws) for detecting anomalous data points.
1414

15-
Anomaly detections run a scheduled job based on [job-scheduler](https://github.com/opendistro-for-elasticsearch/job-scheduler).
15+
Anomaly detections run a scheduled job based on [job-scheduler](https://github.com/opensearch-project/job-scheduler).
1616

17-
You should use anomaly detection plugin with the same version of [Open Distro Alerting plugin](https://github.com/opendistro-for-elasticsearch/alerting). You can also create a monitor based on the anomaly detector. A scheduled monitor run checks the anomaly detection results regularly and collects anomalies to trigger alerts based on custom trigger conditions.
17+
You should use anomaly detection plugin with the same version of [OpenSearch Alerting plugin](https://github.com/opensearch-project/alerting). You can also create a monitor based on the anomaly detector. A scheduled monitor run checks the anomaly detection results regularly and collects anomalies to trigger alerts based on custom trigger conditions.
1818

1919
## Current Limitations
2020
* We will continuously add new unit test cases, but we don't have 100% unit test coverage for now. This is a great area for developers from the community to contribute and help improve test coverage.
@@ -82,7 +82,7 @@ The **test runner JVM** will start suspended and wait for a debugger to attach t
8282

8383
### Advanced: Launching multi node clusters locally
8484

85-
Sometimes you need to launch a cluster with more than one Elasticsearch server process.
85+
Sometimes you need to launch a cluster with more than one OpenSearch server process.
8686

8787
You can do this by running `./gradlew run -PnumNodes=<numberOfNodesYouWant>`
8888

src/main/java/com/amazon/opendistroforelasticsearch/ad/transport/handler/AnomalyIndexHandler.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public class AnomalyIndexHandler<T extends ToXContentObject> {
7070
/**
7171
* Abstract class for index operation.
7272
*
73-
* @param client client to Elasticsearch query
73+
* @param client client to OpenSearch query
7474
* @param settings accessor for node settings.
7575
* @param threadPool used to invoke specific threadpool to execute
7676
* @param indexName name of index to save to
@@ -184,15 +184,15 @@ void saveIteration(IndexRequest indexRequest, String detectorId, Iterator<TimeVa
184184
.<IndexResponse>wrap(
185185
response -> { LOG.debug(String.format(Locale.ROOT, SUCCESS_SAVING_MSG, detectorId)); },
186186
exception -> {
187-
// Elasticsearch has a thread pool and a queue for write per node. A thread
187+
// OpenSearch has a thread pool and a queue for write per node. A thread
188188
// pool will have N number of workers ready to handle the requests. When a
189189
// request comes and if a worker is free , this is handled by the worker. Now by
190190
// default the number of workers is equal to the number of cores on that CPU.
191191
// When the workers are full and there are more write requests, the request
192192
// will go to queue. The size of queue is also limited. If by default size is,
193193
// say, 200 and if there happens more parallel requests than this, then those
194194
// requests would be rejected as you can see OpenSearchRejectedExecutionException.
195-
// So OpenSearchRejectedExecutionException is the way that Elasticsearch tells us that
195+
// So OpenSearchRejectedExecutionException is the way that OpenSearch tells us that
196196
// it cannot keep up with the current indexing rate.
197197
// When it happens, we should pause indexing a bit before trying again, ideally
198198
// with randomized exponential backoff.

src/main/java/com/amazon/opendistroforelasticsearch/ad/util/ClientUtil.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ public boolean hasRunningQuery(AnomalyDetector detector) {
247247

248248
/**
249249
* Cancel long running query for given detectorId
250-
* @param client Elasticsearch client
250+
* @param client OpenSearch client
251251
* @param detectorId Anomaly Detector Id
252252
* @param LOG Logger
253253
*/

src/main/java/com/amazon/opendistroforelasticsearch/ad/util/ExceptionUtil.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@ public class ExceptionUtil {
2929
.getExceptionName(new ResourceNotFoundException("", ""));
3030

3131
/**
32-
* Elasticsearch restricts the kind of exceptions can be thrown over the wire
32+
* OpenSearch restricts the kind of exceptions can be thrown over the wire
3333
* (See OpenSearchException.OpenSearchExceptionHandle). Since we cannot
3434
* add our own exception like ResourceNotFoundException without modifying
35-
* Elasticsearch's code, we have to unwrap the remote transport exception and
35+
* OpenSearch's code, we have to unwrap the remote transport exception and
3636
* check its root cause message.
3737
*
3838
* @param exception exception thrown locally or over the wire

src/main/resources/plugin-descriptor.properties

+3-3
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ description=${project.description}
1818

1919
version=${project.version}
2020

21-
name=${elasticsearch.plugin.name}
21+
name=${opensearch.plugin.name}
2222

23-
classname=${elasticsearch.plugin.classname}
23+
classname=${opensearch.plugin.classname}
2424

2525
java.version=1.8
2626

27-
elasticsearch.version=${elasticsearch.version}
27+
opensearch.version=${opensearch.version}

0 commit comments

Comments
 (0)