Skip to content

Commit

Permalink
reserve some versions for 6.x
Browse files Browse the repository at this point in the history
  • Loading branch information
dnhatn committed Jul 17, 2018
1 parent 15e3c4d commit d3780ee
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1009,8 +1009,9 @@ public Source(BytesReference source, String routing) {
public static class Index implements Operation {

public static final int FORMAT_6_0 = 8; // since 6.0.0
public static final int FORMAT_NO_PARENT = FORMAT_6_0 + 1; // since 7.0
public static final int FORMAT_NO_VERSION_TYPE = FORMAT_NO_PARENT + 1; // since 7.0
public static final int FORMAT_7_0 = FORMAT_6_0 + 5; // reserve some versions for 6.x
public static final int FORMAT_NO_PARENT = FORMAT_7_0 + 1;
public static final int FORMAT_NO_VERSION_TYPE = FORMAT_NO_PARENT + 1;
public static final int SERIALIZATION_FORMAT = FORMAT_NO_VERSION_TYPE;

private final String id;
Expand Down Expand Up @@ -1184,7 +1185,8 @@ public long getAutoGeneratedIdTimestamp() {
public static class Delete implements Operation {

private static final int FORMAT_6_0 = 4; // 6.0 - *
public static final int FORMAT_NO_VERSION_TYPE = FORMAT_6_0 + 1; // since 7.0
private static final int FORMAT_7_0 = FORMAT_6_0 + 5; // reserve some versions for 6.x
public static final int FORMAT_NO_VERSION_TYPE = FORMAT_7_0 + 1;
public static final int SERIALIZATION_FORMAT = FORMAT_NO_VERSION_TYPE;

private final String type, id;
Expand Down

0 comments on commit d3780ee

Please sign in to comment.