How to delete a lot of deployments in validation pending state ?
search cancel

How to delete a lot of deployments in validation pending state ?

book

Article ID: 273694

calendar_today

Updated On:

Products

CA Release Automation - Release Operations Center (Nolio) CA Release Automation - DataManagement Server (Nolio)

Issue/Introduction

If there are hundred of deployments in validation Pending status, it could be complicated and taking time to delete them using GUI

Does exist another method to delete a lot of deployments in validation pending status ?

Environment

Release Automation - All Versions

Resolution

Here is another method :

1- Execute following SQL Query to find all deployments in validation pending status :

Microsoft SQL Server :
select 'START chrome "http://nolio:nolio@localhost:20203/invoke?operation=removeRelease&objectname=releasecenter%3Atype%3DInfo&value0='+LTRIM(STR(id))+'&type0=long"', id, name from rc_releases where currentStage='VALIDATION'
 
MySQL :
select CONCAT('START chrome "http://nolio:nolio@localhost:20203/invoke?operation=removeRelease&objectname=releasecenter%3Atype%3DInfo&value0=',id,'&type0=long"'), id, name from rc_releases where currentStage='VALIDATION';
 
 
Remarks :
nolio:nolio is the user/password for JMX.
localhost : it is the name of NAC. It could be replaced by name of NAC
20203 : is the JMX port (default is 20203)

This query returns the deployments which are in VALIDATION stage
And it gives in first column the url to delete it in JMX

Example :
 
This command opens google chrome with specified url. This url open JMX on localhost NAC with nolio/nolio user and removes the release id=24

START chrome "http://nolio:nolio@localhost:20203/invoke?operation=removeRelease&objectname=releasecenter%3Atype%3DInfo&value0=24&type0=long"

 

2- Check if the deployment name should be deleted and execute the chrome commands in a cmd prompt :

For example you could select 50 url lines and paste them in a cmd :  
 

This will create a google chrome tab for every command line :

Do this with a group of 50 commands. Then close google chrome when all actions are executed and do again the steps with another group of 50.