Skip to content

docs(bench): add repo allocation micro-benchmarks and remove non-technical docs - #5

Merged
SShogun merged 1 commit into
masterfrom
docs/benchmarks-cleanup
Oct 20, 2026
Merged

SShogun merged 1 commit into
masterfrom
docs/benchmarks-cleanup

Conversation

@SShogun

@SShogun SShogun commented Oct 20, 2026 •

Copy link
Copy Markdown
Owner

Updates README with internal/repo micro-benchmark results and removes social_templates.md.

Summary by Sourcery

Document repository performance and verification results while removing obsolete social media templates.

Enhancements:

  • Document repository cache and concurrency micro-benchmark results, including allocation characteristics and end-to-end verification coverage.

Documentation:

  • Remove the obsolete social media templates documentation.

Copilot AI balanced review requested due to automatic review settings October 20, 2026 05:03
@sourcery-ai

sourcery-ai Bot commented Oct 20, 2026 •

Copy link
Copy Markdown
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adds README documentation for internal repository micro-benchmarks and end-to-end Redis verification, while removing the non-technical social templates document.

File-Level Changes

Change Details Files
Documents repository performance characteristics and allocation behavior using reproducible benchmark and integration-verification results.
  • Adds cache-hit, contention, cache-miss, and backfill benchmark results with latency, throughput, and allocation metrics.
  • Describes the benchmark environment and command used to isolate in-process repository behavior from network latency.
  • Records the multi-module integration verification count and Redis-backed stream recovery result.
README.md
Removes the social-template documentation from the repository.
  • Deletes the social media template document.
docs/social_templates.md

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!

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

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey - I've found 1 issue

Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path="README.md" line_range="205" />
<code_context>
+| :--- | :---: | :---: | :---: | :---: | :---: |
+| **Cache Hit (`GetByID_CacheHit`)** | 8 | `36.98 ns/op` | ~27.0M ops/sec | `0 B/op` | `0 allocs/op` |
+| **Parallel Contention (`GetByID_Contention`)** | 8 | `42.99 ns/op` | ~23.3M ops/sec | `0 B/op` | `0 allocs/op` |
+| **Cache Miss Fast-Path (`GetByID_CacheMiss`)** | 8 | `73.99 ns/op` | ~13.5M ops/sec | `0 B/op` | `0 allocs/op` |
+| **Cold Miss + Cache Backfill (`GetByID_BackfillPath`)** | 8 | `418.90 ns/op` | ~2.39M ops/sec | `352 B/op` | `2 allocs/op` |
+
</code_context>
<issue_to_address>
**Cache miss work mislabeled**

When readers compare the reported row as a fast-path result, `BenchmarkCacheItemRepo_GetByID_CacheMiss` gets a cache miss on every iteration, then runs the fallback and attempts a cache backfill. Its result therefore includes that work, not a cache-miss fast path.

Rename the row to describe the fallback and backfill work, or change the benchmark to measure an actual fast path.
</issue_to_address>

Sourcery assessment

Approval pending. 1 finding to address first.

Blocking findings: README.md:205


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

Comment thread README.md
| :--- | :---: | :---: | :---: | :---: | :---: |
| **Cache Hit (`GetByID_CacheHit`)** | 8 | `36.98 ns/op` | ~27.0M ops/sec | `0 B/op` | `0 allocs/op` |
| **Parallel Contention (`GetByID_Contention`)** | 8 | `42.99 ns/op` | ~23.3M ops/sec | `0 B/op` | `0 allocs/op` |
| **Cache Miss Fast-Path (`GetByID_CacheMiss`)** | 8 | `73.99 ns/op` | ~13.5M ops/sec | `0 B/op` | `0 allocs/op` |

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Medium · Cache miss work mislabeled

When readers compare the reported row as a fast-path result, BenchmarkCacheItemRepo_GetByID_CacheMiss gets a cache miss on every iteration, then runs the fallback and attempts a cache backfill. Its result therefore includes that work, not a cache-miss fast path.

Rename the row to describe the fallback and backfill work, or change the benchmark to measure an actual fast path.

Prompt for AI agents
In `README.md` at line 205:

**Cache miss work mislabeled**

When readers compare the reported row as a fast-path result, `BenchmarkCacheItemRepo_GetByID_CacheMiss` gets a cache miss on every iteration, then runs the fallback and attempts a cache backfill. Its result therefore includes that work, not a cache-miss fast path.

Rename the row to describe the fallback and backfill work, or change the benchmark to measure an actual fast path.

@SShogun
SShogun merged commit bce2b7e into master Oct 20, 2026
3 checks passed
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