• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tari-project / tari / 38604382781
77%

Build:
DEFAULT BRANCH: development
Ran 14 Oct 2026 06:35PM UTC
Jobs 1
Files 801
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

14 Oct 2026 05:10PM UTC coverage: 74.778% (-0.4%) from 75.204%
38604382781

push

github

web-flow
fix(comms): stop culled and idle RPC sessions promptly and bound internal channel sends (#8118)

Description
---

This PR implements SPEC-B parts B2–B7, the RPC server spec from the
comms audit. B1 (handshake off the accept loop) already landed in #8095.
Before this, a culled RPC session kept running and kept its session slot
until its request finished, because the stop signal was only checked
between requests. ACK pings reset the idle timer, so about ten keys
could pin all 100 global slots. Internal channels between the comms
actors could also back up without limit.

There are 7 commits; the later ones fix findings from code review and
security review.

### B2: drop on full for internal channels
- **`utils::mpsc::send_or_drop`.** It waits at most 1 s for room, then
drops the item. Drops log a warning at most once per 10 s per site,
naming the top 3 peers. The count of peers tracked is bounded. They are
counted in `comms_channel_drop_total{site}` when the `metrics` feature
is on.
- **Where it is used:**
- `Protocols::notify`, replacing the 10 s timeout in the connection
manager loop.
  - The peer connection's new-substream event.
- The listener's `PeerConnected` and `PeerInboundConnectFailed` events.
If `PeerConnected` is dropped, the connection is closed, waiting at most
1 s.
- **Never dropped:** `PeerDisconnected` and `PeerViolation`. Losing them
would lose disconnect events and bans.

### B3: culled sessions stop promptly
- The stop signal is now checked everywhere a session can wait: sending
the handshake acceptance, the service call, streaming, every send, and
the close, which is capped at 500 ms once stopped.
- A culled session releases its slot within 1 s.

### B4: ACK does not count as activity
- ACK, FIN and rejected requests no longer reset the idle timer.

### B5: sessions keyed by a unique id
- Sessions are tracked by a server-wide `session_id`, not by the yamux
stream id, which reconnects reuse.
- A session is released however its task en... (continued)

1036 of 1092 new or added lines in 12 files covered. (94.87%)

1080 existing lines in 27 files now uncovered.

126762 of 169517 relevant lines covered (74.78%)

975077.32 hits per line

Uncovered Changes

Lines Coverage ∆ File
25
89.2
1.3% comms/core/src/protocol/rpc/server/mod.rs
10
73.03
0.53% comms/core/src/connection_manager/listener.rs
7
99.13
-0.23% comms/core/src/protocol/rpc/test/smoke.rs
6
96.8
-2.37% comms/core/src/utils/mpsc.rs
5
96.82
comms/core/src/protocol/rpc/server/request_codec.rs
2
88.94
1.91% comms/core/src/connection_manager/peer_connection.rs
1
90.43
-0.88% comms/core/src/protocol/protocols.rs

Coverage Regressions

Lines Coverage ∆ File
529
60.94
-8.36% base_layer/core/src/chain_storage/blockchain_database.rs
266
33.85
-45.7% base_layer/core/src/base_node/rpc/query_service.rs
78
59.26
-1.19% base_layer/core/src/chain_storage/lmdb_db/lmdb_db.rs
61
87.32
-9.0% base_layer/core/src/base_node/sync/header_sync/validator.rs
39
72.12
-4.12% base_layer/core/src/base_node/sync/horizon_state_sync/synchronizer.rs
16
80.91
-1.97% base_layer/core/src/test_helpers/blockchain.rs
13
83.24
-7.03% comms/core/src/connectivity/proactive_dialer.rs
11
50.94
-5.19% base_layer/core/src/base_node/sync/rpc/service.rs
9
64.79
-2.66% base_layer/core/src/chain_storage/db_transaction.rs
8
73.51
0.51% comms/core/src/connectivity/manager.rs
7
75.73
-6.8% base_layer/core/src/blocks/accumulated_data.rs
6
81.82
-9.09% base_layer/common_types/src/types/fixed_hash.rs
6
86.04
-2.7% comms/core/src/protocol/rpc/status.rs
5
68.97
0.0% base_layer/wallet/src/transaction_service/storage/sqlite_db.rs
3
98.98
-0.76% base_layer/core/src/consensus/base_node_consensus_manager.rs
3
87.65
-0.3% base_layer/core/src/proof_of_work/cuckaroo_pow.rs
3
50.67
-4.0% base_layer/core/src/validation/error.rs
3
73.08
-0.07% base_layer/wallet/src/output_manager_service/storage/sqlite_db/mod.rs
3
88.94
1.91% comms/core/src/connection_manager/peer_connection.rs
3
89.2
1.3% comms/core/src/protocol/rpc/server/mod.rs
2
85.32
-0.46% comms/dht/src/network_discovery/rebootstrap.rs
1
98.88
-1.12% base_layer/common_types/src/dammsum.rs
1
81.5
-0.16% base_layer/core/src/chain_storage/lmdb_db/lmdb.rs
1
82.86
1.61% base_layer/core/src/validation/helpers.rs
1
90.92
-0.16% base_layer/p2p/src/services/liveness/service.rs
1
78.72
0.0% base_layer/wallet/src/storage/sqlite_db/wallet.rs
1
81.58
0.66% comms/core/src/connection_manager/manager.rs
Jobs
ID Job ID Ran Files Coverage
1 38604382781.1 14 Oct 2026 06:35PM UTC 801
74.78
GitHub Action Run
Source Files on build 38604382781
  • Tree
  • List 801
  • Changed 49
  • Source Changed 13
  • Coverage Changed 49
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #38604382781
  • 30d1302c on github
  • Prev Build on development (#38579576051)
  • Next Build on development (#38698884399)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc