17 lines
772 B
Markdown
17 lines
772 B
Markdown
## MODIFIED Requirements
|
|
### Requirement: Optimistic Locking for Task Updates
|
|
The system SHALL use optimistic locking to prevent concurrent update conflicts on tasks.
|
|
|
|
#### Scenario: Concurrent update detected
|
|
- **WHEN** user A and user B both load task at version 1
|
|
- **WHEN** user A saves changes, incrementing version to 2
|
|
- **WHEN** user B attempts to save with version 1
|
|
- **THEN** system returns 409 Conflict error
|
|
- **AND** response includes a human-readable message instructing refresh and retry
|
|
- **AND** response includes the current and provided version numbers
|
|
|
|
#### Scenario: Sequential updates succeed
|
|
- **WHEN** user loads task at version N
|
|
- **WHEN** user saves changes with correct version N
|
|
- **THEN** system accepts update and increments version to N+1
|