Skip to content

Commit

Permalink
Merge branch 'main' into pointrange_optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
harshavamsi committed Aug 22, 2024
2 parents 37ef477 + abb1041 commit 15fd737
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ public TermsQueryBuilder(StreamInput in) throws IOException {
termsLookup = in.readOptionalWriteable(TermsLookup::new);
values = (List<?>) in.readGenericValue();
this.supplier = null;
if (in.getVersion().onOrAfter(Version.V_3_0_0)) {
if (in.getVersion().onOrAfter(Version.V_2_17_0)) {
valueType = in.readEnum(ValueType.class);
}
}
Expand All @@ -264,7 +264,7 @@ protected void doWriteTo(StreamOutput out) throws IOException {
out.writeString(fieldName);
out.writeOptionalWriteable(termsLookup);
out.writeGenericValue(values);
if (out.getVersion().onOrAfter(Version.V_3_0_0)) {
if (out.getVersion().onOrAfter(Version.V_2_17_0)) {
out.writeEnum(valueType);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@ private void copyOneFile(
try {
cancellableThreads.executeIO(() -> {
destination.copyFrom(source, file, file, IOContext.DEFAULT);
logger.trace("Downloaded file {} of size {}", file, destination.fileLength(file));
onFileCompletion.run();
if (secondDestination != null) {
secondDestination.copyFrom(destination, file, file, IOContext.DEFAULT);
Expand Down
4 changes: 2 additions & 2 deletions server/src/main/java/org/opensearch/indices/TermsLookup.java
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public TermsLookup(StreamInput in) throws IOException {
path = in.readString();
index = in.readString();
routing = in.readOptionalString();
if (in.getVersion().onOrAfter(Version.V_3_0_0)) {
if (in.getVersion().onOrAfter(Version.V_2_17_0)) {
store = in.readBoolean();
}
}
Expand All @@ -101,7 +101,7 @@ public void writeTo(StreamOutput out) throws IOException {
out.writeString(path);
out.writeString(index);
out.writeOptionalString(routing);
if (out.getVersion().onOrAfter(Version.V_3_0_0)) {
if (out.getVersion().onOrAfter(Version.V_2_17_0)) {
out.writeBoolean(store);
}
}
Expand Down

0 comments on commit 15fd737

Please sign in to comment.