Skip to content

Fixed PrimaryTerm/SeqNo datatypes in UpdateQuery #3137

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ public class UpdateQuery {
@Nullable private final Boolean fetchSource;
@Nullable private final List<String> fetchSourceIncludes;
@Nullable private final List<String> fetchSourceExcludes;
@Nullable private final Integer ifSeqNo;
@Nullable private final Integer ifPrimaryTerm;
@Nullable private final Long ifSeqNo;
@Nullable private final Long ifPrimaryTerm;
@Nullable private final RefreshPolicy refreshPolicy;
@Nullable private final Integer retryOnConflict;
@Nullable private final String timeout;
Expand Down Expand Up @@ -71,8 +71,8 @@ public static Builder builder(Query query) {
private UpdateQuery(String id, @Nullable String script, @Nullable Map<String, Object> params,
@Nullable Document document, @Nullable Document upsert, @Nullable String lang, @Nullable String routing,
@Nullable Boolean scriptedUpsert, @Nullable Boolean docAsUpsert, @Nullable Boolean fetchSource,
@Nullable List<String> fetchSourceIncludes, @Nullable List<String> fetchSourceExcludes, @Nullable Integer ifSeqNo,
@Nullable Integer ifPrimaryTerm, @Nullable RefreshPolicy refreshPolicy, @Nullable Integer retryOnConflict,
@Nullable List<String> fetchSourceIncludes, @Nullable List<String> fetchSourceExcludes, @Nullable Long ifSeqNo,
@Nullable Long ifPrimaryTerm, @Nullable RefreshPolicy refreshPolicy, @Nullable Integer retryOnConflict,
@Nullable String timeout, @Nullable String waitForActiveShards, @Nullable Query query,
@Nullable Boolean abortOnVersionConflict, @Nullable Integer batchSize, @Nullable Integer maxDocs,
@Nullable Integer maxRetries, @Nullable String pipeline, @Nullable Float requestsPerSecond,
Expand Down Expand Up @@ -172,12 +172,12 @@ public List<String> getFetchSourceExcludes() {
}

@Nullable
public Integer getIfSeqNo() {
public Long getIfSeqNo() {
return ifSeqNo;
}

@Nullable
public Integer getIfPrimaryTerm() {
public Long getIfPrimaryTerm() {
return ifPrimaryTerm;
}

Expand Down Expand Up @@ -278,8 +278,8 @@ public static final class Builder {
@Nullable private Boolean scriptedUpsert;
@Nullable private Boolean docAsUpsert;
@Nullable private Boolean fetchSource;
@Nullable private Integer ifSeqNo;
@Nullable private Integer ifPrimaryTerm;
@Nullable private Long ifSeqNo;
@Nullable private Long ifPrimaryTerm;
@Nullable private RefreshPolicy refreshPolicy;
@Nullable private Integer retryOnConflict;
@Nullable private String timeout;
Expand Down Expand Up @@ -351,12 +351,12 @@ public Builder withFetchSource(Boolean fetchSource) {
return this;
}

public Builder withIfSeqNo(Integer ifSeqNo) {
public Builder withIfSeqNo(Long ifSeqNo) {
this.ifSeqNo = ifSeqNo;
return this;
}

public Builder withIfPrimaryTerm(Integer ifPrimaryTerm) {
public Builder withIfPrimaryTerm(Long ifPrimaryTerm) {
this.ifPrimaryTerm = ifPrimaryTerm;
return this;
}
Expand Down