Skip to content

Commit

Permalink
Merge branch 'rename/opensearch' of github.com:opensearch-project/Ope…
Browse files Browse the repository at this point in the history
…nSearch into server/src/main/java/org/opensearch/node

Signed-off-by: Harold Wang <harowang@amazon.com>
  • Loading branch information
harold-wang committed Mar 17, 2021
2 parents 7cbbee9 + 86bb16d commit a0c411d
Show file tree
Hide file tree
Showing 137 changed files with 183 additions and 195 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
import org.apache.http.message.BasicStatusLine;
import org.apache.http.nio.entity.NByteArrayEntity;
import org.apache.lucene.util.BytesRef;
import org.elasticsearch.Build;
import org.opensearch.Build;
import org.elasticsearch.client.Request;
import org.elasticsearch.client.RequestOptions;
import org.elasticsearch.client.Response;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

package org.opensearch.client.core;

import org.elasticsearch.Build;
import org.opensearch.Build;
import org.opensearch.Version;
import org.opensearch.client.AbstractResponseTestCase;
import org.opensearch.cluster.ClusterName;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
import org.bouncycastle.openpgp.jcajce.JcaPGPObjectFactory;
import org.bouncycastle.openpgp.operator.jcajce.JcaKeyFingerprintCalculator;
import org.bouncycastle.openpgp.operator.jcajce.JcaPGPContentVerifierBuilderProvider;
import org.elasticsearch.Build;
import org.opensearch.Build;
import org.opensearch.Version;
import org.opensearch.bootstrap.JarHell;
import org.opensearch.cli.EnvironmentAwareCommand;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
import org.bouncycastle.openpgp.operator.jcajce.JcaPGPKeyPair;
import org.bouncycastle.openpgp.operator.jcajce.JcePBESecretKeyDecryptorBuilder;
import org.bouncycastle.openpgp.operator.jcajce.JcePBESecretKeyEncryptorBuilder;
import org.elasticsearch.Build;
import org.opensearch.Build;
import org.opensearch.Version;
import org.opensearch.cli.ExitCodes;
import org.elasticsearch.cli.MockTerminal;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

package org.opensearch.ingest.common;

import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.common.time.DateFormatter;
import org.elasticsearch.ingest.AbstractProcessor;
import org.elasticsearch.ingest.ConfigurationUtils;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@

package org.opensearch.ingest.common;

import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.common.Nullable;
import org.opensearch.common.time.DateFormatter;
import org.opensearch.common.util.LocaleUtils;
import org.elasticsearch.ingest.AbstractProcessor;
import org.elasticsearch.ingest.ConfigurationUtils;
import org.elasticsearch.ingest.IngestDocument;
import org.elasticsearch.ingest.Processor;
import org.opensearch.ingest.AbstractProcessor;
import org.opensearch.ingest.ConfigurationUtils;
import org.opensearch.ingest.IngestDocument;
import org.opensearch.ingest.Processor;
import org.opensearch.script.ScriptService;
import org.opensearch.script.TemplateScript;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
import com.maxmind.geoip2.record.Location;
import com.maxmind.geoip2.record.Subdivision;
import org.opensearch.OpenSearchParseException;
import org.elasticsearch.SpecialPermission;
import org.opensearch.SpecialPermission;
import org.opensearch.common.network.InetAddresses;
import org.opensearch.common.network.NetworkAddress;
import org.elasticsearch.ingest.AbstractProcessor;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@
import org.apache.lucene.expressions.js.VariableContext;
import org.apache.lucene.search.DoubleValuesSource;
import org.apache.lucene.search.SortField;
import org.elasticsearch.SpecialPermission;
import org.opensearch.SpecialPermission;
import org.opensearch.common.Nullable;
import org.elasticsearch.index.fielddata.IndexFieldData;
import org.elasticsearch.index.fielddata.IndexNumericFieldData;
import org.elasticsearch.index.mapper.DateFieldMapper;
import org.elasticsearch.index.mapper.GeoPointFieldMapper.GeoPointFieldType;
import org.elasticsearch.index.mapper.MappedFieldType;
import org.opensearch.index.fielddata.IndexFieldData;
import org.opensearch.index.fielddata.IndexNumericFieldData;
import org.opensearch.index.mapper.DateFieldMapper;
import org.opensearch.index.mapper.GeoPointFieldMapper.GeoPointFieldType;
import org.opensearch.index.mapper.MappedFieldType;
import org.opensearch.script.AggregationScript;
import org.opensearch.script.BucketAggregationScript;
import org.opensearch.script.BucketAggregationSelectorScript;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
*/
package org.opensearch.script.mustache;

import org.elasticsearch.ResourceNotFoundException;
import org.opensearch.ResourceNotFoundException;
import org.opensearch.action.admin.cluster.storedscripts.GetStoredScriptResponse;
import org.opensearch.action.bulk.BulkRequestBuilder;
import org.opensearch.action.search.SearchRequest;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.message.ParameterizedMessage;
import org.apache.logging.log4j.util.Supplier;
import org.elasticsearch.SpecialPermission;
import org.opensearch.SpecialPermission;
import org.opensearch.script.GeneralScriptException;
import org.opensearch.script.Script;
import org.opensearch.script.ScriptContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

package org.opensearch.painless;

import org.elasticsearch.SpecialPermission;
import org.opensearch.SpecialPermission;
import org.opensearch.common.settings.Settings;
import org.opensearch.painless.Compiler.Loader;
import org.opensearch.painless.lookup.PainlessLookup;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
import org.apache.lucene.search.TotalHits;
import org.apache.lucene.search.Weight;
import org.apache.lucene.util.BytesRef;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.action.search.MaxScoreCollector;
import org.opensearch.common.lucene.Lucene;
import org.opensearch.common.lucene.search.TopDocsAndMaxScore;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
import org.apache.lucene.util.BytesRef;
import org.apache.lucene.util.SetOnce;
import org.opensearch.OpenSearchException;
import org.elasticsearch.ResourceNotFoundException;
import org.opensearch.ResourceNotFoundException;
import org.opensearch.Version;
import org.opensearch.action.ActionListener;
import org.opensearch.action.get.GetRequest;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

import org.apache.lucene.search.Query;
import org.opensearch.OpenSearchException;
import org.elasticsearch.ResourceNotFoundException;
import org.opensearch.ResourceNotFoundException;
import org.opensearch.action.admin.indices.mapping.put.PutMappingRequest;
import org.opensearch.action.get.GetRequest;
import org.opensearch.action.get.GetResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

import org.apache.lucene.search.TotalHits;
import org.opensearch.OpenSearchException;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.Version;
import org.opensearch.action.ActionType;
import org.opensearch.action.ActionListener;
Expand Down Expand Up @@ -67,14 +67,8 @@
import org.elasticsearch.common.xcontent.XContentType;
import org.opensearch.index.Index;
import org.opensearch.index.engine.VersionConflictEngineException;
import org.opensearch.index.reindex.AbstractBulkByScrollRequest;
import org.opensearch.index.reindex.BulkByScrollResponse;
import org.opensearch.index.reindex.BulkByScrollTask;
import org.opensearch.index.reindex.ClientScrollableHitSource;
import org.opensearch.index.reindex.ScrollableHitSource;
import org.opensearch.index.reindex.ScrollableHitSource.Hit;
import org.opensearch.index.reindex.ScrollableHitSource.SearchFailure;
import org.opensearch.index.reindex.WorkerBulkByScrollTaskState;
import org.opensearch.index.shard.ShardId;
import org.opensearch.rest.RestStatus;
import org.opensearch.search.SearchHit;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.action.ActionFuture;
import org.opensearch.action.admin.cluster.node.tasks.cancel.CancelTasksRequest;
import org.opensearch.action.admin.cluster.node.tasks.list.ListTasksResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
package org.opensearch.index.reindex;

import org.opensearch.OpenSearchException;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.action.ActionFuture;
import org.opensearch.action.admin.cluster.node.tasks.list.ListTasksResponse;
import org.opensearch.action.admin.cluster.node.tasks.list.TaskGroup;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.apache.lucene.util.SetOnce;
import org.elasticsearch.Build;
import org.opensearch.Build;
import org.opensearch.client.Client;
import org.opensearch.cluster.metadata.IndexNameExpressionResolver;
import org.opensearch.cluster.service.ClusterService;
import org.opensearch.common.io.stream.NamedWriteableRegistry;
import org.opensearch.common.unit.TimeValue;
import org.elasticsearch.common.xcontent.NamedXContentRegistry;
import org.elasticsearch.env.Environment;
import org.elasticsearch.env.NodeEnvironment;
import org.opensearch.env.Environment;
import org.opensearch.env.NodeEnvironment;
import org.opensearch.plugins.ClusterPlugin;
import org.opensearch.plugins.Plugin;
import org.opensearch.repositories.RepositoriesService;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

package org.opensearch.systemd;

import org.elasticsearch.Build;
import org.opensearch.Build;
import org.opensearch.common.CheckedConsumer;
import org.opensearch.common.unit.TimeValue;
import org.elasticsearch.test.ESTestCase;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
import io.netty.channel.ChannelHandlerContext;
import io.netty.handler.codec.MessageToMessageDecoder;
import io.netty.handler.codec.http.FullHttpRequest;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;

import java.util.List;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
import io.netty.channel.ChannelHandler;
import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.SimpleChannelInboundHandler;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.http.HttpPipelinedRequest;

@ChannelHandler.Sharable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
import io.netty.util.AttributeKey;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.common.network.NetworkService;
import org.opensearch.common.settings.ClusterSettings;
import org.opensearch.common.settings.Setting;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.ChannelPromise;
import org.opensearch.OpenSearchException;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.common.bytes.BytesReference;
import org.opensearch.common.bytes.ReleasableBytesReference;
import org.opensearch.common.lease.Releasables;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
import io.netty.channel.Channel;
import io.netty.channel.ChannelFuture;
import io.netty.channel.ChannelPromise;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.action.ActionListener;
import org.opensearch.common.Nullable;
import org.opensearch.common.bytes.BytesReference;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.message.ParameterizedMessage;
import org.elasticsearch.ExceptionsHelper;
import org.opensearch.ExceptionsHelper;
import org.opensearch.Version;
import org.opensearch.cluster.node.DiscoveryNode;
import org.opensearch.common.SuppressForbidden;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
Expand All @@ -17,7 +17,7 @@
* under the License.
*/

package org.elasticsearch;
package org.opensearch;

/**
* Provides a static final field that can be used to check if assertions are enabled. Since this field might be used elsewhere to check if
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
Expand All @@ -17,13 +17,12 @@
* under the License.
*/

package org.elasticsearch;
package org.opensearch;

import org.opensearch.common.Booleans;
import org.opensearch.common.io.FileSystemUtils;
import org.opensearch.common.io.stream.StreamInput;
import org.opensearch.common.io.stream.StreamOutput;
import org.opensearch.Version;

import java.io.IOException;
import java.net.URL;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
Expand All @@ -17,7 +17,7 @@
* under the License.
*/

package org.elasticsearch;
package org.opensearch;

import com.fasterxml.jackson.core.JsonParseException;
import org.apache.logging.log4j.LogManager;
Expand All @@ -28,7 +28,7 @@
import org.opensearch.action.ShardOperationFailedException;
import org.opensearch.common.Nullable;
import org.opensearch.common.util.concurrent.EsRejectedExecutionException;
import org.elasticsearch.index.Index;
import org.opensearch.index.Index;
import org.opensearch.rest.RestStatus;

import java.io.IOException;
Expand Down
14 changes: 6 additions & 8 deletions server/src/main/java/org/opensearch/OpenSearchException.java
Original file line number Diff line number Diff line change
Expand Up @@ -736,8 +736,8 @@ private enum OpenSearchExceptionHandle {
org.opensearch.index.snapshots.IndexShardSnapshotFailedException::new, 0, UNKNOWN_VERSION_ADDED),
DFS_PHASE_EXECUTION_EXCEPTION(org.opensearch.search.dfs.DfsPhaseExecutionException.class,
org.opensearch.search.dfs.DfsPhaseExecutionException::new, 1, UNKNOWN_VERSION_ADDED),
EXECUTION_CANCELLED_EXCEPTION(org.elasticsearch.common.util.CancellableThreads.ExecutionCancelledException.class,
org.elasticsearch.common.util.CancellableThreads.ExecutionCancelledException::new, 2, UNKNOWN_VERSION_ADDED),
EXECUTION_CANCELLED_EXCEPTION(org.opensearch.common.util.CancellableThreads.ExecutionCancelledException.class,
org.opensearch.common.util.CancellableThreads.ExecutionCancelledException::new, 2, UNKNOWN_VERSION_ADDED),
MASTER_NOT_DISCOVERED_EXCEPTION(org.opensearch.discovery.MasterNotDiscoveredException.class,
org.opensearch.discovery.MasterNotDiscoveredException::new, 3, UNKNOWN_VERSION_ADDED),
ELASTICSEARCH_SECURITY_EXCEPTION(org.opensearch.OpenSearchSecurityException.class,
Expand Down Expand Up @@ -770,8 +770,8 @@ private enum OpenSearchExceptionHandle {
org.opensearch.cluster.routing.IllegalShardRoutingStateException::new, 17, UNKNOWN_VERSION_ADDED),
BROADCAST_SHARD_OPERATION_FAILED_EXCEPTION(org.opensearch.action.support.broadcast.BroadcastShardOperationFailedException.class,
org.opensearch.action.support.broadcast.BroadcastShardOperationFailedException::new, 18, UNKNOWN_VERSION_ADDED),
RESOURCE_NOT_FOUND_EXCEPTION(org.elasticsearch.ResourceNotFoundException.class,
org.elasticsearch.ResourceNotFoundException::new, 19, UNKNOWN_VERSION_ADDED),
RESOURCE_NOT_FOUND_EXCEPTION(org.opensearch.ResourceNotFoundException.class,
org.opensearch.ResourceNotFoundException::new, 19, UNKNOWN_VERSION_ADDED),
ACTION_TRANSPORT_EXCEPTION(org.opensearch.transport.ActionTransportException.class,
org.opensearch.transport.ActionTransportException::new, 20, UNKNOWN_VERSION_ADDED),
ELASTICSEARCH_GENERATION_EXCEPTION(org.opensearch.OpenSearchGenerationException.class,
Expand Down Expand Up @@ -875,8 +875,8 @@ private enum OpenSearchExceptionHandle {
org.opensearch.cluster.IncompatibleClusterStateVersionException::new, 75, UNKNOWN_VERSION_ADDED),
RECOVERY_ENGINE_EXCEPTION(org.opensearch.index.engine.RecoveryEngineException.class,
org.opensearch.index.engine.RecoveryEngineException::new, 76, UNKNOWN_VERSION_ADDED),
UNCATEGORIZED_EXECUTION_EXCEPTION(org.elasticsearch.common.util.concurrent.UncategorizedExecutionException.class,
org.elasticsearch.common.util.concurrent.UncategorizedExecutionException::new, 77, UNKNOWN_VERSION_ADDED),
UNCATEGORIZED_EXECUTION_EXCEPTION(org.opensearch.common.util.concurrent.UncategorizedExecutionException.class,
org.opensearch.common.util.concurrent.UncategorizedExecutionException::new, 77, UNKNOWN_VERSION_ADDED),
TIMESTAMP_PARSING_EXCEPTION(org.opensearch.action.TimestampParsingException.class,
org.opensearch.action.TimestampParsingException::new, 78, UNKNOWN_VERSION_ADDED),
ROUTING_MISSING_EXCEPTION(org.opensearch.action.RoutingMissingException.class,
Expand Down Expand Up @@ -948,8 +948,6 @@ private enum OpenSearchExceptionHandle {
ReplicationOperation.RetryOnPrimaryException::new, 117, UNKNOWN_VERSION_ADDED),
ELASTICSEARCH_TIMEOUT_EXCEPTION(org.opensearch.OpenSearchTimeoutException.class,
org.opensearch.OpenSearchTimeoutException::new, 118, UNKNOWN_VERSION_ADDED),
ELASTICSEARCH_TIMEOUT_EXCEPTION(org.opensearch.OpenSearchTimeoutException.class,
org.opensearch.OpenSearchTimeoutException::new, 118, UNKNOWN_VERSION_ADDED),
QUERY_PHASE_EXECUTION_EXCEPTION(org.opensearch.search.query.QueryPhaseExecutionException.class,
org.opensearch.search.query.QueryPhaseExecutionException::new, 119, UNKNOWN_VERSION_ADDED),
REPOSITORY_VERIFICATION_EXCEPTION(org.opensearch.repositories.RepositoryVerificationException.class,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
*/
package org.opensearch;

import org.elasticsearch.ExceptionsHelper;
import org.opensearch.common.io.stream.StreamInput;
import org.opensearch.rest.RestStatus;

Expand Down
Loading

0 comments on commit a0c411d

Please sign in to comment.