Skip to content

feat: e2e dataset benchmarks + fix npm tarball entry points#23

Merged
oleg-koval merged 2 commits into
mainfrom
feat/e2e-benchmark-ci-contributing
Apr 18, 2026
Merged

feat: e2e dataset benchmarks + fix npm tarball entry points#23
oleg-koval merged 2 commits into
mainfrom
feat/e2e-benchmark-ci-contributing

Conversation

@oleg-koval
Copy link
Copy Markdown
Owner

@oleg-koval oleg-koval commented Apr 18, 2026

Summary

  • Adds e2e dataset benchmarks, CI gate, and contributor docs (existing work on this branch).
  • Fix: tsconfig.build.json sets rootDir to ./src so tsc emits dist/index.js and dist/prisma.js, matching package.json main / exports. Published 1.3.0 tarballs only contained dist/src/*, breaking import '@olegkoval/queryd'.

Usage

Verify the package layout before/after publish:

npm pack --dry-run
# Expect: dist/index.js, dist/prisma.js at top level (no lone dist/src-only tree for entrypoints).

After release, smoke-test install:

npm i @olegkoval/queryd@latest
node -e "import('@olegkoval/queryd').then(m => console.log('ok', typeof m.createSlowQueryDetector))"

Release note

Patch/minor bump will follow conventional commits (feat + fix on merge to main).

Summary by CodeRabbit

Release Notes

  • Documentation

    • Updated README with revised product description, quick-start example, and expanded benchmark section
    • Added contributor guidelines documenting setup, testing, and submission workflow
    • Added GitHub issue template for integration feedback
  • New Features

    • Added end-to-end benchmarking suite with Docker Compose support
    • Added CI regression testing for performance monitoring
  • Chores

    • Updated build configuration and TypeScript setup
    • Added benchmark infrastructure and baseline configuration
    • Updated dependencies and npm scripts

- Add Docker-backed dataset E2E bench scripts, compose services, multi-run aggregates
- Add baseline compare + template JSON; wire CI job on Postgres
- Document benchmark output/regression in docs/benchmark-regression.md
- Add CONTRIBUTING, issue template + config; README updates; GIF script UX
- Typecheck scripts via tsconfig; exclude scripts from build; Prisma shim types
tsc was emitting dist/src/*.js while main and exports point to dist/index.js
and dist/prisma.js, breaking installs of @olegkoval/queryd on npm.
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 18, 2026

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 142d0309-de53-49e4-aec6-94ae809d303a

📥 Commits

Reviewing files that changed from the base of the PR and between 2ca64c7 and 8d2ebe5.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (20)
  • .github/ISSUE_TEMPLATE/config.yml
  • .github/ISSUE_TEMPLATE/integration-feedback.md
  • .github/workflows/ci-release.yml
  • .gitignore
  • CONTRIBUTING.md
  • README.md
  • bench/e2e-dataset-baseline.json
  • docker-compose.yml
  • docs/benchmark-regression.md
  • package.json
  • scripts/benchmark-e2e-dataset.ts
  • scripts/benchmark-e2e.ts
  • scripts/benchmark.ts
  • scripts/compare-e2e-dataset-baseline.ts
  • scripts/generate-readme-demo-gif.sh
  • src/__tests__/integration.test.ts
  • src/__tests__/wrapPrisma.test.ts
  • src/prisma-client-shim.d.ts
  • tsconfig.build.json
  • tsconfig.json

📝 Walkthrough

Walkthrough

This PR introduces comprehensive benchmarking infrastructure and project documentation. It adds benchmark scripts for performance measurement, CI regression gates, Docker setup, GitHub issue templates, contribution guidelines, and TypeScript configuration updates to support benchmarking workflows.

Changes

Cohort / File(s) Summary
GitHub Issue Templates
.github/ISSUE_TEMPLATE/config.yml, .github/ISSUE_TEMPLATE/integration-feedback.md
Added GitHub issue configuration enabling blank issues and a new integration feedback template capturing user friction, stack details, reproductions, and documentation gaps.
CI/Workflow Configuration
.github/workflows/ci-release.yml
Added benchmark-e2e-dataset job that provisions PostgreSQL 16, sets benchmark environment variables, and runs npm benchmark scripts; updated release-readiness job to depend on the new benchmark job.
Build & Config Updates
.gitignore, tsconfig.json, tsconfig.build.json
Updated ignore patterns for benchmark artifacts and demo GIF; expanded TypeScript include/exclude patterns to cover scripts and .d.ts files; set rootDir in build config.
Benchmark Infrastructure
docker-compose.yml, bench/e2e-dataset-baseline.json, docs/benchmark-regression.md, scripts/benchmark.ts, scripts/benchmark-e2e.ts, scripts/benchmark-e2e-dataset.ts, scripts/compare-e2e-dataset-baseline.ts
Added complete benchmarking system: Docker Compose PostgreSQL + Node services, baseline configuration with tolerance settings, regression comparison logic, and TypeScript benchmark harnesses measuring query instrumentation overhead across three scenarios (bare, wrapped without budget, wrapped with budget). Includes detailed documentation on CI gating algorithm and workload parameters.
Documentation & Contributions
README.md, CONTRIBUTING.md
Updated README with lightweight query observability positioning, 60-second quick start example, expanded benchmark section with commands and interpretation guide, and contributing guidelines. Added new CONTRIBUTING.md documenting prerequisites, pre-PR verification, benchmarking instructions, and security policies.
Package Management
package.json
Added npm benchmark scripts (local, Docker Compose, E2E variants), demo GIF generation script; bumped semantic-release to ^25.0.3; added postgres and tsx devDependencies.
Demo Generation
scripts/generate-readme-demo-gif.sh
New Bash script generating animated GIF of example JSON events using ImageMagick and FFmpeg; validates tools and font availability; supports timing customization via environment variables.
Prisma Type Definitions
src/prisma-client-shim.d.ts
Added module declaration shim for @prisma/client providing TypeScript typings for $queryRaw, $executeRaw, $queryRawUnsafe, $transaction, PrismaPromise, and TransactionClient.
Test Type Casting Updates
src/__tests__/integration.test.ts, src/__tests__/wrapPrisma.test.ts
Removed compile-time type constraints on transaction callback parameters in favor of runtime as type casts, addressing type annotation incompatibilities in test transaction mocking.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

Suggested labels

released on @beta``

Poem

🐰 Hop, hop, benchmarks arise!
Queries measured in microseconds, so wise.
Docker containers and test runs so grand,
Regression detection across the land!
GitHub templates and docs now shine,
Performance tracking—it's working just fine!

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/e2e-benchmark-ci-contributing

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@oleg-koval oleg-koval merged commit 7551d46 into main Apr 18, 2026
4 of 5 checks passed
@oleg-koval oleg-koval deleted the feat/e2e-benchmark-ci-contributing branch April 18, 2026 20:19
@github-actions
Copy link
Copy Markdown

🎉 This PR is included in version 1.4.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@coveralls
Copy link
Copy Markdown

Coverage Report for CI Build 24613072425

Warning

Build has drifted: This PR's base is out of sync with its target branch, so coverage data may include unrelated changes.
Quick fix: rebase this PR. Learn more →

Coverage remained the same at 95.97%

Details

  • Coverage remained the same as the base build.
  • Patch coverage: No coverable lines changed in this PR.
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 230
Covered Lines: 227
Line Coverage: 98.7%
Relevant Branches: 167
Covered Branches: 154
Branch Coverage: 92.22%
Branches in Coverage %: Yes
Coverage Strength: 23.48 hits per line

💛 - Coveralls

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants