Skip to content

Use InfluxDB v3 API for analytics reporting - #23620

Open
SMillerDev wants to merge 1 commit into
mainfrom
SMillerDev-patch-1
Open

Use InfluxDB v3 API for analytics reporting#23620
SMillerDev wants to merge 1 commit into
mainfrom
SMillerDev-patch-1

Conversation

@SMillerDev

@SMillerDev SMillerDev commented Aug 22, 2026

Copy link
Copy Markdown
Member

  • Have you followed our Contributing guidelines?
  • Have you checked for other open Pull Requests for the same change?
  • Have you explained what your changes do? Performance claims (e.g. "this is faster") must include brew benchmark results.
  • Have you explained why you'd like these changes included, not just what they do?
  • For bug fixes, have you given step-by-step brew commands to reproduce the bug?
  • Have you written new tests (excluding integration tests)? Here's an example.
  • Have you successfully run brew lgtm (style, typechecking and tests) locally?

  • I did not use AI/LLM to create this PR, or I disclosed the tool/model below and reviewed its output; I did not attribute commits to AI and will answer maintainer questions and review comments myself without AI/LLM.

This makes sure we're using the most modern API to write analytics data. Just to keep up to date.

TODO:

  • Change URL to the new brew.sh endpoint
  • Remove authorization header because it has a fallback with the new endpoint, can also be a followup

Comment thread Library/Homebrew/tests/parallel_runtime_rspec.log Outdated
Comment thread Library/Homebrew/utils/analytics.rb
Comment thread Library/Homebrew/utils/analytics.rb
@SMillerDev
SMillerDev force-pushed the SMillerDev-patch-1 branch 2 times, most recently from ca4a36c to 1ed254e Compare August 23, 2026 11:55
@SMillerDev
SMillerDev marked this pull request as ready for review August 23, 2026 11:56
Copilot AI lite review requested due to automatic review settings August 23, 2026 11:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Updates Homebrew鈥檚 analytics reporting to use the InfluxDB v3 line-protocol write endpoint in Utils::Analytics, aligning the client with a newer ingestion API.

Changes:

  • Switch analytics write URL from /api/v2/write to /api/v3/write_lp with updated query parameters.

馃挕 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Comment thread Library/Homebrew/utils/analytics.rb
Comment thread Library/Homebrew/utils/analytics.rb
Comment thread Library/Homebrew/utils/analytics.rb
@SMillerDev
SMillerDev force-pushed the SMillerDev-patch-1 branch 2 times, most recently from d361df2 to 861f58b Compare August 24, 2026 13:05
@SMillerDev

Copy link
Copy Markdown
Member Author

Split it out to: #23639

@MikeMcQuaid

Copy link
Copy Markdown
Member

Same deal: Thanks! Can you confirm you've run this locally with export HOMEBREW_ANALYTICS_DEBUG=1 and it produces identical output (bar the URL) to the previous approach?

@SMillerDev

Copy link
Copy Markdown
Member Author

The analytics still works fine and has identical output. I will wait with the merge until after the next release though, to make sure we don't change too much in one go.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants