Skip to content

ci: add weekly Maven Central download stats workflow#1707

Closed
javier-aliaga wants to merge 2 commits intodapr:masterfrom
javier-aliaga:feat/usage-statistics-action
Closed

ci: add weekly Maven Central download stats workflow#1707
javier-aliaga wants to merge 2 commits intodapr:masterfrom
javier-aliaga:feat/usage-statistics-action

Conversation

@javier-aliaga
Copy link
Copy Markdown
Contributor

Scheduled GitHub Action (Mondays 9am UTC) that fetches OSSRH download stats (monthly timeline + per-version breakdown) and writes them to the workflow step summary. Credentials are passed via netrc file to avoid process-arg exposure, and API response data is sanitized before rendering to Markdown.

Description

Please explain the changes you've made

Issue reference

We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.

Please reference the issue this PR will close: #[issue number]

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

  • Code compiles correctly
  • Created/updated tests
  • Extended the documentation

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request adds a new GitHub Actions workflow file (.github/workflows/sdk-stats.yml) that implements a scheduled task to fetch and display Maven Central download statistics for the Dapr Java SDK. The workflow runs every Monday at 9 AM UTC and retrieves both monthly timeline statistics and per-version breakdown data from OSSRH (OSS Repository Hosting), displaying the results in the GitHub Actions workflow summary.

Changes:

  • Added new workflow file to fetch and display Maven Central download statistics
  • Implements secure credential handling via netrc file to avoid exposing tokens in process arguments
  • Sanitizes API response data before rendering to Markdown to prevent injection attacks

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@javier-aliaga javier-aliaga force-pushed the feat/usage-statistics-action branch 2 times, most recently from b7a8c22 to 6a76826 Compare March 31, 2026 13:28
Scheduled GitHub Action (Mondays 9am UTC) that fetches OSSRH
download stats (monthly timeline + per-version breakdown) and
writes them to the workflow step summary. Credentials are passed
via netrc file to avoid process-arg exposure, and API response
data is sanitized before rendering to Markdown.

Signed-off-by: Javier Aliaga <javier@diagrid.io>
- Add Apache License 2.0 copyright header
- Use read-only OSSRH secrets (OSSRH_READ_USER_TOKEN/OSSRH_READ_PWD_TOKEN)
- Handle empty xmllint output for total downloads gracefully

Signed-off-by: Javier Aliaga <javier@diagrid.io>
@javier-aliaga javier-aliaga force-pushed the feat/usage-statistics-action branch from 6a76826 to ee13ed8 Compare March 31, 2026 14:30
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 31, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.54%. Comparing base (d6b25cb) to head (ee13ed8).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1707      +/-   ##
============================================
+ Coverage     79.53%   79.54%   +0.01%     
+ Complexity     2197     2196       -1     
============================================
  Files           238      238              
  Lines          6591     6591              
  Branches        732      732              
============================================
+ Hits           5242     5243       +1     
+ Misses          992      990       -2     
- Partials        357      358       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

2 participants