Skip to content

Fix a master->7.x serialization bug #54429

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 2 commits into from
Mar 30, 2020
Merged

Fix a master->7.x serialization bug #54429

merged 2 commits into from
Mar 30, 2020

Conversation

nik9000
Copy link
Member

@nik9000 nik9000 commented Mar 30, 2020

master wasn't sending auto_date_histogram's
minimumIntervalExpression over the wire to 7.x nodes even though
everything above 7.3 expected it. We never noticed this because we
didn't have any yml tests for auto_date_histogram until I added some
in #54161.

Closes #54396

`master` wasn't sending `auto_date_histogram`'s
`minimumIntervalExpression` over the wire to `7.x` nodes even though
everything above `7.3` expected it. We never noticed this because we
didn't have any yml tests for `auto_date_histogram` until I added some
in elastic#54161.

Closes elastic#54396
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-analytics-geo (:Analytics/Aggregations)

@nik9000
Copy link
Member Author

nik9000 commented Mar 30, 2020

I've labeled this :non-issue because it fixes a bug in an unreleased version (8.0.0). If we had made it to 8.0 without fixing this it would have been a bug.

@@ -110,20 +110,6 @@

private String minimumIntervalExpression;

public String getMinimumIntervalExpression() {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm moving these below the ctor to make me feel better.

@@ -138,6 +124,14 @@ public AutoDateHistogramAggregationBuilder(StreamInput in) throws IOException {
}
}

@Override
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm moving this up under the reading ctor so it is easier to compare.

@Override
protected void innerWriteTo(StreamOutput out) throws IOException {
out.writeVInt(numBuckets);
if (out.getVersion().onOrAfter(Version.V_7_3_0)) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing this from 8_0_0 to 7_3_0 is the actual fix.

Copy link
Contributor

@pcsanwald pcsanwald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

very nice catch!

@nik9000 nik9000 merged commit 472dd1b into elastic:master Mar 30, 2020
nik9000 added a commit to nik9000/elasticsearch that referenced this pull request Mar 30, 2020
This fixes a serialization bug in `auto_date_histogram` that comes up in
a cluster mixed between pre-7.3.0 and post-7.3.0.

Includes elastic#54429 to keep 7.x looking like master for simpler backports.

Closes elastic#54382
nik9000 added a commit that referenced this pull request Mar 30, 2020
This fixes a serialization bug in `auto_date_histogram` that comes up in
a cluster mixed between pre-7.3.0 and post-7.3.0.

Includes #54429 to keep 7.x looking like master for simpler backports.

Closes #54382
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[CI] Aggregation mixed cluster failure
4 participants