Bug 769635 - Disabled providers appear on the Deployable Details page
Summary: Disabled providers appear on the Deployable Details page
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: CloudForms Cloud Engine
Classification: Retired
Component: aeolus-conductor
Version: 1.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
Assignee: Tomas Hrcka
QA Contact: wes hayutin
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-12-21 14:46 UTC by Tomas Sedovic
Modified: 2012-08-30 17:13 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-08-30 17:13:06 UTC
Embargoed:


Attachments (Terms of Use)
Patch to correct scope issue (1.12 KB, patch)
2012-01-03 21:09 UTC, John Eckersberg
no flags Details | Diff

Description Tomas Sedovic 2011-12-21 14:46:16 UTC
Description of problem:
Conductor has the ability to disable individual providers. The Image Details page provides no distinction between disabled and enabled providers.

Steps to Reproduce:
1. Go to Administer > Cloud Providers
2. Press the On switch
3. Press OK in the confirmation dialog
4. Create a new image
5. Go to Environments > Images
6. Click on the new image


Actual results:
All the providers and provider accounts are visible.

Expected results:
The disabled providers and accounts should not be displayed at all. This would be consistent with the Deployable Details page where only the enabled providers are shown.

Additional info:
The "Rebuild All" button should take the availability of the provider into an account as well.

Comment 1 Tomas Hrcka 2012-01-03 13:13:14 UTC
fixed in git commit df5f048e28b557eaa72702894c5da4aff3ea95d4

Comment 2 John Eckersberg 2012-01-03 21:09:08 UTC
Created attachment 550534 [details]
Patch to correct scope issue

Comment 3 John Eckersberg 2012-01-03 21:11:05 UTC
This seems to break db:setup

# RAILS_ENV=production rake db:setup
... snip ...
rake aborted!
PGError: ERROR:  relation "providers" does not exist
LINE 1: SELECT "providers".* FROM "providers" WHERE (enabled = 't')
                                  ^
: SELECT "providers".* FROM "providers" WHERE (enabled = 't')

Tasks: TOP => db:setup => db:schema:load => environment


The attached patch corrects this by delaying the evaluation of Provider within the scope context by encapsulating it in a lambda.

Comment 4 Tomas Hrcka 2012-01-05 10:18:18 UTC
(In reply to comment #2)
> Created attachment 550534 [details]
> Patch to correct scope issue

your patch was pushed to master on conductor

Comment 5 Shveta 2012-01-09 14:31:58 UTC
Only enabled providers are visible now.

Environment -- > Images
Import image . I disabled mock and it was not there in the list while importing image .

Then i enabled mock and it appeared in the list.

==============================================

Same for Environment --> Images --> click on any image
only enabled providers are listed.

=========================================

Verified in 

rpm -qa|grep aeolus
aeolus-configure-2.6.0-0.20120105171403gitf0043e8.el6.noarch
aeolus-conductor-doc-0.9.0-0.20120105223209git5e068fe.el6.noarch
rubygem-arel-2.0.10-0.aeolus.el6.noarch
rubygem-rack-mount-0.7.1-3.aeolus.el6.noarch
rubygem-ZenTest-4.3.3-2.aeolus.el6.noarch
rubygem-aeolus-image-0.4.0-0.20120105171419git8108b42.el6.noarch
aeolus-conductor-0.9.0-0.20120105223209git5e068fe.el6.noarch
aeolus-all-0.9.0-0.20120105223209git5e068fe.el6.noarch
rubygem-aeolus-cli-0.4.0-0.20120105171410git2c6b457.el6.noarch
aeolus-conductor-daemons-0.9.0-0.20120105223209git5e068fe.el6.noarch


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