connectrpc 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/docs/development.md +76 -0
- data/lib/connectrpc/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4b63f38115a064ea34b17947232b4945c5600007ba7e8406b84fe4f4f68a2dcc
|
|
4
|
+
data.tar.gz: ec4b544f0f1b22bcd293e14cf58f3d70dd4da8fc5a6d2c112e715943413f8aa8
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 669ed068fcaf1b7aceacd5b8836ef0e4d50a73a5aa152e0befe07c353d9d5718a4747ae9378159f83b592e7141865c06d53073d0b1eab861c4f6fa974db6694c
|
|
7
|
+
data.tar.gz: 43f890664e92326a1237e976fc5a33a89ec164339ff9e6e12b2029731ec2e4ebbb3060a02ba12a6e423e7abe76973a54681314d85a0a2e1e5641bf385f4e49e4
|
data/docs/development.md
CHANGED
|
@@ -772,6 +772,82 @@ streaming SPI under normal installed discovery outside the checkout, in both
|
|
|
772
772
|
package load orders. The [streaming guide](streaming.md) documents the fixed
|
|
773
773
|
one-second tail policy and its compatibility tradeoff.
|
|
774
774
|
|
|
775
|
+
## Lifecycle campaign
|
|
776
|
+
|
|
777
|
+
The long-running lifecycle campaign repeatedly drives the native clients and
|
|
778
|
+
servers through connection churn and faults, then checks that everything they
|
|
779
|
+
own retires. It is non-gating and belongs to no `test` or `verify` task:
|
|
780
|
+
|
|
781
|
+
```sh
|
|
782
|
+
mise run async:soak # Async H2 Transport, ThreadedTransport and Host
|
|
783
|
+
mise run falcon:soak # Falcon HTTP/2 and HTTP/1.1 (HTTP1Transport, Net::HTTP)
|
|
784
|
+
mise run soak # both, Async then Falcon
|
|
785
|
+
```
|
|
786
|
+
|
|
787
|
+
The campaign is exercised on Linux, locally and in CI. It counts descriptors
|
|
788
|
+
through `/dev/fd`, but RSS and the TCP ports and states in its diagnostics come
|
|
789
|
+
from `/proc`; without `/proc` it reports RSS as missing and descriptor targets
|
|
790
|
+
without socket details. Other platforms are untested.
|
|
791
|
+
|
|
792
|
+
[`scripts/soak.rb`](../scripts/soak.rb) runs `scripts/run.rb soak` for each
|
|
793
|
+
named package in turn, each in its own process group. A failed package does not
|
|
794
|
+
stop the next one, and the script exits non-zero if any package failed.
|
|
795
|
+
`scripts/run.rb soak` runs RSpec over `soak/**/*_soak.rb` with `soak/.rspec`,
|
|
796
|
+
which loads `soak/soak_helper.rb` instead of `spec_helper`, so SimpleCov never
|
|
797
|
+
starts. The scenarios (churn, GOAWAY drains, stream retirement,
|
|
798
|
+
stuck frames, slow peers, peer failure, TLS rotation, shutdown, keepalive and
|
|
799
|
+
refusal) and their invariants are specified in the
|
|
800
|
+
[campaign plan](plans/lifecycle-campaign.md). Shared HTTP/2 scenarios live in
|
|
801
|
+
`gems/connectrpc-async/soak/support/scenarios/` and run against both the Async
|
|
802
|
+
Host and Falcon; every private-state read lives in
|
|
803
|
+
`gems/connectrpc-async/soak/support/sampler.rb`, the one file to update when
|
|
804
|
+
library internals move.
|
|
805
|
+
|
|
806
|
+
Each scenario runs warmup rounds until two consecutive post-cleanup samples of
|
|
807
|
+
threads, `/dev/fd` entries and unfinished Async tasks (harness, peer and
|
|
808
|
+
ThreadedTransport owner reactors) are identical, at most three. Every measured
|
|
809
|
+
round must then settle its owned objects (client and server resources retired,
|
|
810
|
+
owner threads joined, registries and shared cancellation listeners empty) and
|
|
811
|
+
return exactly to that sample. Every call without its own cancellation source
|
|
812
|
+
carries the campaign's shared, never-cancelled token, also when it is expected
|
|
813
|
+
to fail. Admission, byte, socket, server connection and stream-buffer peaks are
|
|
814
|
+
sampled under established load against their configured caps, and a handler
|
|
815
|
+
ledger proves at-most-once execution. There are no tolerance bands. RSS and GC
|
|
816
|
+
live slots are reported, never asserted.
|
|
817
|
+
|
|
818
|
+
| Variable | Default | Meaning |
|
|
819
|
+
| --- | --- | --- |
|
|
820
|
+
| `CONNECTRPC_SOAK_ROUNDS` | 5 | Measured rounds per scenario |
|
|
821
|
+
| `CONNECTRPC_SOAK_DEADLINE` | 900 | Run deadline in seconds; raise it for runs well above the default rounds (CI uses 2,700 for 50) |
|
|
822
|
+
| `CONNECTRPC_SOAK_CLEANUP` | 60 | Seconds after the deadline before the process group is killed |
|
|
823
|
+
| `CONNECTRPC_SOAK_SEED` | random | Seed for scenario choices and RSpec order; always recorded |
|
|
824
|
+
| `CONNECTRPC_SOAK_ONLY` | none | Ruby regular expression matched against example descriptions |
|
|
825
|
+
|
|
826
|
+
Extra task arguments go to RSpec, for example
|
|
827
|
+
`mise run async:soak -- soak/drains_soak.rb` or
|
|
828
|
+
`CONNECTRPC_SOAK_ONLY="2a age drain|7 rotation" mise run falcon:soak`.
|
|
829
|
+
|
|
830
|
+
Reports go to `vendor/<pkg>/soak/<Ruby>/`: `campaign.jsonl` gains one line per
|
|
831
|
+
environment record, baseline, round and scenario as they happen, and the
|
|
832
|
+
supervisor renders `summary.md` from it, also after a hang. At the deadline the
|
|
833
|
+
supervisor sends TERM; the child records thread backtraces, Async task trees and
|
|
834
|
+
descriptor targets (TCP sockets with their ports and state) and exits with 124.
|
|
835
|
+
After the cleanup budget the supervisor kills the process group. Any failure,
|
|
836
|
+
deadline or kill exits non-zero. Reproduce a run with its recorded seed. Keep the
|
|
837
|
+
first failure of an intermittent result and its report; do not replace it with a
|
|
838
|
+
later pass. The next run for the same package and Ruby replaces the report, so
|
|
839
|
+
copy `vendor/<pkg>/soak/<Ruby>/` aside before rerunning.
|
|
840
|
+
|
|
841
|
+
`spec/soak_harness_spec.rb` runs in `async:test`. It plants a leaked descriptor,
|
|
842
|
+
thread, Async task, cancellation registration, unretired resource (also one
|
|
843
|
+
that only looks superseded), open round-scoped client, replaced reused
|
|
844
|
+
connection, duplicate handler execution, transient socket-cap overshoot,
|
|
845
|
+
over-cap retained stream bytes, ingress growth after a saturated window and a
|
|
846
|
+
leak in every warmup in small real
|
|
847
|
+
campaigns, and requires each to fail at its intended check. Only the poll that
|
|
848
|
+
detects a planted leak is shortened. Another control requires teardown to run
|
|
849
|
+
every cleanup after a failing one and report the first error.
|
|
850
|
+
|
|
775
851
|
## Official browser development
|
|
776
852
|
|
|
777
853
|
`mise run browser:setup` installs development-only tools under `vendor/browser`;
|
data/lib/connectrpc/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: connectrpc
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- jimeh
|
|
8
8
|
bindir: exe
|
|
9
9
|
cert_chain: []
|
|
10
|
-
date: 2026-11-
|
|
10
|
+
date: 2026-11-17 00:00:00.000000000 Z
|
|
11
11
|
dependencies: []
|
|
12
12
|
description: 'Ruby implementation of the Connect protocol: typed clients, a Net::HTTP
|
|
13
13
|
transport, host-neutral servers and a protoc plugin that generates service modules
|