Unsolved
This post is more than 5 years old
19 Posts
0
1635
Deleting lagacy Clips using XAM
We are trying to migrate from Centera SDK to XAM. When setting retention start time (using XAM) on an XSet which was opened with the ClipId (since it was created using Centera SDK), we get a new XUID upon committing the XSet. The original Clip is unchanged. That means that we should delete using he new XUID. Question is how do we delete the orginal CLIPID?
What is a CDF and how do we get to it via XAM api's?
Is there some documentation that explains this?
Are there any documented examples of how to delete legacy data that was stored in Centera using Centera SDK?
We have ClipId of the documents
When I set retention start time -- using XAM, I get a new XUID.
Using FieldIterator - I see that the fields in the original ClipID remained the same. The fields of the object with new XUID, has base starttime and event starttime.
Now I want to delete the object. Using ClipId, when I try xSystem.deleteXSet(xuID) -- I get an error.
How do I delete it?
Lastly, I was not able to reply (or add) to this post (instead I had to update the original discussion) -- Why is that?
thank yo for your help.
mckeown_paul
409 Posts
0
January 10th, 2012 13:00
use the original Content Address to delete the original CDF.
mckeown_paul
409 Posts
0
January 12th, 2012 12:00
In Centera parlance a CLIP is comprised of two things the Content Descriptor File and one or more blobs. So the Centera Clip = CDF + blobs. The Centera CLip is basically = XSet
The CDF is a (typically) small XML file which contains metadata and tags which contain info which link to the blobs on the system and its this that you get the Content Address for.
So when you open the legacy clip using the Content Address and apply retention to it an XSet is created and when you commit the Xset you get back a XUID.
However the existing CDF is still there as well as the new XSet (actually on the Centera its just a special form of CDF). The CDF still links to the blobs so to delete it just use the original Content Address that you used to open the legacy clip
AartiSheth
19 Posts
0
January 12th, 2012 17:00
Paul,
Thank you for responding.
I am still not sure that I understand what to do here, therefore am giving
more details and some files. Hope you can help.
As an example, Lets consider a document stored on Centera.
1) String ClipId=5RLVCRKSA571Je1C6DQO3PEIUUAG416979UE9V0L5QHCICVQE6SJS
2) I run ManageRetention.java -- to set the retention startttime on it.
Basically ManageContent.java
xUID = (XUID) new CenteraXUID(ClipId)
XSet xSet = xSystem.openXSet(xUID, XSet.MODE_UNRESTRICTED);
xSet.setRetentionStarttime("event",false);
XUID newXUID = xSet.commit();
//save newXUID in a file
3) Now to delete the document, my DeleteContent.java does this:
XUID xuID = (XUID) new CenteraXUID(ClipId);
if(!xSystem.accessXSet(xuID, XSystem.ACCESS_DELETE_OK))
System.out.println("XSet not
accessible for deletion.");
else {
if(xSystem.isXSetRetained(xuID))
System.out.println("XSet is under
retention.");
else {
xSystem.deleteXSet(xuID);
System.out.println("XSet deleted");
}
}
Are you suggesting the same thing or should I create xuID using the
newXUID and delete that?
I ran FieldIterator on the Clip before step 2, and after Step2 (with
ClipId), and after Step2 with newXUID.
Not sure if this helps.
Thank you again for your help.
3 Attachments
Doc_13418396_flds_2_AfterRetentionStart_usingClipId.txt
Doc_13418396_flds_AfterRetentionStart_using_newXUID.txt
Doc_13418396_flds_BeforeRetentionStart_usingClipId.txt