Bug 799951

Summary: Cannot create deployable from image
Product: [Retired] CloudForms Cloud Engine Reporter: Jozef Zigmund <jzigmund>
Component: aeolus-conductorAssignee: Scott Seago <sseago>
Status: CLOSED NOTABUG QA Contact: wes hayutin <whayutin>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 1.0.0CC: akarol, deltacloud-maint, ssachdev
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-03-05 13:35:17 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jozef Zigmund 2012-03-05 13:27:24 UTC
Description of problem:
When user try to create an deployable from Image, it will return 

PGError: ERROR: column catalogs.pool_family_id does not exist LINE 1: SELECT COUNT(*) FROM "catalogs" WHERE "catalogs"."pool_famil... ^ : SELECT COUNT(*) FROM "catalogs" WHERE "catalogs"."pool_family_id" = 1


Steps to Reproduce:
1. Create image through UI (New image)
2. Build & push the image
3. Create deployable from Image
  
Actual results:

PGError: ERROR: column catalogs.pool_family_id does not exist LINE 1: SELECT COUNT(*) FROM "catalogs" WHERE "catalogs"."pool_famil... ^ : SELECT COUNT(*) FROM "catalogs" WHERE "catalogs"."pool_family_id" = 1


Expected results:

Created deployable from image


Additional info:

Rails log says the issue is on the line 47

: SELECT COUNT(*) FROM "catalogs" WHERE "catalogs"."pool_family_id" = 1
/usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract_adapter.rb:207:in `log'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/postgresql_adapter.rb:514:in `execute'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/postgresql_adapter.rb:1004:in `select_raw'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/postgresql_adapter.rb:997:in `select'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract/database_statements.rb:7:in `select_all'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract/query_cache.rb:54:in `select_all'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract/query_cache.rb:68:in `cache_sql'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract/query_cache.rb:54:in `select_all'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract/database_statements.rb:13:in `select_one'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/connection_adapters/abstract/database_statements.rb:19:in `select_value'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/relation/calculations.rb:207:in `execute_simple_calculation'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/relation/calculations.rb:182:in `perform_calculation'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/relation/calculations.rb:152:in `calculate'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/relation/calculations.rb:58:in `count'
 /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.10/lib/active_record/relation.rb:92:in `empty?'
 /home/jzigmund/deltacloud/aggregator/src/app/controllers/deployables_controller.rb:47:in `new'

When I dug deeper, the regresion was impelement in patch with commit # 72f4dff0 so I'm assigning this bug to Scott. The PGErr is comming from deployables_controller.rb method load_catalogs.

Comment 1 Jozef Zigmund 2012-03-05 13:35:17 UTC
Sorry I didnt run the newest migration.