cancel
Showing results for 
Search instead for 
Did you mean: 

How To create multiple folder in one call using CMIS api in alfresco

shantprai
Champ in-the-making
Champ in-the-making
Hi,
I am using CMIS api to create folder in alfresco i.e.
newFolderProps.put(PropertyIds.OBJECT_TYPE_ID, "cmis:folder");
newFolderProps.put(PropertyIds.NAME, folderNAme);
createdFolder = reqdFolder.createFolder(newFolderProps);

Here I have one problem that I have to create 100 folders , but this method will create one folder at a time so in this scenerio it will call 100 times same function,
Is there any way to create 100 or more than 100 folder in a single call of alfresco where I can give whole structure to create folder .
So it will increase the performance and send less call to alfresco server.
Please send me reply
2 REPLIES 2

afaust
Legendary Innovator
Legendary Innovator
Hello,

when using CMIS, there is no bulk operation (yet) to create multiple objects in one call. The only (and quite hacky) way to do something like this is by implementing a behaviour in Alfresco that reacts to a specific type of object created and creates a bulk structure - so you'd only have to make one call via CMIS and the behaviour does the rest.
Of course, this introduces a strong coupling between client and server, which should be avoided. But other than this hack, I don't see much hope for your request…

Regards
Axel

shantprai
Champ in-the-making
Champ in-the-making
Hi ,
Thanks for reply , If you find any better way to do same thing please share it
Welcome to the new Hyland Connect. Get started or submit feedback.