You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@causeway.apache.org by da...@apache.org on 2026/06/08 10:34:23 UTC

(causeway) 03/17: CAUSEWAY-4025: archives command export manager simplification

This is an automated email from the ASF dual-hosted git repository.

danhaywood pushed a commit to branch CAUSEWAY-4028
in repository https://gitbox.apache.org/repos/asf/causeway.git

commit fd047a2035133be4952eb48806972215e93a1063
Author: Dan Haywood <da...@haywood-associates.co.uk>
AuthorDate: Mon Jun 8 08:57:22 2026 +0100

    CAUSEWAY-4025: archives command export manager simplification
---
 .../.openspec.yaml                                    |  0
 .../design.md                                         |  0
 .../proposal.md                                       |  0
 .../specs/command-export-command-reordering/spec.md   |  0
 .../specs/command-export-known-targets/spec.md        |  0
 .../specs/command-export-manager-command-list/spec.md |  0
 .../tasks.md                                          |  0
 .../specs/command-export-command-reordering/spec.md   | 19 +++++++++++++++----
 openspec/specs/command-export-known-targets/spec.md   |  9 +++++++++
 .../specs/command-export-manager-command-list/spec.md |  6 +++++-
 10 files changed, 29 insertions(+), 5 deletions(-)

diff --git a/openspec/changes/simplify-command-export-manager-commands/.openspec.yaml b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/.openspec.yaml
similarity index 100%
rename from openspec/changes/simplify-command-export-manager-commands/.openspec.yaml
rename to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/.openspec.yaml
diff --git a/openspec/changes/simplify-command-export-manager-commands/design.md b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/design.md
similarity index 100%
rename from openspec/changes/simplify-command-export-manager-commands/design.md
rename to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/design.md
diff --git a/openspec/changes/simplify-command-export-manager-commands/proposal.md b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/proposal.md
similarity index 100%
rename from openspec/changes/simplify-command-export-manager-commands/proposal.md
rename to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/proposal.md
diff --git a/openspec/changes/simplify-command-export-manager-commands/specs/command-export-command-reordering/spec.md b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/specs/command-export-command-reordering/spec.md
similarity index 100%
rename from openspec/changes/simplify-command-export-manager-commands/specs/command-export-command-reordering/spec.md
rename to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/specs/command-export-command-reordering/spec.md
diff --git a/openspec/changes/simplify-command-export-manager-commands/specs/command-export-known-targets/spec.md b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/specs/command-export-known-targets/spec.md
similarity index 100%
rename from openspec/changes/simplify-command-export-manager-commands/specs/command-export-known-targets/spec.md
rename to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/specs/command-export-known-targets/spec.md
diff --git a/openspec/changes/simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md
similarity index 100%
copy from openspec/changes/simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md
copy to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md
diff --git a/openspec/changes/simplify-command-export-manager-commands/tasks.md b/openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/tasks.md
similarity index 100%
rename from openspec/changes/simplify-command-export-manager-commands/tasks.md
rename to openspec/changes/archive/2026-06-08-simplify-command-export-manager-commands/tasks.md
diff --git a/openspec/specs/command-export-command-reordering/spec.md b/openspec/specs/command-export-command-reordering/spec.md
index 88bc7f017be..5bd695285ef 100644
--- a/openspec/specs/command-export-command-reordering/spec.md
+++ b/openspec/specs/command-export-command-reordering/spec.md
@@ -4,25 +4,36 @@
 TBD - created by archiving change add-move-commands-action. Update Purpose after archive.
 ## Requirements
 ### Requirement: Export manager moves selected commands after a target command
-When command-log recording support is `ENABLED`, the export manager SHALL provide an action to move one or more selected exportable commands after a target command.
+When command-log recording support is `ENABLED`, the export manager SHALL provide an action to move one or more selected commands from the unified commands collection after a target command.
 When command-log recording support is `DISABLED`, the export manager MUST disable command movement.
 The action SHALL operate only on commands at or after the export manager baseline.
-The target command choices SHALL include commands at or after the export manager baseline.
+The target command choices SHALL include commands at or after the export manager baseline from the unified commands collection.
 The target command choices MUST exclude every command selected for movement.
 The action MUST reject execution when no commands are selected.
 The action MUST reject execution when the target command is missing.
 The action MUST reject execution when the target command is one of the selected commands.
-The action MUST reject execution when any selected command or target command is outside the baseline-bounded exportable command set.
+The action MUST reject execution when any selected command or target command is outside the baseline-bounded command set.
+The action MUST NOT exclude a selected command or target command merely because its replay state is `EXPORTED`.
 
 #### Scenario: Target choices exclude selected commands
 - **GIVEN** command-log recording support is `ENABLED`
 - **AND** an export manager baseline is set
-- **AND** commands `A`, `B`, and `C` are exportable after the baseline
+- **AND** commands `A`, `B`, and `C` are in the unified commands collection after the baseline
 - **AND** commands `A` and `B` are selected for movement
 - **WHEN** the system provides target choices for the move action
 - **THEN** command `C` is offered as a target choice
 - **AND** commands `A` and `B` are not offered as target choices
 
+#### Scenario: Target choices include exported commands
+- **GIVEN** command-log recording support is `ENABLED`
+- **AND** an export manager baseline is set
+- **AND** command `A` has replay state `UNDEFINED`
+- **AND** command `B` has replay state `EXPORTED`
+- **AND** commands `A` and `B` are in the unified commands collection after the baseline
+- **AND** command `A` is selected for movement
+- **WHEN** the system provides target choices for the move action
+- **THEN** command `B` is offered as a target choice
+
 #### Scenario: Cannot move without a selection
 - **GIVEN** command-log recording support is `ENABLED`
 - **AND** an export manager baseline is set
diff --git a/openspec/specs/command-export-known-targets/spec.md b/openspec/specs/command-export-known-targets/spec.md
index 688a6918f67..e9ee6c31398 100644
--- a/openspec/specs/command-export-known-targets/spec.md
+++ b/openspec/specs/command-export-known-targets/spec.md
@@ -74,10 +74,12 @@ The export manager MUST NOT treat ordinary persisted domain objects as roots mer
 ### Requirement: Export target knowledge follows baseline-bounded export order
 The export manager SHALL evaluate target knowledge using the same command ordering that command export uses for replayable sequences.
 The export manager SHALL use current command timestamps when evaluating baseline-bounded export order.
+The export manager SHALL derive the available export-order context from the unified commands collection rather than from a replay-state-filtered collection.
 When command timestamps have been changed by an export-manager command move action, the changed timestamps SHALL determine whether a command result is earlier or later for target and reference-parameter validation.
 A command result SHALL make a bookmark known only for selected commands that occur later in that ordering.
 A command result MUST NOT make the same bookmark known for an earlier selected command or for another selected command whose ordering is not after the result-producing command.
 A command before the export manager baseline MUST NOT make a target known for the selected export sequence.
+A command's replay state MUST NOT by itself make the command unavailable as an earlier result for export target knowledge when the command is at or after the baseline and participates in the selected export sequence.
 
 #### Scenario: Later result does not validate earlier selected target
 - **GIVEN** an export manager baseline is set
@@ -92,6 +94,13 @@ A command before the export manager baseline MUST NOT make a target known for th
 - **WHEN** a selected later action command targets bookmark `demoCustomer:1`
 - **THEN** the export manager accepts the later command for export
 
+#### Scenario: Exported earlier result validates later selected target
+- **GIVEN** an export manager baseline is set
+- **AND** a selected command with replay state `EXPORTED` has result bookmark `demoCustomer:1`
+- **AND** that selected command appears earlier in export order and at or after the baseline
+- **WHEN** a selected later action command targets bookmark `demoCustomer:1`
+- **THEN** the export manager accepts the later command for export
+
 #### Scenario: Result before baseline does not validate selected target
 - **GIVEN** an export manager baseline is set
 - **AND** a command before the baseline has result bookmark `demoCustomer:1`
diff --git a/openspec/changes/simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md b/openspec/specs/command-export-manager-command-list/spec.md
similarity index 95%
rename from openspec/changes/simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md
rename to openspec/specs/command-export-manager-command-list/spec.md
index 4633d838251..bbbeab64a4b 100644
--- a/openspec/changes/simplify-command-export-manager-commands/specs/command-export-manager-command-list/spec.md
+++ b/openspec/specs/command-export-manager-command-list/spec.md
@@ -1,5 +1,8 @@
-## ADDED Requirements
+# command-export-manager-command-list Specification
 
+## Purpose
+TBD - created by archiving change simplify-command-export-manager-commands. Update Purpose after archive.
+## Requirements
 ### Requirement: Export manager shows one baseline-bounded command collection
 The export manager SHALL expose a collection named `commands`.
 The `commands` collection SHALL contain foreground command log entries at or after the export manager baseline.
@@ -62,3 +65,4 @@ Exporting selected commands MUST NOT remove those commands from the commands col
 - **WHEN** the user views the commands collection
 - **THEN** the replay state for command `A` is visible
 - **AND** the replay state for command `B` is visible
+