diff --git a/bin/service.bat b/bin/service.bat index 72062b99b7d..d4040be9b47 100644 Binary files a/bin/service.bat and b/bin/service.bat differ diff --git a/dev-tools/build_release.py b/dev-tools/build_release.py index 4402187b567..c9451498f51 100644 --- a/dev-tools/build_release.py +++ b/dev-tools/build_release.py @@ -242,7 +242,7 @@ def build_release(run_tests=False, dry_run=True, cpus=1, bwc_version=None): 'test -Dtests.jvms=%s -Des.node.mode=local' % (cpus), 'test -Dtests.jvms=%s -Des.node.mode=network' % (cpus)) if bwc_version: - print('Running Backwards compatibilty tests against version [%s]' % (bwc_version)) + print('Running Backwards compatibility tests against version [%s]' % (bwc_version)) run_mvn('clean', 'test -Dtests.filter=@backwards -Dtests.bwc.version=%s -Dtests.bwc=true -Dtests.jvms=1' % bwc_version) run_mvn('clean test-compile -Dforbidden.test.signatures="org.apache.lucene.util.LuceneTestCase\$AwaitsFix @ Please fix all bugs before release"') run_mvn('clean %s -DskipTests' % (target)) diff --git a/dev-tools/extract_party_license.rb b/dev-tools/extract_party_license.rb index e3326e66492..170006b6855 100644 --- a/dev-tools/extract_party_license.rb +++ b/dev-tools/extract_party_license.rb @@ -32,7 +32,7 @@ def all_installed_gems end all_installed_gems.select {|y| y.gem_dir.include?('vendor') }.sort {|v, u| v.name <=> u.name }.each do |x| - puts '='*80 #seperator + puts '='*80 #separator if(x.license) #ah gem has license information puts "%s,%s,%s,%s,%s"%[x.name, x.version, x.license, x.homepage, x.email] else diff --git a/dev-tools/forbidden/core-signatures.txt b/dev-tools/forbidden/core-signatures.txt index e67f95a3b24..59a4316e588 100644 --- a/dev-tools/forbidden/core-signatures.txt +++ b/dev-tools/forbidden/core-signatures.txt @@ -23,7 +23,7 @@ org.apache.lucene.index.IndexReader#decRef() org.apache.lucene.index.IndexReader#incRef() org.apache.lucene.index.IndexReader#tryIncRef() -@defaultMessage QueryWrapperFilter is cachable by default - use Queries#wrap instead +@defaultMessage QueryWrapperFilter is cacheable by default - use Queries#wrap instead org.apache.lucene.search.QueryWrapperFilter#(org.apache.lucene.search.Query) @defaultMessage Pass the precision step from the mappings explicitly instead diff --git a/docs/reference/modules/advanced-scripting.asciidoc b/docs/reference/modules/advanced-scripting.asciidoc index 99f4e122aef..4de55531697 100644 --- a/docs/reference/modules/advanced-scripting.asciidoc +++ b/docs/reference/modules/advanced-scripting.asciidoc @@ -79,7 +79,7 @@ The number of terms in a field cannot be accessed using the `_index` variable. S Term statistics for a field can be accessed with a subscript operator like this: `_index['FIELD']['TERM']`. This will never return null, even if term or field does not exist. If you do not need the term frequency, call `_index['FIELD'].get('TERM', 0)` -to avoid uneccesary initialization of the frequencies. The flag will have only +to avoid unnecessary initialization of the frequencies. The flag will have only affect is your set the `index_options` to `docs` (see <>). diff --git a/docs/reference/query-dsl/filters/geo-shape-filter.asciidoc b/docs/reference/query-dsl/filters/geo-shape-filter.asciidoc index f97e798990f..dfe06932bbd 100644 --- a/docs/reference/query-dsl/filters/geo-shape-filter.asciidoc +++ b/docs/reference/query-dsl/filters/geo-shape-filter.asciidoc @@ -18,7 +18,7 @@ as defined for the field mapping. ==== Filter Format The Filter supports two ways of defining the Filter shape, either by -providing a whole shape defintion, or by referencing the name of a shape +providing a whole shape definition, or by referencing the name of a shape pre-indexed in another index. Both formats are defined below with examples. diff --git a/docs/reference/query-dsl/queries/regexp-syntax.asciidoc b/docs/reference/query-dsl/queries/regexp-syntax.asciidoc index 178722d57ea..5563c52ba4f 100644 --- a/docs/reference/query-dsl/queries/regexp-syntax.asciidoc +++ b/docs/reference/query-dsl/queries/regexp-syntax.asciidoc @@ -189,7 +189,7 @@ negates the character class. The allowed forms are: [^-abc] # any character except '-' or 'a' or 'b' or 'c' [^abc\-] # any character except '-' or 'a' or 'b' or 'c' -Note that the dash `"-"` indicates a range of characeters, unless it is +Note that the dash `"-"` indicates a range of characters, unless it is the first character or if it is escaped with a backslash. For string `"abcd"`: diff --git a/docs/reference/query-dsl/queries/span-not-query.asciidoc b/docs/reference/query-dsl/queries/span-not-query.asciidoc index d49d3ef116a..466c0c6c7d3 100644 --- a/docs/reference/query-dsl/queries/span-not-query.asciidoc +++ b/docs/reference/query-dsl/queries/span-not-query.asciidoc @@ -30,4 +30,4 @@ The `include` and `exclude` clauses can be any span type query. The `exclude` clause is the span query whose matches must not overlap those returned. -In the above example all documents with the term hoya are filtered except the ones that have 'la' preceeding them. +In the above example all documents with the term hoya are filtered except the ones that have 'la' preceding them. diff --git a/docs/reference/search/aggregations/bucket/significantterms-aggregation.asciidoc b/docs/reference/search/aggregations/bucket/significantterms-aggregation.asciidoc index 1af12eed08b..7b5f7e63736 100644 --- a/docs/reference/search/aggregations/bucket/significantterms-aggregation.asciidoc +++ b/docs/reference/search/aggregations/bucket/significantterms-aggregation.asciidoc @@ -329,7 +329,7 @@ Google normalized distance as described in "The Google Similarity Distance", Ci ===== Which one is best? -Roughly, `mutual_information` prefers high frequent terms even if they occur also frequently in the background. For example, in an analysis of natural language text this might lead to selection of stop words. `mutual_information` is unlikely to select very rare terms like misspellings. `gnd` prefers terms with a high co-occurence and avoids selection of stopwords. It might be better suited for synonym detection. However, `gnd` has a tendency to select very rare terms that are, for example, a result of misspelling. `chi_square` and `jlh` are somewhat in-between. +Roughly, `mutual_information` prefers high frequent terms even if they occur also frequently in the background. For example, in an analysis of natural language text this might lead to selection of stop words. `mutual_information` is unlikely to select very rare terms like misspellings. `gnd` prefers terms with a high co-occurrence and avoids selection of stopwords. It might be better suited for synonym detection. However, `gnd` has a tendency to select very rare terms that are, for example, a result of misspelling. `chi_square` and `jlh` are somewhat in-between. It is hard to say which one of the different heuristics will be the best choice as it depends on what the significant terms are used for (see for example [Yang and Pedersen, "A Comparative Study on Feature Selection in Text Categorization", 1997](http://courses.ischool.berkeley.edu/i256/f06/papers/yang97comparative.pdf) for a study on using significant terms for feature selection for text classification). diff --git a/docs/reference/search/suggesters/phrase-suggest.asciidoc b/docs/reference/search/suggesters/phrase-suggest.asciidoc index d9715b24d9d..20ec442a4e4 100644 --- a/docs/reference/search/suggesters/phrase-suggest.asciidoc +++ b/docs/reference/search/suggesters/phrase-suggest.asciidoc @@ -13,7 +13,7 @@ suggestions are required in order to present to the end-user. The to select entire corrected phrases instead of individual tokens weighted based on `ngram-language` models. In practice this suggester will be able to make better decisions about which tokens to pick based on -co-occurence and frequencies. +co-occurrence and frequencies. ==== API Example diff --git a/docs/reference/setup/dir-layout.asciidoc b/docs/reference/setup/dir-layout.asciidoc index bf89ea1e775..0095f60e332 100644 --- a/docs/reference/setup/dir-layout.asciidoc +++ b/docs/reference/setup/dir-layout.asciidoc @@ -47,7 +47,7 @@ path.data: ["/mnt/first", "/mnt/second"] [[default-paths]] === Default Paths -Below are the default paths that elasticsearch will use, if not explictly changed. +Below are the default paths that elasticsearch will use, if not explicitly changed. [float] ==== deb and rpm diff --git a/docs/reference/testing/testing-framework.asciidoc b/docs/reference/testing/testing-framework.asciidoc index 7008af54931..9c50c8c20c7 100644 --- a/docs/reference/testing/testing-framework.asciidoc +++ b/docs/reference/testing/testing-framework.asciidoc @@ -208,7 +208,7 @@ As many elasticsearch tests are checking for a similar output, like the amount o `assertSecondHit()`:: Asserts the second hit hits the specified matcher `assertThirdHit()`:: Asserts the third hits hits the specified matcher `assertSearchHit()`:: Assert a certain element in a search response hits the specified matcher -`assertNoFailures()`:: Asserts that no shard failures have occured in the response +`assertNoFailures()`:: Asserts that no shard failures have occurred in the response `assertFailures()`:: Asserts that shard failures have happened during a search request `assertHighlight()`:: Assert specific highlights matched `assertSuggestion()`:: Assert for specific suggestions diff --git a/rest-api-spec/api/bulk.json b/rest-api-spec/api/bulk.json index 69bb16bce77..dff32e31f03 100644 --- a/rest-api-spec/api/bulk.json +++ b/rest-api-spec/api/bulk.json @@ -29,7 +29,7 @@ "type" : "enum", "options" : ["sync","async"], "default" : "sync", - "description" : "Explicitely set the replication type" + "description" : "Explicitly set the replication type" }, "routing": { "type" : "string", diff --git a/rest-api-spec/api/mlt.json b/rest-api-spec/api/mlt.json index bb15dc18017..898c5afcae7 100644 --- a/rest-api-spec/api/mlt.json +++ b/rest-api-spec/api/mlt.json @@ -45,7 +45,7 @@ }, "min_term_freq": { "type" : "number", - "description" : "The term frequency as percent: terms with lower occurence in the source document will be ignored" + "description" : "The term frequency as percent: terms with lower occurrence in the source document will be ignored" }, "min_word_length": { "type" : "number", diff --git a/rest-api-spec/test/cluster.reroute/11_explain.yaml b/rest-api-spec/test/cluster.reroute/11_explain.yaml index 6cab02d143f..5419acb9321 100644 --- a/rest-api-spec/test/cluster.reroute/11_explain.yaml +++ b/rest-api-spec/test/cluster.reroute/11_explain.yaml @@ -24,7 +24,7 @@ setup: - match: {explanations: []} --- -"Explain API for non-existant node & shard": +"Explain API for non-existent node & shard": - do: cluster.state: diff --git a/src/main/java/org/elasticsearch/ExceptionsHelper.java b/src/main/java/org/elasticsearch/ExceptionsHelper.java index e97eb41d0f1..552d339301e 100644 --- a/src/main/java/org/elasticsearch/ExceptionsHelper.java +++ b/src/main/java/org/elasticsearch/ExceptionsHelper.java @@ -135,7 +135,7 @@ public final class ExceptionsHelper { public static void rethrowAndSuppress(List exceptions) throws T { T main = null; for (T ex : exceptions) { - main = useOrSupress(main, ex); + main = useOrSuppress(main, ex); } if (main != null) { throw main; @@ -149,14 +149,14 @@ public final class ExceptionsHelper { public static void maybeThrowRuntimeAndSuppress(List exceptions) { T main = null; for (T ex : exceptions) { - main = useOrSupress(main, ex); + main = useOrSuppress(main, ex); } if (main != null) { throw new ElasticsearchException(main.getMessage(), main); } } - public static T useOrSupress(T first, T second) { + public static T useOrSuppress(T first, T second) { if (first == null) { return second; } else { diff --git a/src/main/java/org/elasticsearch/action/termvector/TermVectorFields.java b/src/main/java/org/elasticsearch/action/termvector/TermVectorFields.java index 2e6175ea1ef..4968f8adde8 100644 --- a/src/main/java/org/elasticsearch/action/termvector/TermVectorFields.java +++ b/src/main/java/org/elasticsearch/action/termvector/TermVectorFields.java @@ -248,7 +248,7 @@ public final class TermVectorFields extends Fields { // realloc. growBuffers(); // finally, read the values into the arrays - // curentPosition etc. so that we can just iterate + // currentPosition etc. so that we can just iterate // later writeInfos(perFieldTermVectorInput); return spare.get(); diff --git a/src/main/java/org/elasticsearch/common/Base64.java b/src/main/java/org/elasticsearch/common/Base64.java index 03cc2a46b6d..4b77e125e2a 100644 --- a/src/main/java/org/elasticsearch/common/Base64.java +++ b/src/main/java/org/elasticsearch/common/Base64.java @@ -517,7 +517,7 @@ public class Base64 { * anywhere along their length by specifying * srcOffset and destOffset. * This method does not check to make sure your arrays - * are large enough to accomodate srcOffset + 3 for + * are large enough to accommodate srcOffset + 3 for * the source array or destOffset + 4 for * the destination array. * The actual number of significant bytes in your array is @@ -1038,7 +1038,7 @@ public class Base64 { * anywhere along their length by specifying * srcOffset and destOffset. * This method does not check to make sure your arrays - * are large enough to accomodate srcOffset + 4 for + * are large enough to accommodate srcOffset + 4 for * the source array or destOffset + 3 for * the destination array. * This method returns the actual number of bytes that diff --git a/src/main/java/org/elasticsearch/common/Strings.java b/src/main/java/org/elasticsearch/common/Strings.java index 50ff848c482..99e6598d063 100644 --- a/src/main/java/org/elasticsearch/common/Strings.java +++ b/src/main/java/org/elasticsearch/common/Strings.java @@ -270,7 +270,7 @@ public class Strings { } /** - * Trim all occurences of the supplied leading character from the given String. + * Trim all occurrences of the supplied leading character from the given String. * * @param str the String to check * @param leadingCharacter the leading character to be trimmed @@ -326,7 +326,7 @@ public class Strings { } /** - * Replace all occurences of a substring within a string with + * Replace all occurrences of a substring within a string with * another string. * * @param inString String to examine diff --git a/src/main/java/org/elasticsearch/common/inject/BindingProcessor.java b/src/main/java/org/elasticsearch/common/inject/BindingProcessor.java index 899beebbe99..835c40ac90c 100644 --- a/src/main/java/org/elasticsearch/common/inject/BindingProcessor.java +++ b/src/main/java/org/elasticsearch/common/inject/BindingProcessor.java @@ -131,7 +131,7 @@ class BindingProcessor extends AbstractProcessor { return null; } - // This cast is safe after the preceeding check. + // This cast is safe after the preceding check. final BindingImpl binding; try { binding = injector.createUnitializedBinding(key, scoping, source, errors); diff --git a/src/main/java/org/elasticsearch/common/inject/assistedinject/FactoryProvider.java b/src/main/java/org/elasticsearch/common/inject/assistedinject/FactoryProvider.java index 90b0d8cdb72..dbee846f3d0 100644 --- a/src/main/java/org/elasticsearch/common/inject/assistedinject/FactoryProvider.java +++ b/src/main/java/org/elasticsearch/common/inject/assistedinject/FactoryProvider.java @@ -114,7 +114,7 @@ import java.util.Set; *

*

Backwards compatibility using {@literal @}AssistedInject

* Instead of the {@literal @}Inject annotation, you may annotate the constructed classes with - * {@literal @}{@link AssistedInject}. This triggers a limited backwards-compatability mode. + * {@literal @}{@link AssistedInject}. This triggers a limited backwards-compatibility mode. *

*

Instead of matching factory method arguments to constructor parameters using their names, the * parameters are matched by their order. The first factory method argument is diff --git a/src/main/java/org/elasticsearch/common/inject/internal/AsynchronousComputationException.java b/src/main/java/org/elasticsearch/common/inject/internal/AsynchronousComputationException.java index 880725ab1dd..2f5ee937c53 100644 --- a/src/main/java/org/elasticsearch/common/inject/internal/AsynchronousComputationException.java +++ b/src/main/java/org/elasticsearch/common/inject/internal/AsynchronousComputationException.java @@ -17,7 +17,7 @@ package org.elasticsearch.common.inject.internal; /** - * Wraps an exception that occured during a computation in a different thread. + * Wraps an exception that occurred during a computation in a different thread. * * @author Bob Lee */ diff --git a/src/main/java/org/elasticsearch/common/inject/internal/ComputationException.java b/src/main/java/org/elasticsearch/common/inject/internal/ComputationException.java index 67d5bd22d73..1244a2fd33d 100644 --- a/src/main/java/org/elasticsearch/common/inject/internal/ComputationException.java +++ b/src/main/java/org/elasticsearch/common/inject/internal/ComputationException.java @@ -17,7 +17,7 @@ package org.elasticsearch.common.inject.internal; /** - * Wraps an exception that occured during a computation. + * Wraps an exception that occurred during a computation. */ public class ComputationException extends RuntimeException { diff --git a/src/main/java/org/elasticsearch/common/inject/internal/Errors.java b/src/main/java/org/elasticsearch/common/inject/internal/Errors.java index 1f2114905ea..c1134702521 100644 --- a/src/main/java/org/elasticsearch/common/inject/internal/Errors.java +++ b/src/main/java/org/elasticsearch/common/inject/internal/Errors.java @@ -35,7 +35,7 @@ import java.util.*; /** * A collection of error messages. If this type is passed as a method parameter, the method is - * considered to have executed succesfully only if new errors were not added to this collection. + * considered to have executed successfully only if new errors were not added to this collection. *

*

Errors can be chained to provide additional context. To add context, call {@link #withSource} * to create a new Errors instance that contains additional context. All messages added to the diff --git a/src/main/java/org/elasticsearch/common/inject/internal/ProviderMethod.java b/src/main/java/org/elasticsearch/common/inject/internal/ProviderMethod.java index 6872fa3f037..2c5282387af 100644 --- a/src/main/java/org/elasticsearch/common/inject/internal/ProviderMethod.java +++ b/src/main/java/org/elasticsearch/common/inject/internal/ProviderMethod.java @@ -94,7 +94,7 @@ public class ProviderMethod implements ProviderWithDependencies { } try { - // We know this cast is safe becase T is the method's return type. + // We know this cast is safe because T is the method's return type. @SuppressWarnings({"unchecked", "UnnecessaryLocalVariable"}) T result = (T) method.invoke(instance, parameters); return result; diff --git a/src/main/java/org/elasticsearch/common/inject/spi/ElementVisitor.java b/src/main/java/org/elasticsearch/common/inject/spi/ElementVisitor.java index 8998779f270..1cf17af035f 100644 --- a/src/main/java/org/elasticsearch/common/inject/spi/ElementVisitor.java +++ b/src/main/java/org/elasticsearch/common/inject/spi/ElementVisitor.java @@ -64,7 +64,7 @@ public interface ElementVisitor { V visit(MembersInjectorLookup lookup); /** - * Visit an error message and the context in which it occured. + * Visit an error message and the context in which it occurred. */ V visit(Message message); diff --git a/src/main/java/org/elasticsearch/common/inject/spi/InjectionPoint.java b/src/main/java/org/elasticsearch/common/inject/spi/InjectionPoint.java index aafc77d29f0..0ea766be228 100644 --- a/src/main/java/org/elasticsearch/common/inject/spi/InjectionPoint.java +++ b/src/main/java/org/elasticsearch/common/inject/spi/InjectionPoint.java @@ -89,18 +89,18 @@ public final class InjectionPoint { } private ImmutableList> forMember(Member member, TypeLiteral type, - Annotation[][] paramterAnnotations) { + Annotation[][] parameterAnnotations) { Errors errors = new Errors(member); - Iterator annotationsIterator = Arrays.asList(paramterAnnotations).iterator(); + Iterator annotationsIterator = Arrays.asList(parameterAnnotations).iterator(); List> dependencies = Lists.newArrayList(); int index = 0; for (TypeLiteral parameterType : type.getParameterTypes(member)) { try { - Annotation[] parameterAnnotations = annotationsIterator.next(); - Key key = Annotations.getKey(parameterType, member, parameterAnnotations, errors); - dependencies.add(newDependency(key, Nullability.allowsNull(parameterAnnotations), index)); + Annotation[] paramAnnotations = annotationsIterator.next(); + Key key = Annotations.getKey(parameterType, member, paramAnnotations, errors); + dependencies.add(newDependency(key, Nullability.allowsNull(paramAnnotations), index)); index++; } catch (ErrorsException e) { errors.merge(e.getErrors()); diff --git a/src/main/java/org/elasticsearch/common/inject/spi/Message.java b/src/main/java/org/elasticsearch/common/inject/spi/Message.java index fd088f51e3b..029e3c62e02 100644 --- a/src/main/java/org/elasticsearch/common/inject/spi/Message.java +++ b/src/main/java/org/elasticsearch/common/inject/spi/Message.java @@ -29,7 +29,7 @@ import java.util.List; import static com.google.common.base.Preconditions.checkNotNull; /** - * An error message and the context in which it occured. Messages are usually created internally by + * An error message and the context in which it occurred. Messages are usually created internally by * Guice and its extensions. Messages can be created explicitly in a module using {@link * org.elasticsearch.common.inject.Binder#addError(Throwable) addError()} statements: *

diff --git a/src/main/java/org/elasticsearch/common/logging/support/LoggerMessageFormat.java b/src/main/java/org/elasticsearch/common/logging/support/LoggerMessageFormat.java
index 510f410a936..8ec9f61df00 100644
--- a/src/main/java/org/elasticsearch/common/logging/support/LoggerMessageFormat.java
+++ b/src/main/java/org/elasticsearch/common/logging/support/LoggerMessageFormat.java
@@ -68,7 +68,7 @@ public class LoggerMessageFormat {
                     return sbuf.toString();
                 }
             } else {
-                if (isEscapedDelimeter(messagePattern, j)) {
+                if (isEscapedDelimiter(messagePattern, j)) {
                     if (!isDoubleEscaped(messagePattern, j)) {
                         L--; // DELIM_START was escaped, thus should not be incremented
                         sbuf.append(messagePattern.substring(i, j - 1));
@@ -95,13 +95,13 @@ public class LoggerMessageFormat {
         return sbuf.toString();
     }
 
-    static boolean isEscapedDelimeter(String messagePattern,
-                                      int delimeterStartIndex) {
+    static boolean isEscapedDelimiter(String messagePattern,
+                                      int delimiterStartIndex) {
 
-        if (delimeterStartIndex == 0) {
+        if (delimiterStartIndex == 0) {
             return false;
         }
-        char potentialEscape = messagePattern.charAt(delimeterStartIndex - 1);
+        char potentialEscape = messagePattern.charAt(delimiterStartIndex - 1);
         if (potentialEscape == ESCAPE_CHAR) {
             return true;
         } else {
@@ -109,8 +109,8 @@ public class LoggerMessageFormat {
         }
     }
 
-    static boolean isDoubleEscaped(String messagePattern, int delimeterStartIndex) {
-        if (delimeterStartIndex >= 2 && messagePattern.charAt(delimeterStartIndex - 2) == ESCAPE_CHAR) {
+    static boolean isDoubleEscaped(String messagePattern, int delimiterStartIndex) {
+        if (delimiterStartIndex >= 2 && messagePattern.charAt(delimiterStartIndex - 2) == ESCAPE_CHAR) {
             return true;
         } else {
             return false;
diff --git a/src/main/java/org/elasticsearch/common/lucene/search/Queries.java b/src/main/java/org/elasticsearch/common/lucene/search/Queries.java
index d8d88b89886..ccb2d6f482c 100644
--- a/src/main/java/org/elasticsearch/common/lucene/search/Queries.java
+++ b/src/main/java/org/elasticsearch/common/lucene/search/Queries.java
@@ -124,7 +124,7 @@ public class Queries {
             return result;
         }
 
-        /* otherwise, simple expresion */
+        /* otherwise, simple expression */
 
         if (-1 < spec.indexOf('%')) {
             /* percentage - assume the % was the last char.  If not, let Integer.parseInt fail. */
diff --git a/src/main/java/org/elasticsearch/http/netty/pipelining/HttpPipeliningHandler.java b/src/main/java/org/elasticsearch/http/netty/pipelining/HttpPipeliningHandler.java
index a01982b673e..10008c76a54 100644
--- a/src/main/java/org/elasticsearch/http/netty/pipelining/HttpPipeliningHandler.java
+++ b/src/main/java/org/elasticsearch/http/netty/pipelining/HttpPipeliningHandler.java
@@ -30,7 +30,7 @@ public class HttpPipeliningHandler extends SimpleChannelHandler {
 
     /**
      * @param maxEventsHeld the maximum number of channel events that will be retained prior to aborting the channel
-     *                      connection. This is required as events cannot queue up indefintely; we would run out of
+     *                      connection. This is required as events cannot queue up indefinitely; we would run out of
      *                      memory if this was the case.
      */
     public HttpPipeliningHandler(final int maxEventsHeld) {
diff --git a/src/main/java/org/elasticsearch/index/indexing/ShardIndexingService.java b/src/main/java/org/elasticsearch/index/indexing/ShardIndexingService.java
index 3f6c85dcd2b..72a6ebfe801 100644
--- a/src/main/java/org/elasticsearch/index/indexing/ShardIndexingService.java
+++ b/src/main/java/org/elasticsearch/index/indexing/ShardIndexingService.java
@@ -294,7 +294,7 @@ public class ShardIndexingService extends AbstractIndexShardComponent {
                 assert startOfThrottleMillis > 0 : "Bad state of startOfThrottleMillis";
                 long throttleTimeMillis = System.currentTimeMillis() - startOfThrottleMillis;
                 if (throttleTimeMillis >= 0) {
-                    //A timeslip may have occured but never want to add a negative number
+                    //A timeslip may have occurred but never want to add a negative number
                     throttleTimeMillisMetric.inc(throttleTimeMillis);
                 }
             }
diff --git a/src/main/java/org/elasticsearch/index/query/TypeFilterParser.java b/src/main/java/org/elasticsearch/index/query/TypeFilterParser.java
index 2e9a5348f4c..fbd0702ca0f 100644
--- a/src/main/java/org/elasticsearch/index/query/TypeFilterParser.java
+++ b/src/main/java/org/elasticsearch/index/query/TypeFilterParser.java
@@ -64,7 +64,7 @@ public class TypeFilterParser implements FilterParser {
         parser.nextToken();
 
         Filter filter;
-        //LUCENE 4 UPGRADE document mapper should use bytesref aswell? 
+        //LUCENE 4 UPGRADE document mapper should use bytesref as well? 
         DocumentMapper documentMapper = parseContext.mapperService().documentMapper(type.utf8ToString());
         if (documentMapper == null) {
             filter = new TermFilter(new Term(TypeFieldMapper.NAME, type));
diff --git a/src/main/java/org/elasticsearch/index/query/functionscore/DecayFunctionParser.java b/src/main/java/org/elasticsearch/index/query/functionscore/DecayFunctionParser.java
index 23c154b5eed..199d497f6d1 100644
--- a/src/main/java/org/elasticsearch/index/query/functionscore/DecayFunctionParser.java
+++ b/src/main/java/org/elasticsearch/index/query/functionscore/DecayFunctionParser.java
@@ -85,7 +85,7 @@ import java.util.Locale;
  * parameters origin and scale.
  * 

* To write a new scoring function, create a new class that inherits from this - * one and implement the getDistanceFuntion(). Furthermore, to create a builder, + * one and implement the getDistanceFunction(). Furthermore, to create a builder, * override the getName() in {@link DecayFunctionBuilder}. *

* See {@link GaussDecayFunctionBuilder} and {@link GaussDecayFunctionParser} diff --git a/src/main/java/org/elasticsearch/index/query/functionscore/FunctionScoreQueryParser.java b/src/main/java/org/elasticsearch/index/query/functionscore/FunctionScoreQueryParser.java index 5f2e37e5632..64508e21fc3 100644 --- a/src/main/java/org/elasticsearch/index/query/functionscore/FunctionScoreQueryParser.java +++ b/src/main/java/org/elasticsearch/index/query/functionscore/FunctionScoreQueryParser.java @@ -51,7 +51,7 @@ import java.util.Arrays; public class FunctionScoreQueryParser implements QueryParser { public static final String NAME = "function_score"; - ScoreFunctionParserMapper funtionParserMapper; + ScoreFunctionParserMapper functionParserMapper; // For better readability of error message static final String MISPLACED_FUNCTION_MESSAGE_PREFIX = "You can either define \"functions\":[...] or a single function, not both. "; static final String MISPLACED_BOOST_FUNCTION_MESSAGE_SUFFIX = " Did you mean \"boost\" instead?"; @@ -59,8 +59,8 @@ public class FunctionScoreQueryParser implements QueryParser { public static final ParseField WEIGHT_FIELD = new ParseField("weight"); @Inject - public FunctionScoreQueryParser(ScoreFunctionParserMapper funtionParserMapper) { - this.funtionParserMapper = funtionParserMapper; + public FunctionScoreQueryParser(ScoreFunctionParserMapper functionParserMapper) { + this.functionParserMapper = functionParserMapper; } @Override @@ -129,7 +129,7 @@ public class FunctionScoreQueryParser implements QueryParser { // we try to parse a score function. If there is no score // function for the current field name, // functionParserMapper.get() will throw an Exception. - scoreFunction = funtionParserMapper.get(parseContext.index(), currentFieldName).parse(parseContext, parser); + scoreFunction = functionParserMapper.get(parseContext.index(), currentFieldName).parse(parseContext, parser); } if (functionArrayFound) { String errorString = "Found \"functions\": [...] already, now encountering \"" + currentFieldName + "\"."; @@ -202,9 +202,9 @@ public class FunctionScoreQueryParser implements QueryParser { filter = parseContext.parseInnerFilter(); } else { // do not need to check null here, - // funtionParserMapper throws exception if parser + // functionParserMapper throws exception if parser // non-existent - ScoreFunctionParser functionParser = funtionParserMapper.get(parseContext.index(), currentFieldName); + ScoreFunctionParser functionParser = functionParserMapper.get(parseContext.index(), currentFieldName); scoreFunction = functionParser.parse(parseContext, parser); } } diff --git a/src/main/java/org/elasticsearch/index/search/nested/IncludeNestedDocsQuery.java b/src/main/java/org/elasticsearch/index/search/nested/IncludeNestedDocsQuery.java index 293c9be94f4..57467478888 100644 --- a/src/main/java/org/elasticsearch/index/search/nested/IncludeNestedDocsQuery.java +++ b/src/main/java/org/elasticsearch/index/search/nested/IncludeNestedDocsQuery.java @@ -57,7 +57,7 @@ public class IncludeNestedDocsQuery extends Query { this.parentFilter = parentFilter; } - // For rewritting + // For rewriting IncludeNestedDocsQuery(Query rewrite, Query originalQuery, IncludeNestedDocsQuery previousInstance) { this.origParentQuery = originalQuery; this.parentQuery = rewrite; diff --git a/src/main/java/org/elasticsearch/index/similarity/AbstractSimilarityProvider.java b/src/main/java/org/elasticsearch/index/similarity/AbstractSimilarityProvider.java index 7ae0067e9c2..43f6091a70d 100644 --- a/src/main/java/org/elasticsearch/index/similarity/AbstractSimilarityProvider.java +++ b/src/main/java/org/elasticsearch/index/similarity/AbstractSimilarityProvider.java @@ -24,7 +24,7 @@ import org.elasticsearch.ElasticsearchIllegalArgumentException; import org.elasticsearch.common.settings.Settings; /** - * Abstract implemenetation of {@link SimilarityProvider} providing common behaviour + * Abstract implementation of {@link SimilarityProvider} providing common behaviour */ public abstract class AbstractSimilarityProvider implements SimilarityProvider { diff --git a/src/main/java/org/elasticsearch/percolator/QueryCollector.java b/src/main/java/org/elasticsearch/percolator/QueryCollector.java index bbe0a9d8b75..4149e86a385 100644 --- a/src/main/java/org/elasticsearch/percolator/QueryCollector.java +++ b/src/main/java/org/elasticsearch/percolator/QueryCollector.java @@ -230,7 +230,7 @@ abstract class QueryCollector extends SimpleCollector { MatchAndSort(ESLogger logger, PercolateContext context, boolean isNestedDoc) { super(logger, context, isNestedDoc); - // TODO: Use TopFieldCollector.create(...) for ascending and decending scoring? + // TODO: Use TopFieldCollector.create(...) for ascending and descending scoring? topDocsCollector = TopScoreDocCollector.create(context.size(), false); } diff --git a/src/main/java/org/elasticsearch/search/SearchService.java b/src/main/java/org/elasticsearch/search/SearchService.java index 76cb56af9e7..781f4a44fdb 100644 --- a/src/main/java/org/elasticsearch/search/SearchService.java +++ b/src/main/java/org/elasticsearch/search/SearchService.java @@ -98,8 +98,8 @@ import static org.elasticsearch.common.unit.TimeValue.timeValueMinutes; public class SearchService extends AbstractLifecycleComponent { public static final String NORMS_LOADING_KEY = "index.norms.loading"; - private static final String DEFAUTL_KEEPALIVE_COMPONENENT_KEY = "default_keep_alive"; - public static final String DEFAUTL_KEEPALIVE_KEY = "search." + DEFAUTL_KEEPALIVE_COMPONENENT_KEY; + private static final String DEFAULT_KEEPALIVE_COMPONENENT_KEY = "default_keep_alive"; + public static final String DEFAULT_KEEPALIVE_KEY = "search." + DEFAULT_KEEPALIVE_COMPONENENT_KEY; private static final String KEEPALIVE_INTERVAL_COMPONENENT_KEY = "keep_alive_interval"; public static final String KEEPALIVE_INTERVAL_KEY = "search." + KEEPALIVE_INTERVAL_COMPONENENT_KEY; @@ -155,7 +155,7 @@ public class SearchService extends AbstractLifecycleComponent { TimeValue keepAliveInterval = componentSettings.getAsTime(KEEPALIVE_INTERVAL_COMPONENENT_KEY, timeValueMinutes(1)); // we can have 5 minutes here, since we make sure to clean with search requests and when shard/index closes - this.defaultKeepAlive = componentSettings.getAsTime(DEFAUTL_KEEPALIVE_COMPONENENT_KEY, timeValueMinutes(5)).millis(); + this.defaultKeepAlive = componentSettings.getAsTime(DEFAULT_KEEPALIVE_COMPONENENT_KEY, timeValueMinutes(5)).millis(); Map elementParsers = new HashMap<>(); elementParsers.putAll(dfsPhase.parseElements()); diff --git a/src/main/java/org/elasticsearch/search/lookup/PositionIterator.java b/src/main/java/org/elasticsearch/search/lookup/PositionIterator.java index 24cc74e74d2..c4e01a61126 100644 --- a/src/main/java/org/elasticsearch/search/lookup/PositionIterator.java +++ b/src/main/java/org/elasticsearch/search/lookup/PositionIterator.java @@ -86,7 +86,7 @@ public class PositionIterator implements Iterator { public Iterator reset() { if (resetted) { throw new ElasticsearchException( - "Cannot iterate twice! If you want to iterate more that once, add _CACHE explicitely."); + "Cannot iterate twice! If you want to iterate more that once, add _CACHE explicitly."); } resetted = true; return this; diff --git a/src/main/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProvider.java b/src/main/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProvider.java index cc946abab67..cd4a91a8698 100644 --- a/src/main/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProvider.java +++ b/src/main/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProvider.java @@ -49,7 +49,7 @@ import java.util.*; public class AnalyzingCompletionLookupProvider extends CompletionLookupProvider { // for serialization - public static final int SERIALIZE_PRESERVE_SEPERATORS = 1; + public static final int SERIALIZE_PRESERVE_SEPARATORS = 1; public static final int SERIALIZE_HAS_PAYLOADS = 2; public static final int SERIALIZE_PRESERVE_POSITION_INCREMENTS = 4; @@ -166,7 +166,7 @@ public class AnalyzingCompletionLookupProvider extends CompletionLookupProvider output.writeVInt(maxSurfaceFormsPerAnalyzedForm); output.writeInt(maxGraphExpansions); // can be negative int options = 0; - options |= preserveSep ? SERIALIZE_PRESERVE_SEPERATORS : 0; + options |= preserveSep ? SERIALIZE_PRESERVE_SEPARATORS : 0; options |= hasPayloads ? SERIALIZE_HAS_PAYLOADS : 0; options |= preservePositionIncrements ? SERIALIZE_PRESERVE_POSITION_INCREMENTS : 0; output.writeVInt(options); @@ -210,7 +210,7 @@ public class AnalyzingCompletionLookupProvider extends CompletionLookupProvider int maxSurfaceFormsPerAnalyzedForm = input.readVInt(); int maxGraphExpansions = input.readInt(); int options = input.readVInt(); - boolean preserveSep = (options & SERIALIZE_PRESERVE_SEPERATORS) != 0; + boolean preserveSep = (options & SERIALIZE_PRESERVE_SEPARATORS) != 0; boolean hasPayloads = (options & SERIALIZE_HAS_PAYLOADS) != 0; boolean preservePositionIncrements = (options & SERIALIZE_PRESERVE_POSITION_INCREMENTS) != 0; diff --git a/src/main/java/org/elasticsearch/snapshots/SnapshotsService.java b/src/main/java/org/elasticsearch/snapshots/SnapshotsService.java index c9c621107ba..a1075424c52 100644 --- a/src/main/java/org/elasticsearch/snapshots/SnapshotsService.java +++ b/src/main/java/org/elasticsearch/snapshots/SnapshotsService.java @@ -440,7 +440,7 @@ public class SnapshotsService extends AbstractLifecycleComponent - * This method is executed on master node and it's complimentary to the {@link #currentSnapshotShards(SnapshotId)} becuase it + * This method is executed on master node and it's complimentary to the {@link #currentSnapshotShards(SnapshotId)} because it * returns simliar information but for already finished snapshots. *

* diff --git a/src/test/java/org/elasticsearch/cluster/routing/allocation/RandomAllocationDeciderTests.java b/src/test/java/org/elasticsearch/cluster/routing/allocation/RandomAllocationDeciderTests.java index dce1542c9ed..73e38b55fca 100644 --- a/src/test/java/org/elasticsearch/cluster/routing/allocation/RandomAllocationDeciderTests.java +++ b/src/test/java/org/elasticsearch/cluster/routing/allocation/RandomAllocationDeciderTests.java @@ -128,7 +128,7 @@ public class RandomAllocationDeciderTests extends ElasticsearchAllocationTestCas } - randomAllocationDecider.allwaysSayYes = true; + randomAllocationDecider.alwaysSayYes = true; logger.info("now say YES to everything"); int iterations = 0; do { @@ -172,7 +172,7 @@ public class RandomAllocationDeciderTests extends ElasticsearchAllocationTestCas this.random = random; } - public boolean allwaysSayYes = false; + public boolean alwaysSayYes = false; @Override public Decision canRebalance(ShardRouting shardRouting, RoutingAllocation allocation) { @@ -180,7 +180,7 @@ public class RandomAllocationDeciderTests extends ElasticsearchAllocationTestCas } private Decision getRandomDecision() { - if (allwaysSayYes) { + if (alwaysSayYes) { return Decision.YES; } switch (random.nextInt(10)) { diff --git a/src/test/java/org/elasticsearch/common/BooleansTests.java b/src/test/java/org/elasticsearch/common/BooleansTests.java index 6e159698836..24058ac5438 100644 --- a/src/test/java/org/elasticsearch/common/BooleansTests.java +++ b/src/test/java/org/elasticsearch/common/BooleansTests.java @@ -82,7 +82,7 @@ public class BooleansTests extends ElasticsearchTestCase { } } - public void testIsExplict() { + public void testIsExplicit() { assertThat(Booleans.isExplicitFalse(randomFrom("true", "on", "yes", "1", "foo", null)), is(false)); assertThat(Booleans.isExplicitFalse(randomFrom("false", "off", "no", "0")), is(true)); assertThat(Booleans.isExplicitTrue(randomFrom("true", "on", "yes", "1")), is(true)); diff --git a/src/test/java/org/elasticsearch/index/fielddata/AbstractStringFieldDataTests.java b/src/test/java/org/elasticsearch/index/fielddata/AbstractStringFieldDataTests.java index e1ef53cd61b..19cf91a9936 100644 --- a/src/test/java/org/elasticsearch/index/fielddata/AbstractStringFieldDataTests.java +++ b/src/test/java/org/elasticsearch/index/fielddata/AbstractStringFieldDataTests.java @@ -578,14 +578,14 @@ public abstract class AbstractStringFieldDataTests extends AbstractFieldDataImpl // 3 b/c 1 segment level caches and 1 top level cache assertThat(indicesFieldDataCache.getCache().size(), equalTo(4l)); - IndexOrdinalsFieldData cachedInstace = null; + IndexOrdinalsFieldData cachedInstance = null; for (Accountable ramUsage : indicesFieldDataCache.getCache().asMap().values()) { if (ramUsage instanceof IndexOrdinalsFieldData) { - cachedInstace = (IndexOrdinalsFieldData) ramUsage; + cachedInstance = (IndexOrdinalsFieldData) ramUsage; break; } } - assertThat(cachedInstace, sameInstance(globalOrdinals)); + assertThat(cachedInstance, sameInstance(globalOrdinals)); topLevelReader.close(); // Now only 3 segment level entries, only the toplevel reader has been closed, but the segment readers are still used by IW assertThat(indicesFieldDataCache.getCache().size(), equalTo(3l)); diff --git a/src/test/java/org/elasticsearch/index/query/SimpleIndexQueryParserTests.java b/src/test/java/org/elasticsearch/index/query/SimpleIndexQueryParserTests.java index 76e4ba1059c..46cf28860bf 100644 --- a/src/test/java/org/elasticsearch/index/query/SimpleIndexQueryParserTests.java +++ b/src/test/java/org/elasticsearch/index/query/SimpleIndexQueryParserTests.java @@ -2477,7 +2477,7 @@ public class SimpleIndexQueryParserTests extends ElasticsearchSingleNodeTest { } @Test - public void testWeight1fStillProducesWeighFuction() throws IOException { + public void testWeight1fStillProducesWeighFunction() throws IOException { IndexQueryParserService queryParser = queryParser(); String queryString = jsonBuilder().startObject() .startObject("function_score") diff --git a/src/test/java/org/elasticsearch/indices/mapping/UpdateMappingTests.java b/src/test/java/org/elasticsearch/indices/mapping/UpdateMappingTests.java index fd8759f85cd..20be0605c02 100644 --- a/src/test/java/org/elasticsearch/indices/mapping/UpdateMappingTests.java +++ b/src/test/java/org/elasticsearch/indices/mapping/UpdateMappingTests.java @@ -339,7 +339,7 @@ public class UpdateMappingTests extends ElasticsearchIntegrationTest { defaultMapping = getResponse.getMappings().get("test").get(MapperService.DEFAULT_MAPPING).sourceAsMap(); assertThat(defaultMapping, not(hasKey("date_detection"))); - // now test you can change stuff that are normally unchangable + // now test you can change stuff that are normally unchangeable logger.info("Creating _default_ mappings with an analyzed field"); putResponse = client().admin().indices().preparePutMapping("test").setType(MapperService.DEFAULT_MAPPING).setSource( JsonXContent.contentBuilder().startObject().startObject(MapperService.DEFAULT_MAPPING) diff --git a/src/test/java/org/elasticsearch/script/IndexLookupTests.java b/src/test/java/org/elasticsearch/script/IndexLookupTests.java index 836b394af30..b4082508fa9 100644 --- a/src/test/java/org/elasticsearch/script/IndexLookupTests.java +++ b/src/test/java/org/elasticsearch/script/IndexLookupTests.java @@ -574,13 +574,13 @@ public class IndexLookupTests extends ElasticsearchIntegrationTest { assertThat(sr.getHits().hits().length, equalTo(0)); ShardSearchFailure[] shardFails = sr.getShardFailures(); for (ShardSearchFailure fail : shardFails) { - assertThat(fail.reason().indexOf("Cannot iterate twice! If you want to iterate more that once, add _CACHE explicitely."), + assertThat(fail.reason().indexOf("Cannot iterate twice! If you want to iterate more that once, add _CACHE explicitly."), Matchers.greaterThan(-1)); } } catch (SearchPhaseExecutionException ex) { assertThat( "got " + ex.getDetailedMessage(), - ex.getDetailedMessage().indexOf("Cannot iterate twice! If you want to iterate more that once, add _CACHE explicitely."), + ex.getDetailedMessage().indexOf("Cannot iterate twice! If you want to iterate more that once, add _CACHE explicitly."), Matchers.greaterThan(-1)); } } diff --git a/src/test/java/org/elasticsearch/search/suggest/CompletionSuggestSearchTests.java b/src/test/java/org/elasticsearch/search/suggest/CompletionSuggestSearchTests.java index a0364d383ad..490bf0ee9d7 100644 --- a/src/test/java/org/elasticsearch/search/suggest/CompletionSuggestSearchTests.java +++ b/src/test/java/org/elasticsearch/search/suggest/CompletionSuggestSearchTests.java @@ -361,7 +361,7 @@ public class CompletionSuggestSearchTests extends ElasticsearchIntegrationTest { } @Test - public void testDisabledPreserveSeperators() throws Exception { + public void testDisabledPreserveSeparators() throws Exception { completionMappingBuilder.preserveSeparators(false); createIndexAndMapping(completionMappingBuilder); @@ -385,7 +385,7 @@ public class CompletionSuggestSearchTests extends ElasticsearchIntegrationTest { } @Test - public void testEnabledPreserveSeperators() throws Exception { + public void testEnabledPreserveSeparators() throws Exception { completionMappingBuilder.preserveSeparators(true); createIndexAndMapping(completionMappingBuilder); diff --git a/src/test/java/org/elasticsearch/search/suggest/ContextSuggestSearchTests.java b/src/test/java/org/elasticsearch/search/suggest/ContextSuggestSearchTests.java index 370b9e21c51..206ba35b1ac 100644 --- a/src/test/java/org/elasticsearch/search/suggest/ContextSuggestSearchTests.java +++ b/src/test/java/org/elasticsearch/search/suggest/ContextSuggestSearchTests.java @@ -561,7 +561,7 @@ public class ContextSuggestSearchTests extends ElasticsearchIntegrationTest { // now index a document without a color field try { index(INDEX, "service", "2", jsonBuilder().startObject().startObject("suggest").field("input", "backback").endObject().endObject()); - fail("index operation was not supposed to be succesful"); + fail("index operation was not supposed to be successful"); } catch (ElasticsearchIllegalArgumentException e) { assertThat(e.getMessage(), containsString("one or more prefixes needed")); } diff --git a/src/test/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProviderV1.java b/src/test/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProviderV1.java index 4b459342fac..651488d674d 100644 --- a/src/test/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProviderV1.java +++ b/src/test/java/org/elasticsearch/search/suggest/completion/AnalyzingCompletionLookupProviderV1.java @@ -63,7 +63,7 @@ import java.util.TreeMap; public class AnalyzingCompletionLookupProviderV1 extends CompletionLookupProvider { // for serialization - public static final int SERIALIZE_PRESERVE_SEPERATORS = 1; + public static final int SERIALIZE_PRESERVE_SEPARATORS = 1; public static final int SERIALIZE_HAS_PAYLOADS = 2; public static final int SERIALIZE_PRESERVE_POSITION_INCREMENTS = 4; @@ -182,7 +182,7 @@ public class AnalyzingCompletionLookupProviderV1 extends CompletionLookupProvide output.writeVInt(maxSurfaceFormsPerAnalyzedForm); output.writeInt(maxGraphExpansions); // can be negative int options = 0; - options |= preserveSep ? SERIALIZE_PRESERVE_SEPERATORS : 0; + options |= preserveSep ? SERIALIZE_PRESERVE_SEPARATORS : 0; options |= hasPayloads ? SERIALIZE_HAS_PAYLOADS : 0; options |= preservePositionIncrements ? SERIALIZE_PRESERVE_POSITION_INCREMENTS : 0; output.writeVInt(options); @@ -216,7 +216,7 @@ public class AnalyzingCompletionLookupProviderV1 extends CompletionLookupProvide int maxSurfaceFormsPerAnalyzedForm = input.readVInt(); int maxGraphExpansions = input.readInt(); int options = input.readVInt(); - boolean preserveSep = (options & SERIALIZE_PRESERVE_SEPERATORS) != 0; + boolean preserveSep = (options & SERIALIZE_PRESERVE_SEPARATORS) != 0; boolean hasPayloads = (options & SERIALIZE_HAS_PAYLOADS) != 0; boolean preservePositionIncrements = (options & SERIALIZE_PRESERVE_POSITION_INCREMENTS) != 0; sizeInBytes += fst.ramBytesUsed(); diff --git a/src/test/java/org/elasticsearch/test/ElasticsearchTestCase.java b/src/test/java/org/elasticsearch/test/ElasticsearchTestCase.java index 8ae868cc328..00e2f0ead07 100644 --- a/src/test/java/org/elasticsearch/test/ElasticsearchTestCase.java +++ b/src/test/java/org/elasticsearch/test/ElasticsearchTestCase.java @@ -500,18 +500,18 @@ public abstract class ElasticsearchTestCase extends AbstractRandomizedTest { * Retruns the tests compatibility version. */ public Version compatibilityVersion() { - return compatibiltyVersion(getClass()); + return compatibilityVersion(getClass()); } - private Version compatibiltyVersion(Class clazz) { + private Version compatibilityVersion(Class clazz) { if (clazz == Object.class || clazz == ElasticsearchIntegrationTest.class) { return globalCompatibilityVersion(); } CompatibilityVersion annotation = clazz.getAnnotation(CompatibilityVersion.class); if (annotation != null) { - return Version.smallest(Version.fromId(annotation.version()), compatibiltyVersion(clazz.getSuperclass())); + return Version.smallest(Version.fromId(annotation.version()), compatibilityVersion(clazz.getSuperclass())); } - return compatibiltyVersion(clazz.getSuperclass()); + return compatibilityVersion(clazz.getSuperclass()); } private static String compatibilityVersionProperty() { diff --git a/src/test/java/org/elasticsearch/test/InternalTestCluster.java b/src/test/java/org/elasticsearch/test/InternalTestCluster.java index cbc04eb05ce..5d927cb5de3 100644 --- a/src/test/java/org/elasticsearch/test/InternalTestCluster.java +++ b/src/test/java/org/elasticsearch/test/InternalTestCluster.java @@ -374,7 +374,7 @@ public final class InternalTestCluster extends TestCluster { builder.put(SearchService.KEEPALIVE_INTERVAL_KEY, TimeValue.timeValueSeconds(10 + random.nextInt(5 * 60))); } if (random.nextBoolean()) { // sometimes set a - builder.put(SearchService.DEFAUTL_KEEPALIVE_KEY, TimeValue.timeValueSeconds(100 + random.nextInt(5 * 60))); + builder.put(SearchService.DEFAULT_KEEPALIVE_KEY, TimeValue.timeValueSeconds(100 + random.nextInt(5 * 60))); } if (random.nextBoolean()) { // change threadpool types to make sure we don't have components that rely on the type of thread pools diff --git a/src/test/java/org/elasticsearch/update/UpdateTests.java b/src/test/java/org/elasticsearch/update/UpdateTests.java index 772aa3bae90..4a22a474a9d 100644 --- a/src/test/java/org/elasticsearch/update/UpdateTests.java +++ b/src/test/java/org/elasticsearch/update/UpdateTests.java @@ -692,7 +692,7 @@ public class UpdateTests extends ElasticsearchIntegrationTest { long start = System.currentTimeMillis(); do { long msRemaining = timeOut.getMillis() - (System.currentTimeMillis() - start); - logger.info("[{}] going to try and aquire [{}] in [{}]ms [{}] available to aquire right now",name, maxRequests,msRemaining, requestsOutstanding.availablePermits()); + logger.info("[{}] going to try and acquire [{}] in [{}]ms [{}] available to acquire right now",name, maxRequests,msRemaining, requestsOutstanding.availablePermits()); try { requestsOutstanding.tryAcquire(maxRequests, msRemaining, TimeUnit.MILLISECONDS ); return; @@ -718,7 +718,7 @@ public class UpdateTests extends ElasticsearchIntegrationTest { ut.join(); //Threads should have finished because of the latch.await } - //If are no errors every request recieved a response otherwise the test would have timedout + //If are no errors every request received a response otherwise the test would have timedout //aquiring the request outstanding semaphores. for (Throwable throwable : failures) { logger.info("Captured failure on concurrent update:", throwable);