Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Serializable i.e. low level commands #5353

Closed
bwaidelich opened this issue Nov 8, 2024 · 3 comments
Closed

Serializable i.e. low level commands #5353

bwaidelich opened this issue Nov 8, 2024 · 3 comments
Assignees

Comments

@bwaidelich
Copy link
Member

bwaidelich commented Nov 8, 2024

Commands are meant to capture the intent of a user to change the state of the system.
But due to the fact that we re-apply commands during a rebase (in order to avoid inconsistencies in the content graph) some commands have a "serialized counter-part" that is (more) idempotent than the original command (e.g. when creating a node, the default values of the schema at the time of the command should be taken into account and not change between rebases).

Those lower-level commands are already marked @internal but they can still be send to ContentRepository::handle() – We should change that by making a clear distinction between actual commands and those internal (aka serialized) commands.

The affected commands are:

  • CreateNodeAggregateWithNode => CreateNodeAggregateWithNodeAndSerializedProperties
  • SetNodeProperties => SetSerializedNodeProperties
  • SetNodeReferences => SetSerializedNodeReferences

and potentially some more to come. e.g. today we discussed that CopyNodesRecursively should have a serialized counter-part too in order to better capture the intent (and to avoid that this command can be used to circumvent constraint checks)

Related: #5054

@bwaidelich
Copy link
Member Author

Note: Those internal commands could be used to for faster processing, e.g. within importers / migrators. But IMO we should go for the separation (and with it for consistent behavior and extension points). If performance is the bottleneck, low-level services could always directly persist events

@bwaidelich
Copy link
Member Author

Note: This can be closed once CopyNodesRecursively is removed from the core

@mhsdesign
Copy link
Member

Copy Nodes is now only a low level command anymore, not public api: #5371 and will be removed

@github-project-automation github-project-automation bot moved this from In Progress 🚧 to Done ✅ in Neos 9.0 Release Board Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

2 participants