32 lines
1.5 KiB
Markdown
32 lines
1.5 KiB
Markdown
## Purpose
|
|
|
|
Canonical specification for force-fetch-command requirements synced from OpenSpec change deltas.
|
|
|
|
## Requirements
|
|
|
|
### Requirement: Operator can trigger immediate news fetch via Python command
|
|
The system SHALL provide a Python command that triggers one immediate news aggregation run outside of the hourly scheduler.
|
|
|
|
#### Scenario: Successful forced fetch invocation
|
|
- **WHEN** an operator runs the documented force-fetch command with valid runtime configuration
|
|
- **THEN** the system executes one full fetch cycle using the existing aggregation pipeline
|
|
- **AND** the command terminates after the run completes
|
|
|
|
#### Scenario: Command does not reconfigure scheduler
|
|
- **WHEN** an operator runs the force-fetch command while the service scheduler exists
|
|
- **THEN** the command performs a one-off run only
|
|
- **AND** scheduler job definitions and cadence remain unchanged
|
|
|
|
### Requirement: Forced fetch reuses existing aggregation behavior
|
|
The system SHALL use the same retry, fallback, deduplication, image processing, and persistence logic as scheduled fetch runs.
|
|
|
|
#### Scenario: Retry and fallback parity
|
|
- **WHEN** the primary news provider request fails during a forced run
|
|
- **THEN** the system applies the configured retry behavior
|
|
- **AND** uses the configured fallback provider path if available
|
|
|
|
#### Scenario: Deduplication parity
|
|
- **WHEN** fetched headlines match existing duplicate rules
|
|
- **THEN** duplicate items are skipped according to existing deduplication policy
|
|
- **AND** only eligible items are persisted
|