How to Update the Bulk Metadata using Documentum Rest Endpoints

kaushaldhabadge
edited December 17 in Documentum #1

I have request where I have to update the object name of 10000 documents to "DeactivatedDocument" using Documentum Rest Endpoints.

But I'm not sure which endpoints should I use and how to use. I explored /batches endpoint but for that preparing the request body is going to be tough tasks for that I have to walkthrough the for loop which is tedious job.

Can someone help me in finding the right endpoint with URI details and Request body?

Thanks, Kaushal

Answers

  • A DQL update request could do the job but there is no way that I know of to issue one via REST (the dql resource is only for select queries). Even if there was, 10000 objects is a lot to update in a single transaction and you would need to make sure that your database can handle it (e.g. increase rollback segments). Besides, some documents may be locked or immutable, so it may not work at all from a practical standpoint.

    So I guess using the batches resource may be one option. You could also extend Documentum REST and add a custom resource to do this.

    In any case, I find the requirement to rename 10000 documents a bit strange. I don't know what "deactivating" a document means in your context, but there may be other ways to handle this (e.g. changing ACLs).

  • Hello, @Hicham Bahi
    Thanks for your input and looking into it.


    I acknowledge that the DQL endpoint only supports select queries, which translates to read-only. Let me summarize what I really need below:


    Frequently, we move the folder_Aa1 from folder_A to folder_B. Since each folder has a unique attribute name and id (name and id of folder_A or folder_B), the id and name must also change whenever I move the folder Aa1 from folder_A to folder_B.


    I am searching for something that is similar to the Update query.
    I looked into /batches, however it takes a long time for 1000 items for preparing the request body, and it ultimately reaches every endpoint at the rear.

    Thanks, Kaushal

  • So I think your best option is to extend Documentum REST with your own custom resource.