Update the BWC versions (post 1.x backport) (#2390)
Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
This commit is contained in:
parent
919d18036e
commit
65debde436
|
@ -60,7 +60,7 @@ public abstract class ScoreFunctionBuilder<FB extends ScoreFunctionBuilder<FB>>
|
|||
*/
|
||||
public ScoreFunctionBuilder(StreamInput in) throws IOException {
|
||||
weight = checkWeight(in.readOptionalFloat());
|
||||
if (in.getVersion().onOrAfter(Version.V_2_0_0)) {
|
||||
if (in.getVersion().onOrAfter(Version.V_1_3_0)) {
|
||||
functionName = in.readOptionalString();
|
||||
}
|
||||
}
|
||||
|
@ -68,7 +68,7 @@ public abstract class ScoreFunctionBuilder<FB extends ScoreFunctionBuilder<FB>>
|
|||
@Override
|
||||
public final void writeTo(StreamOutput out) throws IOException {
|
||||
out.writeOptionalFloat(weight);
|
||||
if (out.getVersion().onOrAfter(Version.V_2_0_0)) {
|
||||
if (out.getVersion().onOrAfter(Version.V_1_3_0)) {
|
||||
out.writeOptionalString(functionName);
|
||||
}
|
||||
doWriteTo(out);
|
||||
|
|
Loading…
Reference in New Issue