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

WIP reintroduce $publishedNodes and $discardedNodes for partial discard and publish v2 #5386

Closed

Conversation

mhsdesign
Copy link
Member

@mhsdesign mhsdesign commented Nov 30, 2024

initially extracted from #5385 wont be needed for 9.0 just ideas how to calculate the node ids to publish in WorkspaceWasPartiallyDiscared e.g.

The here shown implementation of extractNodeAggregateIdsAndAffectedDimensionSpacePoints to restore the information which nodes were discarded or published, is hard to acquire, as for the discard case we can look through all events that happened - which we are about to discard - while for publish we could decide to look into the information which events were used for the simulation or use the events that come out of the simulation. Ideally they should be the same but there might be edgecases. Maybe we just really need that property at all.

Upgrade instructions

Review instructions

Checklist

  • Code follows the PSR-2 coding style
  • Tests have been created, run and adjusted as needed
  • The PR is created against the lowest maintained branch
  • Reviewer - PR Title is brief but complete and starts with FEATURE|TASK|BUGFIX
  • Reviewer - The first section explains the change briefly for change-logs
  • Reviewer - Breaking Changes are marked with !!! and have upgrade-instructions

…ow calculation of which changes in which dimension will be discarded

or also to be used in the change projection later more easily. Its more straight forward to refer to a interface method than to make this dependent on each event case by case.

TODO Fix this for change node type and change node name as they affect all dsp!
…rded` to allow for future extension to only discard changes in a specific dimension

Also by calculating the `NodeIdsToPublishOrDiscard` by the _actual_ events we can know for sure there is no gibberish in the event.
Previously for example discarding a non-existing node or a node in a not valid DSP would just save that directly into the event, which is not correct as that did not happen like that. It was merely a bad intention.
…hed` in preparation of partial dimension publish ... at some point
@github-actions github-actions bot added the 9.0 label Nov 30, 2024
mhsdesign added a commit to mhsdesign/neos-development-collection that referenced this pull request Nov 30, 2024
reasoning:

- the `publishedNodeIds` were removed on the event, as we dont need it, and it would rise a discussion if we need to keep dimension space points there too or not: see neos#5386 how i archived it.

- instead of now trying to make `WorkspaceWasPartiallyPublished` contain all the information we dont use or need, the idea is to make it dumb. Now its basically just a `WorkspaceWasPublished` and then the other remaining events are applied as if they were carried out by a user.
If we need to add more metadata to the partial publish at some point, that would need a new event id say as we woouldnt be able to mess with the `WorkspaceWasPartiallyPublished` once released.
So by just combining them into one we have the option open to create a `WorkspaceWasPartiallyPublished` again but differently which wil be breaking too but differently. Its just a new event then, no need to migrate data.
@mhsdesign mhsdesign changed the title Feature/poc partial discard and publish v2 WIP reintroduce $publishedNodes and $discardedNodes for partial discard and publish v2 Dec 5, 2024
@mhsdesign
Copy link
Member Author

For now we decided its not worth the hassle to extract $publishedNodes and $discardedNodes extensively if there is no usecase, see #5385

@mhsdesign mhsdesign closed this Dec 5, 2024
neos-bot pushed a commit to neos/contentgraph-doctrinedbaladapter that referenced this pull request Dec 12, 2024
reasoning:

- the `publishedNodeIds` were removed on the event, as we dont need it, and it would rise a discussion if we need to keep dimension space points there too or not: see neos/neos-development-collection#5386 how i archived it.

- instead of now trying to make `WorkspaceWasPartiallyPublished` contain all the information we dont use or need, the idea is to make it dumb. Now its basically just a `WorkspaceWasPublished` and then the other remaining events are applied as if they were carried out by a user.
If we need to add more metadata to the partial publish at some point, that would need a new event id say as we woouldnt be able to mess with the `WorkspaceWasPartiallyPublished` once released.
So by just combining them into one we have the option open to create a `WorkspaceWasPartiallyPublished` again but differently which wil be breaking too but differently. Its just a new event then, no need to migrate data.
neos-bot pushed a commit to neos/contentrepository-core that referenced this pull request Dec 12, 2024
reasoning:

- the `publishedNodeIds` were removed on the event, as we dont need it, and it would rise a discussion if we need to keep dimension space points there too or not: see neos/neos-development-collection#5386 how i archived it.

- instead of now trying to make `WorkspaceWasPartiallyPublished` contain all the information we dont use or need, the idea is to make it dumb. Now its basically just a `WorkspaceWasPublished` and then the other remaining events are applied as if they were carried out by a user.
If we need to add more metadata to the partial publish at some point, that would need a new event id say as we woouldnt be able to mess with the `WorkspaceWasPartiallyPublished` once released.
So by just combining them into one we have the option open to create a `WorkspaceWasPartiallyPublished` again but differently which wil be breaking too but differently. Its just a new event then, no need to migrate data.
neos-bot pushed a commit to neos/neos that referenced this pull request Dec 12, 2024
reasoning:

- the `publishedNodeIds` were removed on the event, as we dont need it, and it would rise a discussion if we need to keep dimension space points there too or not: see neos/neos-development-collection#5386 how i archived it.

- instead of now trying to make `WorkspaceWasPartiallyPublished` contain all the information we dont use or need, the idea is to make it dumb. Now its basically just a `WorkspaceWasPublished` and then the other remaining events are applied as if they were carried out by a user.
If we need to add more metadata to the partial publish at some point, that would need a new event id say as we woouldnt be able to mess with the `WorkspaceWasPartiallyPublished` once released.
So by just combining them into one we have the option open to create a `WorkspaceWasPartiallyPublished` again but differently which wil be breaking too but differently. Its just a new event then, no need to migrate data.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant