Bug 856470

Summary: Should give a friendly prompt when removing database
Product: OKD Reporter: Wei Sun <wsun>
Component: ocAssignee: John (J5) Palmieri <johnp>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: low Docs Contact:
Priority: medium    
Version: 2.xCC: ccoleman, jkeck
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-11-06 18:49:40 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Wei Sun 2012-09-12 05:59:08 UTC
Description of problem:
Should give a friendly prompt when removing database,because if remove database,that maybe makes app using database can't be accessed.

Version-Release number of selected component (if applicable):
rhc 0.98.14
devenv_2156

How reproducible:
always

Steps to Reproduce:
1.follow this
https://github.com/openshift/redmine-2.0-openshift-quickstart
2.remove mysql-5.1
3.
  
Actual results:
When remove mysql-5.1,only prompt success


Expected results:
Give a friendly prompt,like "if you remove this cartridge,app maybe cann't be accessed"

Additional info:
[wsun@localhost redmine]$ rhc app cartridge remove -a redmine -c mysql-5.1 -d
Password: ******

Contacting https://ec2-23-23-16-62.compute-1.amazonaws.com
Response from server:
DEBUG:


Exit Code: 0
api_c: placeholder
broker_c: namespacerhloginsshapp_uuiddebugaltercartridgecart_typeactionapp_nameapi
API version:    1.1.3

RESULT:
Success

Comment 1 Clayton Coleman 2012-09-27 15:35:47 UTC
In the new commands we should require a confirmation to remove carts and delete applications.

Comment 2 Clayton Coleman 2012-10-17 18:42:08 UTC
Fixed and merged into master

Comment 3 Wei Sun 2012-10-18 02:31:54 UTC
verified on devenv_2341
client :rhc 0.99.7

Steps:

1.create an application
2.add mysql to application
rhc cartridge add mysql-5.1 -a $appname
3.remove mysql without --confirm
rhc cartridge remove mysql-5.1 -a $appname


Result:
[sunwei@dhcp-8-229 dev]$ rhc cartridge remove mysql-5.1 -a phptest
Password: ******


RESULT:
Removing a cartridge is a destructive operation that may result in loss of data associated with the cartridge.  You must pass
the --confirm switch to this command in order to to remove the cartridge.