Skip to content
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

[TSVB] Add migration script for 'drop_last_bucket' value #110782

Merged
merged 3 commits into from
Sep 2, 2021

Conversation

alexwizp
Copy link
Contributor

@alexwizp alexwizp commented Sep 1, 2021

Fix regression of #97257

Summary

By default, drop_last_bucket / series_drop_last_bucket is not defined in the model. This caused a problem when upgrading to version 7.14 as the default value was changed in #97257. As a result - after updating, saved visualizations show different data

What was done in that PR:

  • added a migration script that adds the required property to the model
  • migration script was added for byRef and byValue visualizations

@alexwizp alexwizp requested a review from stratoula September 1, 2021 12:48
@alexwizp alexwizp self-assigned this Sep 1, 2021
@alexwizp alexwizp added v7.14.2 v7.15.1 v7.16.0 v8.0.0 Feature:TSVB TSVB (Time Series Visual Builder) release_note:fix Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Sep 1, 2021
@alexwizp alexwizp marked this pull request as ready for review September 1, 2021 12:49
@alexwizp alexwizp requested a review from a team as a code owner September 1, 2021 12:49
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-vis-editors (Team:VisEditors)

Copy link
Contributor

@DianaDerevyankina DianaDerevyankina left a comment

Choose a reason for hiding this comment

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

LGTM, tested locally

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @alexwizp

Copy link
Contributor

@stratoula stratoula left a comment

Choose a reason for hiding this comment

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

LGTM, I tested locally various cases and the migrations work fine

Copy link
Contributor

@VladLasitsa VladLasitsa left a comment

Choose a reason for hiding this comment

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

code review LGTM!

@alexwizp alexwizp added the auto-backport Deprecated - use backport:version if exact versions are needed label Sep 2, 2021
@alexwizp alexwizp merged commit 8861732 into elastic:master Sep 2, 2021
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 2, 2021
)

* [TSVB] Add migration script for 'drop_last_bucket' value

* Update visualization_saved_object_migrations.test.ts

* fix PR comments
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 2, 2021
)

* [TSVB] Add migration script for 'drop_last_bucket' value

* Update visualization_saved_object_migrations.test.ts

* fix PR comments
@kibanamachine
Copy link
Contributor

💔 Backport failed

Status Branch Result
7.x
7.14 Commit could not be cherrypicked due to conflicts
7.15

Successful backport PRs will be merged automatically after passing CI.

To backport manually run:
node scripts/backport --pr 110782

kibanamachine added a commit that referenced this pull request Sep 2, 2021
…110957)

* [TSVB] Add migration script for 'drop_last_bucket' value

* Update visualization_saved_object_migrations.test.ts

* fix PR comments

Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
alexwizp added a commit to alexwizp/kibana that referenced this pull request Sep 3, 2021
)

* [TSVB] Add migration script for 'drop_last_bucket' value

* Update visualization_saved_object_migrations.test.ts

* fix PR comments
# Conflicts:
#	src/plugins/visualizations/server/embeddable/visualize_embeddable_factory.ts
alexwizp added a commit that referenced this pull request Sep 3, 2021
…111091)

* [TSVB] Add migration script for 'drop_last_bucket' value

* Update visualization_saved_object_migrations.test.ts

* fix PR comments
# Conflicts:
#	src/plugins/visualizations/server/embeddable/visualize_embeddable_factory.ts
kibanamachine added a commit that referenced this pull request Sep 3, 2021
…110956)

* [TSVB] Add migration script for 'drop_last_bucket' value

* Update visualization_saved_object_migrations.test.ts

* fix PR comments

Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed Feature:TSVB TSVB (Time Series Visual Builder) release_note:fix Team:Visualizations Visualization editors, elastic-charts and infrastructure v7.14.2 v7.15.1 v7.16.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants