Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@fengmk2
Copy link
Member

@fengmk2 fengmk2 commented Dec 7, 2025

close #900

SELECT `id`, `binary_id`, `name`, `date` FROM `binaries` WHERE `category` = 'node' AND `parent` = '/'

Summary by CodeRabbit

  • Performance

    • Optimized binary synchronization through streamlined data retrieval during diff computation.
  • Improvements

    • Enhanced sync logging now includes timing metrics for better diagnostics.
    • Improved detection and handling of date changes in binary items during synchronization.

✏️ Tip: You can customize this high-level summary in your review settings.

@fengmk2 fengmk2 requested review from Copilot and elrrrrrrr December 7, 2025 07:38
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 7, 2025

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Walkthrough

The pull request optimizes the binary sync service by introducing a new lightweight repository query method (listBinaryNameAndDates) to reduce constructor overhead, adds timing metrics to sync logging, and refines diff computation and revalidation logic for handling date changes and latest version detection.

Changes

Cohort / File(s) Change Summary
Repository Method Addition
app/repository/BinaryRepository.ts
Added new public method listBinaryNameAndDates that queries only id, binaryId, name, and date fields, optimizing for diff operations by avoiding full entity instantiation.
Service Optimization & Logic Refinement
app/core/service/BinarySyncerService.ts
Replaced full listBinaries query with lightweight listBinaryNameAndDates, added timing metrics to sync logs, implemented date-change detection with new Binary entity construction, and refined latest-version revalidation to build enriched item shapes.
Test Assertion Updates
test/core/service/BinarySyncerService/executeTask.test.ts
Updated logging assertions from substring checks to regex-based matches, added test-only execution marker, and extended validations to verify date/updatedAt changes across multiple sync iterations.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

  • BinarySyncerService.ts – Requires careful review of date-change detection logic, entity construction with field preservation (especially binaryId), and latest-version revalidation path correctness.
  • Test modifications – Verify regex patterns correctly validate log output and that the test-only marker (it.only) is intentional or should be reverted.
  • Cross-module consistency – Ensure the new repository method integrates seamlessly and that the returned lightweight data shape provides all needed fields for downstream diff logic.

Possibly related PRs

  • fix: perf diffΒ #699 – Modifies BinarySyncerService's latest-item calculation and diff logic, directly related to the revalidation changes in this PR.

Suggested labels

enhancement

Suggested reviewers

  • elrrrrrrr

Poem

🐰 A lighter query hops along the way,
Timing metrics chart the sync ballet,
Date diffs dance, revalidations gleamβ€”
Performance blooms in every scheme! ✨

Pre-merge checks and finishing touches

❌ Failed checks (2 warnings)
Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR title and code changes do not align with the linked issue #900, which requests CPU profiler analysis and temporary directory setup for Claude code analysis. Verify that PR #919 is correctly linked to issue #900, or re-link to the appropriate performance optimization issue if one exists.
Out of Scope Changes check ⚠️ Warning The code changes involve database query optimization and service refactoring, which are implementation details unrelated to the CPU profiler analysis objectives stated in issue #900. Either confirm this PR addresses a different issue with correct linking, or ensure the code changes directly support the CPU profiler analysis goals from #900.
βœ… Passed checks (3 passed)
Check name Status Explanation
Description Check βœ… Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage βœ… Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check βœ… Passed The title 'feat: avoids Bone constructor overhead for each row' clearly and specifically describes the main optimization change in the changesetβ€”avoiding unnecessary constructor overhead.
✨ Finishing touches
  • πŸ“ Generate docstrings
πŸ§ͺ Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch limit-listBinaryNameAndDates-v2

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.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @fengmk2, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces a crucial performance enhancement to the binary synchronization service. By optimizing database interactions to retrieve only essential data for diffing, it drastically reduces the overhead of object instantiation, leading to a more efficient and faster synchronization process, particularly beneficial for large datasets. This directly addresses the Bone constructor overhead for each row.

Highlights

  • Performance Optimization: Implemented an optimized database query to fetch only id, binaryId, name, and date columns, significantly reducing Bone constructor overhead during binary synchronization by avoiding full entity instantiation for each row.
  • Diff Operation Logging: Added logging to track the execution time of the diff operation within BinarySyncerService, providing insights into performance during synchronization.
  • Explicit Entity Creation: Modified the diff logic to explicitly create new Binary entities when a date changes or latest version directories are revalidated, ensuring data integrity while leveraging the optimized query results.
  • Test Enhancements: Updated test assertions to use regular expressions (assert.match) for log content and added deep equality checks for listRootBinaries results to ensure precise verification of updated binary items.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with πŸ‘ and πŸ‘Ž on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a performance optimization by avoiding the overhead of creating full ORM model instances for every existing binary file during the sync diffing process. It achieves this by adding a new repository method listBinaryNameAndDates that fetches only the necessary columns. The changes look good and the added timing logs are helpful. I've found one critical issue in the test files that must be addressed before merging, and a suggestion to refactor duplicated code for better maintainability.

@codecov
Copy link

codecov bot commented Dec 7, 2025

Codecov Report

βœ… All modified and coverable lines are covered by tests.
βœ… Project coverage is 95.26%. Comparing base (5ef2c67) to head (e21a373).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #919      +/-   ##
==========================================
- Coverage   95.37%   95.26%   -0.11%     
==========================================
  Files         197      197              
  Lines       22104    22138      +34     
  Branches     2053     2430     +377     
==========================================
+ Hits        21081    21090       +9     
- Misses       1023     1048      +25     

β˜” 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.
  • πŸ“¦ JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
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 PR optimizes the binary synchronization diff operation by avoiding unnecessary Bone ORM constructor overhead. Instead of fetching full BinaryEntity objects for comparison, it introduces a lightweight listBinaryNameAndDates() method that only retrieves the columns needed for diff detection (id, binaryId, name, date). This directly addresses a documented performance bottleneck identified in profiling reports where listBinaries was consuming significant CPU time during sync operations.

Key changes:

  • Adds optimized listBinaryNameAndDates() repository method for partial column selection
  • Refactors diff() method to use lightweight data structures for comparison, only creating full entities when changes are detected
  • Adds timing instrumentation to measure diff operation performance
  • Improves test assertions using assert.match() with regex patterns instead of string includes
  • Adds comprehensive test coverage to verify only modified items have their updatedAt changed

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
app/repository/BinaryRepository.ts Adds listBinaryNameAndDates() method that selects only essential columns (id, binaryId, name, date) for diff operations, avoiding full entity instantiation overhead
app/core/service/BinarySyncerService.ts Refactors diff() to use lightweight partial data structures for comparison; adds timing instrumentation; creates Binary entities only when changes detected
test/core/service/BinarySyncerService/executeTask.test.ts Enhances test to verify optimization works correctly by checking only changed items have updated timestamps; improves assertions using assert.match(); contains it.only that must be removed
Comments suppressed due to low confidence (1)

test/core/service/BinarySyncerService/executeTask.test.ts:22

  • This test is marked with it.only, which will skip all other tests in this file. This should be removed before merging to ensure the full test suite runs in CI/CD.
    it('should execute "node" task', async () => {

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (3)
app/repository/BinaryRepository.ts (1)

58-72: Lightweight projection method looks good; consider extracting a shared type alias

The new listBinaryNameAndDates() correctly limits the selected columns and avoids entity construction, which matches the performance goal and repository naming conventions. To reduce duplication and keep service/repository types in sync, you might extract the { id; binaryId; name; date } shape into a exported type (e.g. BinaryNameAndDateRow) and reuse it here and in BinarySyncerService.diff().

app/core/service/BinarySyncerService.ts (2)

207-212: Timing instrumentation in syncDir() is correct and improves observability

Capturing startTime, computing useTime, and logging the diff size along with the adapter class name gives useful performance insight without affecting control flow. You may want to break the long template string into multiple concatenated lines or variables if you need to strictly adhere to the 120-character line limit, but functionally this looks solid.


312-315: Diff logic correctly leverages the lightweight projection and preserves identity

Switching to listBinaryNameAndDates() and building an existsMap keyed by name is a good optimization that avoids unnecessary entity construction while still providing id/binaryId for updates. The date-diff and latest-version revalidation branches both create new Binary instances with the existing id and binaryId preserved, which should keep the same row identity while updating metadata and avoiding duplicate records. To reduce duplication and keep types tightly coupled with the repository, consider reusing a shared type alias for { id; binaryId; name; date } rather than repeating the structural type in both files.

Also applies to: 338-355, 363-382

πŸ“œ Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 5ef2c67 and f06f480.

πŸ“’ Files selected for processing (3)
  • app/core/service/BinarySyncerService.ts (3 hunks)
  • app/repository/BinaryRepository.ts (1 hunks)
  • test/core/service/BinarySyncerService/executeTask.test.ts (4 hunks)
🧰 Additional context used
πŸ““ Path-based instructions (6)
**/*.{js,ts,tsx,jsx}

πŸ“„ CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,ts,tsx,jsx}: Use single quotes in JavaScript/TypeScript code (from Prettier configuration)
Use 2-space indentation (from Prettier configuration)
Maintain 120 character line width maximum (from Prettier configuration)
Use trailing commas in ES5 syntax (from Prettier configuration)
Avoid parentheses in arrow functions when possible (from Prettier configuration)
Maximum of 6 function parameters (from Oxlint configuration)
Warn on console usage (from Oxlint configuration)
Disallow anonymous default exports (from Oxlint configuration)
Use ES modules (import/export) syntax throughout

Files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
  • app/repository/BinaryRepository.ts
  • app/core/service/BinarySyncerService.ts
**/*.{ts,tsx}

πŸ“„ CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{ts,tsx}: Use strict TypeScript with comprehensive type definitions - avoid any types, use proper typing or unknown
Export types and interfaces for reusability in TypeScript

Files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
  • app/repository/BinaryRepository.ts
  • app/core/service/BinarySyncerService.ts
test/**/*.test.ts

πŸ“„ CodeRabbit inference engine (.github/copilot-instructions.md)

test/**/*.test.ts: Test files must use .test.ts suffix
Tests must use @eggjs/mock for mocking and testing
Tests must use assert from node:assert/strict for assertions
Test files should be organized in test/ directory mirroring source structure
Mock external dependencies using mock() from @eggjs/mock in tests
Use realistic test data created through TestUtil helper methods
Clean up after tests - database is reset between test files
Test both success and failure cases - error paths are equally important
Test files should follow naming pattern: describe('[HTTP_METHOD /api/path] functionName()', ...)

test/**/*.test.ts: Test files must use .test.ts suffix
Use @eggjs/mock for mocking in test files
Use assert from node:assert/strict in test files
Test files must mirror source structure in test/ directory and test both success and error cases

Files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
**/*.ts

πŸ“„ CodeRabbit inference engine (CLAUDE.md)

**/*.ts: Use strict TypeScript with proper typing - avoid any types, use proper typing or unknown instead
Use ES modules with import/export syntax throughout the codebase
Use single quotes (') for strings
Use 2-space indentation
Enforce 120 character line width
Use ES5 trailing commas
Limit functions to a maximum of 6 parameters
Do not use console statements - use logger instead

Files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
  • app/repository/BinaryRepository.ts
  • app/core/service/BinarySyncerService.ts
app/repository/**/*.ts

πŸ“„ CodeRabbit inference engine (.github/copilot-instructions.md)

app/repository/**/*.ts: Repository methods must follow naming convention: findSomething, saveSomething, removeSomething, listSomethings
Repositories must contain CRUD operations and query building without business logic
Repositories must inject dependencies using @Inject() decorator

Use repository method naming convention: findX (single), saveX (create/update), removeX (delete), listXs (multiple, plural)

Files:

  • app/repository/BinaryRepository.ts
app/core/service/**/*.ts

πŸ“„ CodeRabbit inference engine (.github/copilot-instructions.md)

app/core/service/**/*.ts: Services must implement core business logic without HTTP concerns or direct database access
Services must use @SingletonProto() for service lifecycle management
Services must orchestrate multiple repositories and entities, managing transactions and events

Files:

  • app/core/service/BinarySyncerService.ts
🧠 Learnings (11)
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to test/**/*.test.ts : Test both success and failure cases - error paths are equally important

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:56.815Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-29T15:42:56.815Z
Learning: Applies to test/**/*.test.ts : Test files must mirror source structure in `test/` directory and test both success and error cases

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:56.815Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-29T15:42:56.815Z
Learning: Applies to test/**/*.test.ts : Use `assert` from `node:assert/strict` in test files

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to test/**/*.test.ts : Tests must use `assert` from `node:assert/strict` for assertions

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to test/**/*.test.ts : Clean up after tests - database is reset between test files

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to test/**/*.test.ts : Use realistic test data created through `TestUtil` helper methods

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:56.815Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-29T15:42:56.815Z
Learning: Applies to test/**/*.test.ts : Test files must use `.test.ts` suffix

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to test/**/*.test.ts : Test files should be organized in `test/` directory mirroring source structure

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to test/**/*.test.ts : Mock external dependencies using `mock()` from `eggjs/mock` in tests

Applied to files:

  • test/core/service/BinarySyncerService/executeTask.test.ts
πŸ“š Learning: 2025-11-29T15:42:37.586Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-29T15:42:37.586Z
Learning: Applies to app/repository/**/*.ts : Repository methods must follow naming convention: `findSomething`, `saveSomething`, `removeSomething`, `listSomethings`

Applied to files:

  • app/repository/BinaryRepository.ts
πŸ“š Learning: 2025-11-29T15:42:56.815Z
Learnt from: CR
Repo: cnpm/cnpmcore PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-29T15:42:56.815Z
Learning: Applies to app/repository/**/*.ts : Use repository method naming convention: `findX` (single), `saveX` (create/update), `removeX` (delete), `listXs` (multiple, plural)

Applied to files:

  • app/repository/BinaryRepository.ts
🧬 Code graph analysis (1)
app/core/service/BinarySyncerService.ts (3)
app/common/adapter/binary/PrismaBinary.ts (1)
  • result (75-134)
app/common/LogUtil.ts (1)
  • isoNow (1-3)
app/core/entity/Binary.ts (1)
  • Binary (16-49)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (16)
  • GitHub Check: Agent
  • GitHub Check: CodeQL analysis (javascript-typescript)
  • GitHub Check: test on mysql (node@22, shard@0/3, enableJSONBuilder@true)
  • GitHub Check: test on mysql (node@24, shard@0/3, enableJSONBuilder@false)
  • GitHub Check: test on mysql (node@24, shard@1/3, enableJSONBuilder@false)
  • GitHub Check: test on mysql (node@22, shard@0/3, enableJSONBuilder@false)
  • GitHub Check: test on mysql (node@24, shard@0/3, enableJSONBuilder@true)
  • GitHub Check: test on postgresql (node@22, shard@2/3)
  • GitHub Check: test on postgresql (node@24, shard@2/3)
  • GitHub Check: test on mysql (node@22, shard@1/3, enableJSONBuilder@true)
  • GitHub Check: test on postgresql (node@24, shard@1/3)
  • GitHub Check: test on postgresql (node@24, shard@0/3)
  • GitHub Check: test on postgresql (node@22, shard@0/3)
  • GitHub Check: test on postgresql (node@22, shard@1/3)
  • GitHub Check: test-deployment
  • GitHub Check: build-and-push-image

@fengmk2 fengmk2 changed the title fix: avoids Bone constructor overhead for each row feat: avoids Bone constructor overhead for each row Dec 7, 2025
@fengmk2 fengmk2 merged commit f8eedd8 into master Dec 7, 2025
28 of 29 checks passed
@fengmk2 fengmk2 deleted the limit-listBinaryNameAndDates-v2 branch December 7, 2025 08:09
fengmk2 pushed a commit that referenced this pull request Dec 7, 2025
[skip ci]

## 4.14.0 (2025-12-07)

* feat: avoids Bone constructor overhead for each row (#919) ([f8eedd8](f8eedd8)), closes [#919](#919) [hi#level](https://github.com/hi/issues/level)
* chore(benchmark): add CPU profiler analysis tools (#917) ([5ef2c67](5ef2c67)), closes [#917](#917)
@github-actions
Copy link

github-actions bot commented Dec 7, 2025

πŸŽ‰ This PR is included in version 4.14.0 πŸŽ‰

The release is available on:

Your semantic-release bot πŸ“¦πŸš€

fengmk2 added a commit that referenced this pull request Dec 7, 2025
Add analysis scripts for CPU profiles, heap dumps, and heap allocation profiles:
- analyze-cpuprofile.js: Analyzes V8/xprofiler CPU profiles
- analyze-heapdump.js: Analyzes V8 heap snapshots
- analyze-heapprofile.js: Analyzes heap allocation profiles
- compare-profiles.js: Compares two CPU profiles side-by-side

Key findings from production profile analysis:
- Leoric ORM Bone constructor is the #1 CPU hotspot (up to 5.59% under high load)
- JSON parsing is the #1 memory allocator (20.40%)
- Tegg DI container adds significant overhead (9% CPU, 16% memory)
- PR #919 addresses Bone constructor overhead

πŸ€– Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
fengmk2 added a commit that referenced this pull request Dec 9, 2025
Add comprehensive CPU profile analysis tools and reports:
- analyze-cpuprofile.mjs: Main analyzer with category breakdown
- analyze-active-cpu.mjs: Active CPU analysis excluding idle time
- analyze-bone.mjs: Bone constructor overhead analysis
- analyze-call-graph.mjs: App to ORM call relationships
- analyze-routing.mjs: Request routing hotspot analysis
- analyze-app-to-framework.mjs: Framework integration analysis

Key findings from v4.14.0 profile:
- 76% idle time (I/O bound, expected for registry)
- Application code uses only 4.5% of active CPU (efficient)
- Leoric ORM: 15.2% (Bone constructor is top hotspot)
- Egg/Tegg framework: 27.3% (routing, DI, lifecycle)
- deep-equal now uses 0% CPU (fixed in PR #919)

πŸ€– Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
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.

使用 claude code ε―Ή cpuprofiler θΏ›θ‘Œη»“ζžœεˆ†ζž

2 participants