[ 
https://issues.apache.org/jira/browse/JCRVLT-744?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17816524#comment-17816524
 ] 

Jochen commented on JCRVLT-744:
-------------------------------

[~kwin] Sorry, it took me to long to identify me problems and then I did not 
point to the details enough for you to understand. Let me try again:

I our system we have different workspace (like for websites, dam, contacts, 
locations, ...).
When create vault packages, we need to specify, for which workspace the package 
is.

The 'natural' idea was, to add a package property 'workspace' and store it 
there. When importing or assembling the package, our code is getting the 
workspace property and pass the right session to the importer and exporter file 
system.
All of this is fine, when just using archives stored in the file system.

Now we wanted to use the JcrPackageRegistry.
'Naturally' we defined a new workspace ('vaults') for storage of the packages 
in the JCR.

Unfortunately, 
org.apache.jackrabbit.vault.packaging.impl.JcrPackageDefinitionImpl does not 
store our additional property in JCR. The only solution, I see right now, is to 
build some property merging before write and splitting after read - not nice.

The second problem is in 
org.apache.jackrabbit.vault.packaging.impl.JcrPackageManagerImpl. The 
`assemble` functions (with parameter JcrPackage or Node) use the session of the 
'defNode' to do in assemble. There is no way to supply a session for the 
'correct' workspace.
org.apache.jackrabbit.vault.packaging.impl.JcrPackageImpl.extract also has that 
problem.

> Vaults do not handle multi workspace environments
> -------------------------------------------------
>
>                 Key: JCRVLT-744
>                 URL: https://issues.apache.org/jira/browse/JCRVLT-744
>             Project: Jackrabbit FileVault
>          Issue Type: Bug
>          Components: vlt
>            Reporter: Jochen
>            Priority: Major
>
> The vault properties do not specify, for which workspace the package is.
> All the code implicitly assumes, that there is only one workspace.
> There should be a package property specifying the workspace.
> From a supplied session the switch to another workspace can be done via 
> session.getRepository().login(workspaceName)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to