Skip to content

Disallowing configure AM with the v1 api#13883

Merged
machine424 merged 6 commits intoprometheus:mainfrom
alanprot:deprecate-am-v1-api
Oct 18, 2024
Merged

Disallowing configure AM with the v1 api#13883
machine424 merged 6 commits intoprometheus:mainfrom
alanprot:deprecate-am-v1-api

Conversation

@alanprot
Copy link
Contributor

@alanprot alanprot commented Apr 2, 2024

AM V1 API is deprecated and removed.

This PR is just not allowing to configure AM with the V1 api anymore.

@machine424
Copy link
Member

Thanks for the PR!
I'm not sure about the compatibility policy regarding AM but I don't think we should just stop supporting v1 because newer AM no longer ship it.
Maybe we can start by marking v1 as deprecated and remove it in future versions (maybe Prometheus 3.0?)

@alanprot
Copy link
Contributor Author

alanprot commented Apr 3, 2024

Yeah.. that's fair. One can update only prometheus and keep using a old version os AM I guess. But this API is being deprecated for long time and the default is the V2 since 2019.

Im ok either way.

@machine424
Copy link
Member

I think it's safer to wait until v3, we can continue living with it.
if you want to create an issue I can add it to the milestone.
In the meantime, maybe we could add some deprecation warning logs (I don't know if we're required to do so).

@roidelapluie
Copy link
Member

The API stability page says: Some features, which are cosmetic, still under development, or depend on 3rd party services, are not covered by this.

I therefore think we can get rid of the V1 alertmanager alerts format.

@machine424
Copy link
Member

The API stability page says: Some features, which are cosmetic, still under development, or depend on 3rd party services, are not covered by this.

I therefore think we can get rid of the V1 alertmanager alerts format.

Thanks, I forgot about that page, but it's so vague that I bet we can identify a "3rd party service" for every user for every Prometheus feature :)

Copy link
Member

@machine424 machine424 left a comment

Choose a reason for hiding this comment

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

I think we can have this for 3.0
cc @jan--f

@beorn7
Copy link
Member

beorn7 commented Sep 25, 2024

Yeah, would be cool to get this into v3 to avoid any discussion if this needs a major version bump or not.
I'll add this to the project and mark it as a "breaking" change, but @jan--f please dismiss that if it seems inappropriate with your v3 hat on.

jan--f
jan--f previously requested changes Sep 27, 2024
Copy link
Contributor

@jan--f jan--f left a comment

Choose a reason for hiding this comment

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

This looks good once @machine424 's comments are addressed.

I think this would be fine to go into v3. However I do want to note that iiuc this is the first time we introduce a dependency to a minimal alertmanager version.
Imo its fine to document this in various places (config comments, release notes, migration document) but others might disagree.

@ywwg
Copy link
Member

ywwg commented Oct 9, 2024

[this is a copy-paste message on all unfinished breaking change items]
What is the status of this item? We are beginning to reach the point where breaking changes may have to miss 3.0 unless they are wrapped up soon.

@ywwg
Copy link
Member

ywwg commented Oct 11, 2024

@alanprot any update?

@ywwg
Copy link
Member

ywwg commented Oct 15, 2024

since this is mostly good to go other than the last comments, if @alanprot isn't able to get to this I can just adopt it and apply the notes as a second commit.

@alanprot
Copy link
Contributor Author

Oh.. i missed that one.. i will try to address the comments later today, but if u wanna wrap up faster and create a new PR with the change im fine as well! :D

@ywwg
Copy link
Member

ywwg commented Oct 16, 2024

No worries, just didn't want it to fall through the cracks. Thanks for wrapping it up!

alanprot and others added 3 commits October 16, 2024 15:20
Signed-off-by: alanprot <alanprot@gmail.com>
Co-authored-by: Ayoub Mrini <ayoubmrini424@gmail.com>
Signed-off-by: Alan Protasio <alanprot@gmail.com>
Co-authored-by: Ayoub Mrini <ayoubmrini424@gmail.com>
Signed-off-by: Alan Protasio <alanprot@gmail.com>
@alanprot alanprot force-pushed the deprecate-am-v1-api branch 3 times, most recently from b36d908 to abfc8b5 Compare October 16, 2024 22:34
Signed-off-by: alanprot <alanprot@gmail.com>
@alanprot alanprot force-pushed the deprecate-am-v1-api branch from abfc8b5 to b0fda91 Compare October 16, 2024 22:37
Copy link
Member

@machine424 machine424 left a comment

Choose a reason for hiding this comment

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

lgtm, thanks.
just a final doc change.

Co-authored-by: Ayoub Mrini <ayoubmrini424@gmail.com>
Signed-off-by: Alan Protasio <alanprot@gmail.com>
Co-authored-by: Jan Fajerski <jan--f@users.noreply.github.com>
Signed-off-by: Alan Protasio <alanprot@gmail.com>
@alanprot
Copy link
Contributor Author

🤞 haha :D

@machine424 machine424 requested a review from jan--f October 18, 2024 07:17
@machine424 machine424 dismissed jan--f’s stale review October 18, 2024 13:22

I think Jan is ok with this.

@machine424 machine424 merged commit c78d5b9 into prometheus:main Oct 18, 2024
KeyOfSpectator added a commit to AliyunContainerService/prometheus that referenced this pull request Oct 23, 2024
* master: (667 commits)
  NHCB scrape: refactor state handling and speed up scrape test (prometheus#15193)
  feat(tools): add debug printouts to rules unit testing (prometheus#15196)
  docs: add keep_firing_for in alerting rules
  api: Add rule group pagination to list rules api (prometheus#14017)
  Update scrape/scrape.go
  benchmark, rename parser omtext_with_nhcb
  goimports run
  Better docstring on test
  Remove omcounterdata.txt as redundant
  Fix failing benchmarks
  Add unit test to show that current wrapper is sub-optimal
  Rename convert_classic_histograms to convert_classic_histograms_to_nhcb
  More followup to prometheus#15164
  Follow up prometheus#15178
  Followup to prometheus#15164
  test(cmd/prometheus): speed up test execution by t.Parallel() when possible
  feat: normalize "le" and "quantile" labels values upon ingestion
  scrape: provide a fallback format (prometheus#15136)
  Disallowing configure AM with the v1 api (prometheus#13883)
  feat: ProtobufParse.formatOpenMetricsFloat: improve float formatting by using strconv.AppendFloat instead of fmt.Sprint
  ...

# Conflicts:
#	go.mod
#	go.sum
julienduchesne pushed a commit to julienduchesne/prometheus that referenced this pull request Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

6 participants