Skip to content

[Merged by Bors] - TrinoClusters must specify a catalogLabelSelector#277

Closed
sbernauer wants to merge 7 commits into
mainfrom
make-catalogLabelSelector-mandatory
Closed

[Merged by Bors] - TrinoClusters must specify a catalogLabelSelector#277
sbernauer wants to merge 7 commits into
mainfrom
make-catalogLabelSelector-mandatory

Conversation

@sbernauer

@sbernauer sbernauer commented Sep 7, 2022

Copy link
Copy Markdown
Member

Description

During bumping the demos to the 22.09 i noticed that the following spec from the Trino tests and docs is invalid

apiVersion: trino.stackable.tech/v1alpha1
kind: TrinoCluster
metadata:
  name: simple-trino
spec:
  version: 387-stackable0.1.0
  catalogLabelSelector:
    trino: simple-trino

instead it should be

# ...
  catalogLabelSelector:
    matchLabels:
      trino: simple-trino

Nobody noticed this, as the field catalogLabelSelector is optional. If it is not provided, the (nonexistent) Labelselector will match every TrinoCatalog withing the same Namespace and the test passed anyway.
This behavior sounds unsafe/unwanted so i suggest to make it explicit by requiring a Labelselector.

Although this change is technically breaking, the TrinoCatalog feature change has been release for a single day now, so impact should be pretty minimal. It would be greatif we could include this Change in 22.09, so that we reduce the number of breaking changes between Platform releases

Review Checklist

  • Code contains useful comments
  • CRD change approved (or not applicable)
  • (Integration-)Test cases added (or not applicable)
  • Documentation added (or not applicable)
  • Changelog updated (or not applicable)
  • Cargo.toml only contains references to git tags (not specific commits or branches)
  • Helm chart can be installed and deployed operator works (or not applicable)

Once the review is done, comment bors r+ (or bors merge) to merge. Further information

@maltesander maltesander left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM. But breaking change without discussion?

@sbernauer sbernauer changed the title TrinoClusters now must specify a catalogLabelSelector TrinoClusters must specify a catalogLabelSelector Sep 8, 2022
@sbernauer

Copy link
Copy Markdown
Member Author

We discussed this in Slack and Lars, Sönke and Teo approved (send you the link)
Could you please give a final approval?

@sbernauer

Copy link
Copy Markdown
Member Author

@maltesander maltesander left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM but please wait for the tests!

@sbernauer sbernauer mentioned this pull request Sep 8, 2022
13 tasks
@sbernauer

Copy link
Copy Markdown
Member Author

Tests succeeded

@sbernauer

Copy link
Copy Markdown
Member Author

bors r+

bors Bot pushed a commit that referenced this pull request Sep 8, 2022
# Description

During bumping the demos to the 22.09  i noticed that the following spec from the Trino tests and docs is invalid
```
apiVersion: trino.stackable.tech/v1alpha1
kind: TrinoCluster
metadata:
  name: simple-trino
spec:
  version: 387-stackable0.1.0
  catalogLabelSelector:
    trino: simple-trino
```
instead it should be 
```
# ...
  catalogLabelSelector:
    matchLabels:
      trino: simple-trino
```
Nobody noticed this, as the field `catalogLabelSelector` is optional. If it is not provided, the (nonexistent) Labelselector will match every TrinoCatalog withing the same Namespace and the test passed anyway.
This behavior sounds unsafe/unwanted so i suggest to make it explicit by requiring a Labelselector.

Although this change is technically breaking, the `TrinoCatalog` feature change has been release for a single day now, so impact should be pretty minimal. It would be greatif we could include this Change in 22.09, so that we reduce the number of breaking changes between Platform releases

## Review Checklist

- [x] Code contains useful comments
- [x] CRD change approved (or not applicable)
- [x] (Integration-)Test cases added (or not applicable)
- [x] Documentation added (or not applicable)
- [x] Changelog updated (or not applicable)
- [x] Cargo.toml only contains references to git tags (not specific commits or branches)
- [x] Helm chart can be installed and deployed operator works (or not applicable)


Once the review is done, comment `bors r+` (or `bors merge`) to merge. [Further information](https://bors.tech/documentation/getting-started/#reviewing-pull-requests)
@bors

bors Bot commented Sep 8, 2022

Copy link
Copy Markdown
Contributor

Pull request successfully merged into main.

Build succeeded:

@bors bors Bot changed the title TrinoClusters must specify a catalogLabelSelector [Merged by Bors] - TrinoClusters must specify a catalogLabelSelector Sep 8, 2022
@bors bors Bot closed this Sep 8, 2022
@bors
bors Bot deleted the make-catalogLabelSelector-mandatory branch September 8, 2022 10:44
bors Bot pushed a commit that referenced this pull request Sep 8, 2022
Proposing a release that's part of 22.09 to combine the TrinoCatalog feature (#263) with a fix that's a breaking change (#277).

By including trino-operator 0.6.0 in 22.09 we don't have a breaking change between platform releases.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants