Bug 980739 - [origin_runtime_157] Rollback progress is not correct when adding postgresql-8.4 to a nonscalable app with postgresql-9.2
Summary: [origin_runtime_157] Rollback progress is not correct when adding postgresql-...
Keywords:
Status: CLOSED DUPLICATE of bug 980760
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Hiro Asari
QA Contact: libra bugs
URL:
Whiteboard:
Depends On: 979442 980760 981528 1010846
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-03 07:22 UTC by Qiushui Zhang
Modified: 2015-05-14 23:22 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-03 14:02:12 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Qiushui Zhang 2013-07-03 07:22:45 UTC
Description of problem:
Try to add cartridge postgresql-8.4 to a nonscalable app with postgresql-9.2 twice.
It will fail at the first time, but it will get a success the second time.

If adding postgresql-8.4 first, similar problem happens. 

Version-Release number of selected component (if applicable):
devenv_3441

How reproducible:
Always

Steps to Reproduce:
1. Create a nonscalable app with cartridge postgresql-9.2.
2. Try to add cartridge postgresql-8.4 to it.
3. Try to add postgresql-8.4 again.

Actual results:
It will shows a failure at first.
But cartridge postgresql-8.4 will be added the second time.

Expected results:
The rollback should be done correctly. The second postgresql should not be added.

Additional info:
[walter@dhcp-10-238 tmp]$ rhc app create pq92 jbossas-7 postgresql-9.2
[walter@dhcp-10-238 tmp]$ rhc cartridge add -a pq92 -c postgresql-8.4
Adding postgresql-8.4 to application 'pq92' ... 
createdb: database creation failed: ERROR:  database "pq92" already exists
/var/lib/openshift/51d3c61348d5f908b900000b/postgresql/bin/post_install: line 18: error: command not found
[walter@dhcp-10-238 tmp]$ rhc cartridge add -a pq92 -c postgresql-8.4
Adding postgresql-8.4 to application 'pq92' ... Success

postgresql-8.4 (PostgreSQL Database 8.4)
----------------------------------------
  Gears:          Located with jbossas-7, postgresql-9.2
  Connection URL: postgresql://$OPENSHIFT_POSTGRESQL_DB_HOST:$OPENSHIFT_POSTGRESQL_DB_PORT
  Database Name:  pq92
  Password:       JWH48uDm3rR3
  Username:       adminvwqb9y6

Added postgresql-8.4 to application pq92


postgresql-8.4: Connection URL: postgresql://$OPENSHIFT_POSTGRESQL_DB_HOST:$OPENSHIFT_POSTGRESQL_DB_PORT

PostgreSQL 8.4 database added.  Please make note of these credentials:
   Root User: adminvwqb9y6
   Root Password: JWH48uDm3rR3
   Database Name: pq92
Connection URL: postgresql://$OPENSHIFT_POSTGRESQL_DB_HOST:$OPENSHIFT_POSTGRESQL_DB_PORT

[walter@dhcp-10-238 tmp]$ rhc app show --gears -a pq92
ID                       State   Cartridges                              Size  SSH URL
------------------------ ------- --------------------------------------- ----- ------------------------------------------------------
51d3c61348d5f908b900000b started jbossas-7 postgresql-9.2 postgresql-8.4 small 51d3c61348d5f908b900000b.rhcloud.com

Comment 1 Hiro Asari 2013-07-03 14:02:12 UTC
Multiple versions of postgresql should not be allowed on the same application (see 979442), so we shouldn't get here in the first place.

I'm marking this one as a duplicate of 980760, since disallowing duplicate versions of postgresql should "solve" this problem.

*** This bug has been marked as a duplicate of bug 980760 ***


Note You need to log in before you can comment on or make changes to this bug.