Skip to content

Rewrite devisPattern in plain JavaScript for 2.0.0 - #27

Merged
ismailrei merged 1 commit into
masterfrom
modernize
Nov 2, 2026
Merged

ismailrei merged 1 commit into
masterfrom
modernize

Conversation

@ismailrei

Copy link
Copy Markdown
Member

The C++ addon no longer builds: it uses V8 APIs removed around Node.js 12
and cmake-js 3 crashes on install under current Node.js. It was a string
hash map keyed by JSON.stringify(pattern), which a Map does natively.

  • Same public API (add, find, call, list) and first-registration-wins rule
  • Each instance now has its own table; 1.x shared one native table, so
    two matchers could resolve each other's patterns to the wrong handler
  • Drop cmake-js, nan, snyk, Travis and the npm-generated manifest fields
  • Real tests with node:test and a GitHub Actions matrix on Node.js 22/24
  • README describes the actual exact-match behaviour

Release order

Merge and publish first: every other Devisjs package depends on it.

Verification

Ran locally on Node.js 24 against the unpublished sibling packages; the related services (MongoDB 7, Redis 7, RabbitMQ 4) ran in Docker.

Generated with Claude Code

The C++ addon no longer builds: it uses V8 APIs removed around Node.js 12
and cmake-js 3 crashes on install under current Node.js. It was a string
hash map keyed by JSON.stringify(pattern), which a Map does natively.

- Same public API (add, find, call, list) and first-registration-wins rule
- Each instance now has its own table; 1.x shared one native table, so
  two matchers could resolve each other's patterns to the wrong handler
- Drop cmake-js, nan, snyk, Travis and the npm-generated manifest fields
- Real tests with node:test and a GitHub Actions matrix on Node.js 22/24
- README describes the actual exact-match behaviour
This was referenced Nov 2, 2026
@ismailrei
ismailrei merged commit 8d87bdc into master Nov 2, 2026
3 checks passed
@ismailrei
ismailrei deleted the modernize branch November 2, 2026 21:29
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.

1 participant