Skip to content

Test harper#6

Open
kriszyp wants to merge 22 commits intomainfrom
test-harper
Open

Test harper#6
kriszyp wants to merge 22 commits intomainfrom
test-harper

Conversation

@kriszyp
Copy link
Copy Markdown
Member

@kriszyp kriszyp commented Apr 18, 2026

No description provided.

kriszyp and others added 22 commits April 17, 2026 19:41
- Add __test__/harper-integration.spec.ts: starts a real Harper instance with
  TLS + UDS mirroring, reads metadata YAML, configures SymphonyProxy to
  terminate TLS and route through UDS sockets, then verifies HTTP responses.
- Fix loadAddon() in ts/proxy.ts: try both one and two levels up from __dirname
  so the native addon is found in both production (dist/) and test (dist-test/ts/)
  build layouts.
- Add test:integration script and harper/yaml devDependencies in package.json.
- Add integration-test CI job that checks out and builds harper-pro, then runs
  the integration test with HARPER_INTEGRATION_TEST_INSTALL_SCRIPT.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Introduces a sourceAddressHeader route option with three modes:
  - 'proxyProtocol' (default for UDS): send PROXY v1 header before data
  - 'xForwardedFor': read the first HTTP chunk, insert X-Forwarded-For
    after the request line, then copy the rest verbatim — no per-request
    parsing overhead on keep-alive connections
  - 'none' (default for TCP): no source address forwarding

This enables Bun backends (which lack PROXY protocol support) to receive
the real client IP via X-Forwarded-For over UDS upstreams.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds a row to the RouteConfig reference table and a new "Source address
forwarding" section explaining all three modes, with examples for the
PROXY protocol (HarperDB/nginx) and X-Forwarded-For (Bun) use cases.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…e, and configure TLS session resumption

- **package.json**: Added `benchmark`, `benchmark:throughput`, and `diagnostic:keepalive` scripts for testing and diagnostics.
- **proxy.rs**: Introduced multi-threaded runtime (`tokio::runtime::Runtime`) to distribute proxy tasks across CPU cores, improving connection handling.
- **tls.rs**: Configured TLS session resumption with support for both TLS 1.2 and 1.3, reducing handshake latency for resumed sessions.
…ifact publishing

- **package.json**: Remove `build` step from `prepublishOnly` script.
- **Cargo.toml**: Disable default `rustls` and `tokio-rustls` features; enable logging and TLS 1.2 support.
- **release.yml**: Refactor artifact handling and npm publishing, publishing platform-specific packages separately via `napi`.
Updates CI and release workflows to use `--ignore-scripts` flag instead of `--omit=optional` for npm ci, preventing execution of install scripts during dependency installation.
…workflows

Updates CI and release workflows to upgrade npm globally before running `npm ci`, ensuring consistent dependency installation on macOS runners.
…e workflows

Updates macOS and Linux workflow steps to use `npm install --ignore-scripts` instead of upgrading npm and running `npm ci`, simplifying dependency installation across all runners.
…optionalDependencies

Updates the release workflow to manually populate `optionalDependencies` in package.json by reading platform package metadata from the `npm/` directory, replacing the previous `napi prepublish` command. Also upgrades npm to latest version before installing dependencies.
…e workflow

Replaces `npm ci` with `npm install -g npm@latest && npm install --ignore-scripts` to ensure npm is upgraded before dependency installation, aligning with other workflow changes.
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