It's all about the answers!

Ask a question

Error(java.lang.IllegalStateException: More than 1 metadata storage manager registered for storage type on loading a repository workspace programmatically!

Nandini Math (285) | asked Aug 02 '16, 3:55 a.m.
Hello ,

I am using plain java client api 6.0. I am creating a repository workspace using code : JoinOperations.createWorkspace(repo, selectedStream,
this.readConfiguration.getRepoWorkspaceDesc(), null,monitor);

Workspace is created correctly with all the components.

And i am getting the ISandbox object by using below code :
public ISandbox getSandboxForPath(ILocation sandboxPath)
            throws FileSystemException {
        ISharingManager sharingManager = SharingManager.getInstance();
        // FileSystemCore.getSharingManager();

        Collection<ISandbox> updatedSandBoxList = sharingManager

        ISandbox selSandbox = null;
        for (ISandbox sandboxTemp : updatedSandBoxList) {
            if (sandboxTemp.getRoot().toOSString()
                    .equalsIgnoreCase(sandboxPath.toOSString())) {
                selSandbox = sandboxTemp;
        if (selSandbox == null) {
            selSandbox = getSandbox(sandboxPath, false);
        sharingManager.register(selSandbox, false, null);
        return selSandbox;

    public ISandbox getSandbox(ILocation copyFileAreaRoot, boolean registered) {
        if ((registered)
                && (!ICopyFileAreaManager.instance.copyFileAreaExists(
                        copyFileAreaRoot, 0))) {
            return null;
        return new Sandbox(copyFileAreaRoot);

and am using below code to load repo workspace :
ILoadRule2 loadRule = ILoadRuleFactory.loadRuleFactory.getLoadRule(
                    workspaceconn, lrFileReader, true, monitor);

            ILoadOperation loadoperator = loadRule.getLoadOp(this.sandbox,
                    LoadDilemmaHandler.getDefault(), monitor);;

I get error message "java.lang.IllegalStateException: More than 1 metadata storage manager registered for storage type" at line;

Could you please tell me how i it can be fixed ?

Accepted answer

permanent link
Nandini Math (285) | answered Aug 08 '16, 5:05 a.m.

This was caused due to duplicate entries of jar file in eclipse workspace.
Ralph Schoon selected this answer as the correct answer

Your answer

Register or to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.