Commit 1e6f069
authored
fix(pdpv0): re-enable DELETE in processPendingCleanup to stop RPC flood (#1033)
processPendingCleanup runs on every Filecoin block and calls PieceLive()
for every piece with removed=TRUE in pdp_data_set_pieces. The DELETE that
would remove confirmed-dead pieces from the table was commented out, causing
the list to grow without bound and flood Lotus with EthCalls.
After the b7a8796 fix (lo.Contains pointer comparison bug), pieces are now
correctly marked removed=TRUE for the first time. On calibration nodes with
~2,900 such pieces, this caused ~2,900 PieceLive() EthCalls per block
(~30s interval), overwhelming Lotus RPC and causing i/o timeouts on all
subsequent eth_estimateGas calls. This in turn caused proving tasks to fail,
and after 5 consecutive failures datasets were marked unrecoverable.
Re-enable the DELETE with an AND removed=TRUE guard for safety. PieceLive()
is called immediately before the DELETE and confirms the piece is gone
on-chain, making this safe. The list drains to zero over a few blocks and
the EthCall flood stops permanently.1 parent b23d38d commit 1e6f069
1 file changed
+2
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
177 | 177 | | |
178 | 178 | | |
179 | 179 | | |
180 | | - | |
181 | | - | |
182 | | - | |
| 180 | + | |
183 | 181 | | |
184 | 182 | | |
185 | 183 | | |
| 184 | + | |
186 | 185 | | |
187 | 186 | | |
188 | 187 | | |
| |||
0 commit comments