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

[pull] master from netdata:master #377

Merged
merged 6 commits into from
Feb 21, 2025
Merged

Conversation

pull[bot]
Copy link

@pull pull bot commented Feb 20, 2025

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.1)

Can you help keep this open source service alive? 💖 Please sponsor : )

Summary by Sourcery

This pull request fixes the CPU time calculation for MariaDB user statistics and downgrades the Go version in go.mod files.

Bug Fixes:

  • Fixes CPU time calculation for MariaDB user statistics by adjusting the division factor based on the MariaDB version to ensure accurate reporting.

Chores:

  • Downgrade the Go version in go.mod files from 1.23.6 to 1.23.4.

@pull pull bot added the ⤵️ pull label Feb 20, 2025
Copy link

sourcery-ai bot commented Feb 20, 2025

Reviewer's Guide by Sourcery

This pull request includes changes to the CPU time calculation for MariaDB in the MySQL collector, addressing unit reporting inconsistencies in specific MariaDB versions. Additionally, the Go version has been downgraded from 1.23.6 to 1.23.4 in the go.mod files.

Sequence diagram for collecting user statistics

sequenceDiagram
  participant Collector
  participant MariaDB

  Collector->>MariaDB: Query user statistics
  MariaDB-->>Collector: Return statistics (including Cpu_time)
  alt MariaDB version >= 10.11.11 and < 11.4.5
    Collector->>Collector: Divide Cpu_time by 1e7 * 1000
  else MariaDB version >= 11.4.5
    Collector->>Collector: Divide Cpu_time by 1e7 * 1000
  else
    Collector->>Collector: Multiply Cpu_time by 1000
  end
  Collector->>Collector: Store statistics
Loading

File-Level Changes

Change Details Files
Adjusted CPU time calculation for MariaDB versions to address unit reporting inconsistencies.
  • Added a condition to check MariaDB version and apply a division factor when calculating CPU time.
  • Modified the CPU time calculation logic to divide by 1e7 when the MariaDB version meets specific criteria (version 10.11.11 or greater, or version 11.4.5 or greater).
  • Ensured that the calculated CPU time is multiplied by 1000 in all cases.
src/go/plugin/go.d/collector/mysql/collect_user_statistics.go
Downgraded the Go version in go.mod files.
  • Changed the Go version from 1.23.6 to 1.23.4 in src/go/go.mod.
  • Changed the Go version from 1.23.6 to 1.23.4 in src/go/otel-collector/exporter/journaldexporter/go.mod.
src/go/go.mod
src/go/otel-collector/exporter/journaldexporter/go.mod

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!
  • Generate a plan of action for an issue: Comment @sourcery-ai plan on
    an issue to generate a plan of action for it.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@pull pull bot merged commit da2620e into webfutureiorepo:master Feb 21, 2025
1 check passed
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.

4 participants