Borg/pkg
google-labs-jules[bot] 2ff65938ca feat: Circuit breaker for failing domains
Implement a circuit breaker for the website collector to prevent hammering domains that are consistently failing.

The circuit breaker has three states: CLOSED, OPEN, and HALF-OPEN. It tracks failures per-domain and will open the circuit after a configurable number of consecutive failures. After a cooldown period, the circuit will transition to HALF-OPEN and allow a limited number of test requests to check for recovery.

The following command-line flags have been added to the `collect website` command:
- `--no-circuit-breaker`: Disable the circuit breaker
- `--circuit-failures`: Number of failures to trip the circuit breaker
- `--circuit-cooldown`: Cooldown time for the circuit breaker
- `--circuit-success-threshold`: Number of successes to close the circuit breaker
- `--circuit-half-open-requests`: Number of test requests in the half-open state

The implementation also includes:
- A new `circuitbreaker` package with the core logic
- Integration into the `website` package with per-domain tracking
- Improved logging to include the domain name and state changes
- Integration tests to verify the circuit breaker's behavior

Co-authored-by: Snider <631881+Snider@users.noreply.github.com>
2026-02-02 00:59:38 +00:00
..
circuitbreaker feat: Circuit breaker for failing domains 2026-02-02 00:59:38 +00:00
compress feat: Add _Good, _Bad, and _Ugly tests 2025-11-14 10:36:35 +00:00
console feat: Add Borg Console and release workflow 2025-12-27 02:32:31 +00:00
datanode Improve test coverage for datanode and tim packages, and fix cmd tests 2025-11-23 18:58:32 +00:00
github feat: Add _Good, _Bad, and _Ugly tests 2025-11-14 10:36:35 +00:00
logger feat: Improve test coverage and refactor for testability 2025-11-03 18:25:04 +00:00
mocks feat: Improve test coverage and refactor for testability 2025-11-03 16:31:26 +00:00
player feat: v3 streaming with LTHN rolling keys and configurable cadence 2026-01-12 16:01:59 +00:00
pwa feat: Add ChaCha20-Poly1305 encryption and decryption for TIM files (.stim), enhance CLI for encryption format handling (stim), and include metadata inspection support 2025-12-26 01:25:03 +00:00
smsg feat: adaptive bitrate streaming (ABR) for HLS-style encrypted video 2026-01-13 15:40:15 +00:00
stmf feat: Add STMF form encryption and SMSG secure message packages 2025-12-27 00:49:07 +00:00
tarfs feat: Add ChaCha20-Poly1305 encryption and decryption for TIM files (.stim), enhance CLI for encryption format handling (stim), and include metadata inspection support 2025-12-26 01:25:03 +00:00
tim feat: Add ChaCha20-Poly1305 encryption and decryption for TIM files (.stim), enhance CLI for encryption format handling (stim), and include metadata inspection support 2025-12-26 01:25:03 +00:00
trix feat: Add ChaCha20-Poly1305 encryption and decryption for TIM files (.stim), enhance CLI for encryption format handling (stim), and include metadata inspection support 2025-12-26 01:25:03 +00:00
ui feat: Improve test coverage and refactor for testability 2025-11-03 18:25:04 +00:00
vcs feat: Add _Good, _Bad, and _Ugly tests 2025-11-14 10:36:35 +00:00
wasm/stmf feat: adaptive bitrate streaming (ABR) for HLS-style encrypted video 2026-01-13 15:40:15 +00:00
website feat: Circuit breaker for failing domains 2026-02-02 00:59:38 +00:00