Take the 2-minute tour ×
Tridion Stack Exchange is a question and answer site for Tridion developers and administrators. It's 100% free, no registration required.

We have unused Publication targets which needs to be deleted and we thought of using the new 2013 Sp1 feature of decommission the targets . We used the below method

 client.DecommissionPublicationTarget("tcm:0-14-65537");

This line executes successfully without any error but the publication target doesn't get deleted. Do we need to perform any other extra steps?

share|improve this question

2 Answers 2

up vote 7 down vote accepted

The documentation states:

Decommissions (takes out of service) a Publication Target, so it can be deleted afterwards.

I would therefore assume that, yes, you need to delete it afterwards yourself.

Something like:

client.Delete("tcm:0-14-65537");

after calling DecommissionPublicationTarget() should be sufficient.

share|improve this answer
    
Thanks David.It worked :) –  Sam Jul 14 at 11:13
2  
That's indeed how it was designed to work, we thought that the actual delete decision should come from the "owner" rather than the API, in case you were just trying to clean up –  Nuno Linhares Jul 14 at 11:38
    
As @Nuno mentioned, by design, but that also makes it useful and a lot more safe. See also my blog post on this tridiondeveloper.com/decommission-a-publication-target and the sample code of how it could be used in a UI extension code.google.com/p/sdl-tridion-world/source/browse/… (note I'm also not deleting the target in my extension, but that could be added by changing a single line of code as David explains). –  Bart Koopman Jul 14 at 11:53

The alternative is to use PowerShell and run:

Clear-TcmPublicationTarget tcm:x-x-x

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.