[
https://issues.apache.org/jira/browse/OAK-6445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16102792#comment-16102792
]
Tomek Rękawek commented on OAK-6445:
------------------------------------
[~rombert] - maybe we can be more general here and check whether there are no
cross-mount references? It'll cover the versionables (as creating a versionable
creates a reference between version storage and the node) and other unsupported
cases. It'd be good to re-use CrossMountReferenceValidator to do this, sth like:
{code}
boolean failOnDetection = true;
NodeState root = compositeNodeStore.getRoot();
new EditorHook(() -> new CrossMountReferenceValidator(root, mip,
failOnDetection)).processCommit(EmptyNodeState.EMPTY_NODE, root);
{code}
Also, I thought that we may create some mechanism to check if the mount
configuration has changed and perform the test only then (as it may be a bit
long). Eg. we may give each node store an unique id (eg. {{/:composite-id}}),
save the mount name->id mapping locally (whatever this means) and check if it
didn't changed during the CompositeNodeStore creation. Other tests can reuse
this.
About saving the mapping locally, I see a few options:
* static file inside the repository dir,
* OSGi configuration,
* local segment store, meant to save metadata (eg. composite node store may
require creating a segment node store with role = composite-metadata).
WDYT?
> Ensure mounted node stores don't contain versionable nodes
> ----------------------------------------------------------
>
> Key: OAK-6445
> URL: https://issues.apache.org/jira/browse/OAK-6445
> Project: Jackrabbit Oak
> Issue Type: Sub-task
> Components: composite
> Reporter: Robert Munteanu
> Assignee: Robert Munteanu
> Fix For: 1.8, 1.7.5
>
>
> Since versioning does not work with the CompositeNodeStore mounts, we should
> validate that no versionable nodes exist at mount time.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)