ListDeletedObjects returns empty vector for real entity path

Post your questions regarding using the Vault and Fortress API in your programs.

Moderator: SourceGear

Post Reply
surak8
Posts: 16
Joined: Mon Nov 30, 2009 2:04 pm

ListDeletedObjects returns empty vector for real entity path

Post by surak8 » Thu Jan 14, 2010 1:00 pm

When preparing to obliteraate files, ListDeletedObjects works for "$" or "$/" but any real path (i.e. "$/DotNet/DealViewer") returns an empty vector.

My desire is to obliterate only those files associated with projects within a specific entity-path, not the entire repository. Is there any way to do this?

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: ListDeletedObjects returns empty vector for real entity path

Post by Beth » Thu Jan 14, 2010 1:15 pm

At what level did the initial delete occur? If you deleted $/DotNet, then DotNet is the item that is ready to be obliterated.

Just as an FYI, Obliterate and Export/Import are not compatible. If you plant to use Export/Import on that repository, even on a different path, it will fail if Obliterates were performed on the repository.

I'm moving this thread over to the Development Tips (API) section.
Beth Kieler
SourceGear Technical Support

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: ListDeletedObjects returns empty vector for real entity path

Post by jeremy_sg » Thu Jan 14, 2010 2:02 pm

My initial reaction to anyone asking about Obliterate is to discourage them. Obliterate is a long, complicated process, that usually doesn't free up all that much space. Basically, unless you have checked in 200MB binary files and you want to obliterate them, Obliterate is probably not worth it.

Secondly, why aren't you using the Admin Web Client, or the Advanced Obliterate Client power toy?

As for your question, can you post the code that you're using? ListDeletedObjects can only be used on items that are currently in the tree, and is not recursive by default.
Subscribe to the Fortress/Vault blog

surak8
Posts: 16
Joined: Mon Nov 30, 2009 2:04 pm

Re: ListDeletedObjects returns empty vector for real entity path

Post by surak8 » Tue Feb 16, 2010 1:35 pm

I am unable to reproduce this issue following installation of 5.0.3.18802.

My code was:
const string repEnt="$/DotNet/AccountMaint";
ClientInstance ci=ServerOperations.client.ClientInstance;
VaultDeletedObject[] delObjs=ci.ListDeletedObjects(repEnt,true);

As far as Jeremy's comments and questions, the reason I was performing my own Obliterate was because:
1) there is no import utility for PVCS, so I was forced to write one..
2) After running my import utility (20-30 times), client/server performance seemed to degrade noticeably.
3) Obiliterate seemed to return normal speed to client/server.
4) Web client was too cumbersome, and did not know about power tool. No user interface was required for my need to Obliterate, as I needed to clean up old stuff, under a given project-path.

My $/DotNet/Account is a very simple project (see attached image), but $/DotNet/TradeCapture would have been MUCH more difficult clean.
Attachments
post.JPG
Illustrative project hierarchy.
post.JPG (39.23 KiB) Viewed 10102 times

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: ListDeletedObjects returns empty vector for real entity path

Post by Beth » Wed Feb 17, 2010 9:12 am

Thanks for the update. I'm happy to hear it worked after the upgrade.
Beth Kieler
SourceGear Technical Support

Post Reply