<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://purl.org/rss/1.0/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:syn="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/">
  <channel rdf:about="http://blog.gmane.org/gmane.comp.lib.deltacloud.devel">
    <title>gmane.comp.lib.deltacloud.devel</title>
    <link>http://blog.gmane.org/gmane.comp.lib.deltacloud.devel</link>
    <description/>
    <syn:updatePeriod>hourly</syn:updatePeriod>
    <syn:updateFrequency>1</syn:updateFrequency>
    <syn:updateBase>1901-01-01T00:00+00:00</syn:updateBase>
    <items>
      <rdf:Seq>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3757"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3756"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3755"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3754"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3753"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3752"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3751"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3750"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3749"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3748"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3747"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3746"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3745"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3744"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3743"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3739"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3738"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3737"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3736"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3735"/>
      </rdf:Seq>
    </items>
    <image rdf:resource="http://gmane.org/img/gmane-25t.png"/>
    <textinput rdf:resource=""/>
  </channel>
  <image rdf:about="http://gmane.org/img/gmane-25t.png">
    <title>Gmane</title>
    <url>http://gmane.org/img/gmane-25t.png</url>
    <link>http://gmane.org</link>
  </image>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3757">
    <title>Model X</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3757</link>
    <description>&lt;pre&gt;In case you didn't hear, Tesla revealed their upcoming model X
yesterday, looks pretty nice:
http://www.teslamotors.com/modelx

-j
_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>Jason Guiditta</dc:creator>
    <dc:date>2012-02-10T20:00:01</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3756">
    <title>JIRA DTACLOUD-127 - Valid Credentials Errors</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3756</link>
    <description>&lt;pre&gt;Gents

Unfortunately you've been away today.

I've some issues with the aforementioned JIRA.  The commit sent to me by 
fvollero:

https://git-wip-us.apache.org/repos/asf?p=deltacloud.git;a=commit;h=2fbc147f9e3041b19f2c89e4d222ba2185486405

does not solve the JIRA.  It only addresses the issue in EC2 Driver.  
This would suffice for the conductor BZ but this really should be fixed 
across the board.

Another fundamental issue is that the Deltacloud Client (ruby) does not 
properly support HTTP Errors.

We at least need the valid_credentials method to properly handle any 
HTTP Errors returned by the server.  But I think its worth noting though 
that properly handling errors really needs to implemented across the 
client as a whole.

I've created a patch for conductor addressing the original BZ: 
https://bugzilla.redhat.com/show_bug.cgi?id=753880 this will fix the BZ 
once the changes are in the client.

I've added some comments to the JIRA explaining the issue with the 
commit and a suggestion on how to handle http errors.

Could you guys let me know how this goes.

Thanks gents

Martyn


_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2012-02-06T17:54:19</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3755">
    <title>Deltacloud Android App</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3755</link>
    <description>&lt;pre&gt;Gentlemen.

After speaking to Michal and Justin.  It sounds like Deltacloud might be 
interested in importing the Android App I build for DC into the DC project.

You guys are free to take it.

It's here: https://github.com/mtaylor/MobileCloudController

Just give me a few days to author the code before you pull it.

Regards

Martyn
_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2012-02-02T14:46:18</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3754">
    <title>Android Deltacloud App</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3754</link>
    <description>&lt;pre&gt;Hi people,

I wrote a native Deltacloud Android App a while back but didn't get 
round to sending it out, I thought now is as good of a time as any to 
get it out there.

You can download the app from here: 
http://martyntaylor.fedorapeople.org/dcdroid.apk

Please check it out, there are one or two minor issues atm.  But all in 
all it does the job.  Please drop me aline if people have 
suggestions/bugs etc... I will get round to setting up a Redmine/BZ 
project soon.

One Note: The app uses the older style "one DC Instance per provider" 
format (Since I wrote the Android client way before the newer format was 
introduced).

Also, I've only tested this on a handful of displays though I written it 
to be compatible with most (though it might not look so great).

Have fun

Martyn



_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2011-11-30T13:01:53</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3753">
    <title>Can I run deltacloudd server in a differentphysical machine?</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3753</link>
    <description>&lt;pre&gt;Hello all!

I have confusion about deltacloudd deployment. I have three cloud
deployments. Can I access all of them via single installation of
deltacloudd?
For example: I have OpenNebula cloud controller in server A, OpenStack
cloud controller in server B and Eucalyptus in server C. Can I install
deltacloud server in server D and install &amp;amp; run deltacloudc client
from server E. If yes, should I install deltacloudd server in each
cloud controller server (A, B, C) or is it possible to install single
deltacloudd server and run it for all three clouds (with different
drivers)?

Kind regards,
Nodir.
_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>Nodir Kodirov</dc:creator>
    <dc:date>2011-11-07T02:42:04</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3752">
    <title>Re: aeolus-configure -p rhevm is not working in latest rpms from testing</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3752</link>
    <description>&lt;pre&gt;
Richard,

I've assigned the BZ to you for triage.  It looks like it might be a 
yaml issue, but ???

Thanks for the heads up,
Mike
_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>Mike Orazi</dc:creator>
    <dc:date>2011-11-03T15:35:01</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3751">
    <title>aeolus-configure -p rhevm is not working inlatest rpms from testing</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3751</link>
    <description>&lt;pre&gt;https://bugzilla.redhat.com/show_bug.cgi?id=751113

_______________________________________________
deltacloud-devel mailing list
deltacloud-devel&amp;lt; at &amp;gt;lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/deltacloud-devel&lt;/pre&gt;</description>
    <dc:creator>wes hayutin</dc:creator>
    <dc:date>2011-11-03T15:00:01</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3750">
    <title>Conductor Image Management API</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3750</link>
    <description>&lt;pre&gt;In order to lock down components, it has been proposed that we offer an API on top of conductor that exposes image management functionality (pretty much what is currently offered by aeolus-image command line).  This would mean that any client wanting to manipulate objects would talk directly with conductor and go through conductor authentication etc...  This gives a central point of contact for image related tasks via the conductor API and also hides the bits and pieces going on in the background, i.e. iwhd and imagefactory, that really a user is not concerned about.

To recap the state of aeolus-image: 
At the moment the rubygem aeolus-image that is used by conductor serves 2 purposes: firstly, it acts as a client lib to iwhd (which conductor uses in the new catalogue functionality); secondly it holds all the logic for the CLI.

So as it stands, we need to:

1) Rip out the object model (iwhd client part) of aeolus-image and place it in a new rubygem; this will serve solely as a client lib rubygem for iwhd and imagefactory called "aeolus-image-resource" (or another better name)

2) Add imagefactory interaction to the iwhd/imagefactory client lib rubygem - aeolus-image-resource.
     This will interface with the new ImageFactory REST API, and will be used to create builds and push images etc...  using the same object model that is currently in place inside aeolus-image, which is used for interfacing with iwhd. This will also replace code that talks to the imagefactorys qmf interface which is in the aeolus-image CLI code.

3) Add to the current REST API in conductor, to add in the extra resources we need:
       images
       builds
       target_images
       provider_images
    This probably just consists of wrapping the aeolus-image-resource calls in the relevant controllers.

4) Update the aeolus-image command libraries to talk directly to conductor API, hopefully using ActiceResource.

5) Add certificate authentication to aeolus-image.

6) Add aeolus-image configuration in conductor, rather than in ~/.aeolus-image, (we probably want to use configure to set this up)
&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2011-09-14T17:10:43</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3749">
    <title>Re: Condor Cloud Driver</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3749</link>
    <description>&lt;pre&gt;[ CC'd incubator list - DOH! ]

On Mon, Jul 11, 2011 at 03:41:06PM -0700, David Lutterkort wrote:

OK, I will start on these today.  Thanks!

    Ian
&lt;/pre&gt;</description>
    <dc:creator>Ian Main</dc:creator>
    <dc:date>2011-07-13T17:03:14</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3748">
    <title>Re: Condor Cloud Driver</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3748</link>
    <description>&lt;pre&gt;
Very cool.

I completely agree that this should be merged into deltacloud proper.
Some notes from looking at the code:

      * Remove 'Copyright ...' from all source files (have a look at the
        other drives for proper headers)
      * There's some trailing whitespace trouble
      * condor_driver.rb:58: Don't set CONDOR_MAPPER_DIR to something
        that's relative to File::dirname(__FILE__) - instead write
        to /var/tmp (we really ought to claim /var/lib/deltacloud for
        things like this)
      * condor_driver.rb (create_instance): I find encoding
        config_server IP and uuid very ugly. Could the config_server IP
        become part of the config of condor-cloud ? Could we use the
        API_PROVIDER for this ? The uuid could be passed in as the
        user_name of the instance. The comment explaining what's
        happening with user_data also doesn't match the code
      * condor_driver.rb (valid_credentials?): something a little less
        hardcoded would be nice ;)
      * condor_driver.rb (remove_key): do we really want to ignore _all_
        exceptions and just log a warning ? If that is really intended,
        it deserves a comment
      * client/base_models.rb: I assume this will be removed, and the
        code will use the standard models from lib/deltacloud/models/
      * there don't seem to be any tests for the actual driver - we will
        need to figure out a plan for adding them

David
&lt;/pre&gt;</description>
    <dc:creator>David Lutterkort</dc:creator>
    <dc:date>2011-07-11T22:41:06</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3747">
    <title>Re: Condor Cloud Driver</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3747</link>
    <description>&lt;pre&gt;
Well one thing at a time I think.  I think getting this into deltacloud
is the next logical step since it is very tightly coupled to deltacloud.
Getting it into the codebase will allow it to be more easily installed.

Once that happens I'll see about spreading the word a bit more.

    Ian
&lt;/pre&gt;</description>
    <dc:creator>Ian Main</dc:creator>
    <dc:date>2011-07-11T20:17:18</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3746">
    <title>Re: Condor Cloud Driver</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3746</link>
    <description>&lt;pre&gt;
Thank you for your work on this, this looks interesting.  The Condor 
grid community will likely find this interesting as a way to enable 
private cloud services on existing compute grids - but you should let 
them know by sending something to condor-users and/or condor-devel.

What's the status on committing the aeolus-condor patches upstream?  I 
think you'd need to provide pointers in DEVELOPERS.txt on how to pull 
from Condor's upstream instead of pulling from aeolus's yum repo before 
you send that community an announcement.

Along the same vein, this seems like it might be a good candidate for a 
contributed module to Condor:

https://condor-wiki.cs.wisc.edu/index.cgi/wiki?p=ContribModules

Has that been considered?  Doing so would increase exposure within the 
Condor community, who would presumeably be the primary user of this project.

&lt;/pre&gt;</description>
    <dc:creator>Lans Carstensen</dc:creator>
    <dc:date>2011-07-10T01:37:52</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3745">
    <title>Condor Cloud Driver</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3745</link>
    <description>&lt;pre&gt;
Howdy Folks,

So Michal and I have been working on a Condor based cloud using
deltacloud as the front end API.  The code base can be found here:

http://git.fedorahosted.org/git/?p=condor-cloud.git

There are still some cleanups and testing to be done but I would like to
get this into Fedora 16 as a feature. I  am hoping you guys can take a
look and let me know if this is acceptable and what needs to be fixed to
make it so.

There are actually two parts to this project, one is the deltacloud
driver, which can be found under the deltacloud-condor-driver directory.
The rest deals with condor configuration and scripts.

I'm thinking I may name this project 'falcondor' as it seems unused and
more interesting :).

Thanks!

        Ian
&lt;/pre&gt;</description>
    <dc:creator>Ian Main</dc:creator>
    <dc:date>2011-07-08T20:06:44</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3744">
    <title>CLI - Formal XML Definition</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3744</link>
    <description>&lt;pre&gt;Providing a formal deffinition of the XML for an API, makes using the API, in particular creating and maintaining client applications that utilise the API much simpler, and far clearer for a developer.  

There are an array of tools that provide class generation, and automatic marshalling and unmarshalling of objects, generated straight from a formally defined XML Document, for ruby, this project looks to offer these functions: https://github.com/rubyjedi/soap4r .  

In my experience writing Java and Android clients, I have found that the time spent creating an XSD or other formal XML definition, repays 10 fold in development time, and also makes keeping clients up to date alot simpler.  For DC Client I ended up writing my own: https://github.com/mtaylor/deltacloud-tools/blob/master/DeltaCloudClient/docs/deltacloud.xsd

But, I think it would be better as a whole to adopt this approach from the start.  It would not only benefit the creation of the CLI but also anyone else who needs to utilise these APIs

Martyn
&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2011-06-07T10:24:44</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3743">
    <title>Re: e2e failing w/rhevm 2.2</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3743</link>
    <description>&lt;pre&gt;Chris,

I have confirmed that entering an Instance name of &amp;gt; 50 characters does indeed cause a: 500 Internal Server Error.  So I am going to assume this is the issue.

This needs to be addressed both in Condor and in the RHEVM Driver.  The Driver should do any validation checks before sending the API request to the BackEnd provider, and thus return an Error message with a more helpful message.

Cheers

Martyn

----- Original Message -----
From: "Chris Lalancette" &amp;lt;clalance-H+wXaHxf7aLQT0dZR+AlfA&amp;lt; at &amp;gt;public.gmane.org&amp;gt;
To: "Martyn Taylor" &amp;lt;mtaylor-H+wXaHxf7aLQT0dZR+AlfA&amp;lt; at &amp;gt;public.gmane.org&amp;gt;
Cc: "Chris Lalancette" &amp;lt;clalance-H+wXaHxf7aLQT0dZR+AlfA&amp;lt; at &amp;gt;public.gmane.org&amp;gt;, "Michael Orazi" &amp;lt;morazi-H+wXaHxf7aLQT0dZR+AlfA&amp;lt; at &amp;gt;public.gmane.org&amp;gt;
Sent: Monday, 23 May, 2011 1:17:04 PM
Subject: Re: e2e failing w/rhevm 2.2

On 05/23/11 - 07:38:12AM, Martyn Taylor wrote:

It is hard to say if this is the exact problem.

The problem I still know about is that condor generates instance names like:

Condor_localhost.localdomain_job#12.0 (or something like that)

Unfortunately, RHEV-M VM names can only be 50 characters, and the above is
always longer than 50 characters.  Whether that causes the above error is
unclear to me, but until we fix that, RHEV-M is not going to work.

&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2011-05-23T13:35:56</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3739">
    <title>Re: Post Installation: New HWP Model</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3739</link>
    <description>&lt;pre&gt;
That is a good sign that the form we use to start an instance may not be
as user friendly as we would like it to be. Any chance we can add some
javascript validation on that form.  

&lt;/pre&gt;</description>
    <dc:creator>wes hayutin</dc:creator>
    <dc:date>2011-03-14T17:00:29</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3738">
    <title>Post Installation: New HWP Model</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3738</link>
    <description>&lt;pre&gt;Gentlemen,

I've noticed a lot of chat around not being able to start instances.

For any of you who are not aware, you now *MUST create a HWP post installation (that matches some back end provider HWP) in order to start an instance.

Documentation for this is found here: http://www.aeolusproject.org/conductor-use.html
&lt;/pre&gt;</description>
    <dc:creator>Martyn Taylor</dc:creator>
    <dc:date>2011-03-14T16:16:17</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3737">
    <title>Re: request for enhancement - injection of fileson instance creation</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3737</link>
    <description>&lt;pre&gt;

What can i do with new vm's in a cloud without discover them and get more configuration to the vm.
If we install a new system from a template we need to do always some steps like install something else to bring up services or put puppet there to bring up services later.
With one injection like firstboot or postcommand, everything is possible then.
Put, for example "firstboot" has always a dependencies to a guest operating system, in which style firstboot is running.
On the other hand, the most cloud providers have the "same/a" range of supported operating systems.

Thomas
&lt;/pre&gt;</description>
    <dc:creator>Thomas von Steiger</dc:creator>
    <dc:date>2011-02-17T23:51:54</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3736">
    <title>Timeout support in deltacloud-client</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3736</link>
    <description>&lt;pre&gt;Hi all,

I want to propose adding timeout capabilities to deltacloud-client. I'm 
seeing problems in Aeolus Conductor where a non-responding provider will 
hang indefinitely until Apache closes the connection. I think the fix is 
to allow deltacloud-client to raise an exception on timeouts instead of 
trying to do so each place Conductor calls out to a provider. (A good 
demonstration of this problem is to attempt to add a provider like 
'http://1.1.1.1:1234/api'.)

rest-client has support for two types of timeout: an 'open_timeout' when 
opening a connection, and a normal 'timeout' for an active connection: 
http://rdoc.info/github/adamwiggins/rest-client/master/RestClient/Resource

I will send a quick patch that adds these two timeouts to the 'request' 
method. I don't know the deltacloud-client code that well, so I'd 
appreciate it if someone could let me know if there is a better way of 
accomplishing this.

Best,
Matt
&lt;/pre&gt;</description>
    <dc:creator>Matt Wagner</dc:creator>
    <dc:date>2011-02-17T19:32:49</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3735">
    <title>Re: Task #197 - Remove any logic forcing one provider only</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3735</link>
    <description>&lt;pre&gt;
Please send new patches to aeolus-devel-TuqUDEhatI4ANWPb/1PvSmm0pvjS0E/A&amp;lt; at &amp;gt;public.gmane.org

Thanks,
&lt;/pre&gt;</description>
    <dc:creator>Chris Lalancette</dc:creator>
    <dc:date>2011-01-27T15:50:51</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3734">
    <title>[PATCH aeolus 5/6] Cucumber tests for Provideraccounts</title>
    <link>http://permalink.gmane.org/gmane.comp.lib.deltacloud.devel/3734</link>
    <description>&lt;pre&gt;From: Jozef Zigmund &amp;lt;jzigmund-H+wXaHxf7aLQT0dZR+AlfA&amp;lt; at &amp;gt;public.gmane.org&amp;gt;

I fixed all Rspecs and Cucumbers for provider_account model. Also I fixed some forgotten renamings.
It was needed change some attributes in migrations.
---
 .../admin/provider_accounts_controller.rb          |   53 ++++++------
 .../controllers/provider_accounts_controller.rb    |   62 +++++++-------
 src/app/models/image.rb                            |    2 +-
 src/app/models/provider.rb                         |   11 ++-
 src/app/models/provider_account.rb                 |    8 +-
 src/app/views/admin/provider_accounts/_mock.haml   |   16 ++++
 .../provider_accounts/_provider_selection.haml     |    2 +-
 src/app/views/admin/provider_accounts/new.haml     |    3 +-
 src/app/views/admin/providers/_form.haml           |    2 +-
 src/app/views/builds/new.haml                      |    6 +-
 src/db/development_structure.sql                   |   89 ++++++++++++++++++++
 ...824_rename_cloud_account_to_provider_account.rb |    3 +-
 ...737_rename_cloud_accout_id_for_instance_keys.rb |    9 ++
 ...123410_rename_cloud_account_id_for_instances.rb |    9 ++
 ..._families_to_provider_accounts_pool_families.rb |   11 +++
 ...l_properties_of_columns_in_provider_accounts.rb |   13 +++
 src/features/provider.feature                      |    7 +-
 src/features/provider_account.feature              |   20 ++---
 .../step_definitions/provider_account_steps.rb     |    2 +-
 src/features/step_definitions/provider_steps.rb    |    6 +-
 src/features/step_definitions/template_steps.rb    |    8 +-
 src/features/template.feature                      |   14 ++--
 src/spec/controllers/builds_controller_spec.rb     |    6 +-
 .../provider_accounts_controller_spec.rb           |   32 ++++----
 src/spec/factories/instance.rb                     |    4 +-
 src/spec/factories/provider.rb                     |    8 +-
 src/spec/factories/provider_account.rb             |    4 +-
 src/spec/models/image_spec.rb                      |    6 +-
 src/spec/models/instance_observer_spec.rb          |   20 ++--
 src/spec/models/instance_spec.rb                   |   14 +--
 src/spec/models/pool_family_spec.rb                |    8 +-
 src/spec/models/provider_account_spec.rb           |   46 +++++-----
 src/spec/models/provider_spec.rb                   |    2 +-
 src/spec/models/quota_spec.rb                      |   48 +++++-----
 .../services/data_service_active_record_spec.rb    |   58 +++++++-------
 35 files changed, 382 insertions(+), 230 deletions(-)
 create mode 100644 src/app/views/admin/provider_accounts/_mock.haml
 create mode 100644 src/db/development_structure.sql
 create mode 100644 src/db/migrate/20110125122737_rename_cloud_accout_id_for_instance_keys.rb
 create mode 100644 src/db/migrate/20110125123410_rename_cloud_account_id_for_instances.rb
 create mode 100644 src/db/migrate/20110125154113_rename_cloud_accounts_pool_families_to_provider_accounts_pool_families.rb
 create mode 100644 src/db/migrate/20110126161751_change_null_properties_of_columns_in_provider_accounts.rb

diff --git a/src/app/controllers/admin/provider_accounts_controller.rb b/src/app/controllers/admin/provider_accounts_controller.rb
index 41319e9..44d3fc6 100644
--- a/src/app/controllers/admin/provider_accounts_controller.rb
+++ b/src/app/controllers/admin/provider_accounts_controller.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -45,65 +45,66 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class Admin::ProviderAccountsController &amp;lt; ApplicationController
   end
 
   def create
-    &amp;lt; at &amp;gt;provider = Provider.find(params[:select_provider])
+    &amp;lt; at &amp;gt;selected_provider = &amp;lt; at &amp;gt;provider = Provider.find(params[:select_provider])
     require_privilege(Privilege::CREATE, ProviderAccount, &amp;lt; at &amp;gt;provider)
 
     &amp;lt; at &amp;gt;providers = Provider.all
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.new(params[:provider_account])
-    &amp;lt; at &amp;gt;cloud_account.provider = &amp;lt; at &amp;gt;provider
-    &amp;lt; at &amp;gt;cloud_account.quota = &amp;lt; at &amp;gt;quota = Quota.new
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.new(params[:provider_account])
+    &amp;lt; at &amp;gt;provider_account.provider = &amp;lt; at &amp;gt;provider
+    &amp;lt; at &amp;gt;provider_account.quota = &amp;lt; at &amp;gt;quota = Quota.new
 
     if params.delete :test_account
-      test_account(&amp;lt; at &amp;gt;cloud_account)
+      test_account(&amp;lt; at &amp;gt;provider_account)
       render :action =&amp;gt; 'new' and return
     end
 
     limit = params[:quota][:maximum_running_instances] if params[:quota]
-    &amp;lt; at &amp;gt;cloud_account.quota.set_maximum_running_instances(limit)
+    &amp;lt; at &amp;gt;provider_account.quota.set_maximum_running_instances(limit)
 
-    if &amp;lt; at &amp;gt;cloud_account.invalid?
-      if not &amp;lt; at &amp;gt;cloud_account.valid_credentials?
+    if &amp;lt; at &amp;gt;provider_account.invalid?
+      if not &amp;lt; at &amp;gt;provider_account.valid_credentials?
         flash.now[:error] = "The entered credential information is incorrect"
-      elsif &amp;lt; at &amp;gt;cloud_account.errors.on(:username)
-        flash.now[:error] = "The access key '#{params[:cloud_account][:username]}' has already been taken."
+      elsif &amp;lt; at &amp;gt;provider_account.errors.on(:username)
+        flash.now[:error] = "The access key '#{params[:provider_account][:username]}' has already been taken."
       else
         flash.now[:error] = "You must fill in all the required fields"
       end
       render :action =&amp;gt; 'new' and return
     end
 
-    &amp;lt; at &amp;gt;cloud_account.pool_families &amp;lt;&amp;lt; PoolFamily.default
-    &amp;lt; at &amp;gt;cloud_account.save!
-    if &amp;lt; at &amp;gt;cloud_account.populate_realms
+    &amp;lt; at &amp;gt;provider_account.pool_families &amp;lt;&amp;lt; PoolFamily.default
+    &amp;lt; at &amp;gt;provider_account.save!
+    if &amp;lt; at &amp;gt;provider_account.populate_realms
       flash[:notice] = "Provider account added."
     end
-    redirect_to admin_provider_account_path(&amp;lt; at &amp;gt;cloud_account)
+    redirect_to admin_provider_account_path(&amp;lt; at &amp;gt;provider_account)
     kick_condor
   end
 
   def edit
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.find(params[:id])
-    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;cloud_account.quota
-    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;cloud_account.provider
-    require_privilege(Privilege::MODIFY,&amp;lt; at &amp;gt;cloud_account)
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.find(params[:id])
+    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;provider_account.quota
+    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;provider_account.provider
+    require_privilege(Privilege::MODIFY,&amp;lt; at &amp;gt;provider_account)
   end
 
   def update
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.find(params[:id])
-    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;cloud_account.provider
-    require_privilege(Privilege::MODIFY,&amp;lt; at &amp;gt;cloud_account)
-    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;cloud_account.quota
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.find(params[:id])
+    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;provider_account.provider
+    require_privilege(Privilege::ACCOUNT_MODIFY, &amp;lt; at &amp;gt;provider)
+    require_privilege(Privilege::MODIFY,&amp;lt; at &amp;gt;provider_account)
+    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;provider_account.quota
 
     if params.delete :test_account
-      test_account(&amp;lt; at &amp;gt;cloud_account)
+      test_account(&amp;lt; at &amp;gt;provider_account)
       render :action =&amp;gt; 'edit' and return
     end
 
     limit = params[:quota][:maximum_running_instances] if params[:quota]
-    &amp;lt; at &amp;gt;cloud_account.quota.set_maximum_running_instances(limit)
-    if &amp;lt; at &amp;gt;cloud_account.update_attributes(params[:cloud_account])
+    &amp;lt; at &amp;gt;provider_account.quota.set_maximum_running_instances(limit)
+    if &amp;lt; at &amp;gt;provider_account.update_attributes(params[:provider_account])
       flash[:notice] = "Cloud Account updated!"
-      redirect_to admin_provider_account_path(&amp;lt; at &amp;gt;cloud_account)
+      redirect_to admin_provider_account_path(&amp;lt; at &amp;gt;provider_account)
     else
       render :action =&amp;gt; :edit
     end
diff --git a/src/app/controllers/provider_accounts_controller.rb b/src/app/controllers/provider_accounts_controller.rb
index a902150..99ca85d 100644
--- a/src/app/controllers/provider_accounts_controller.rb
+++ b/src/app/controllers/provider_accounts_controller.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -36,7 +36,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
 
   def new
     &amp;lt; at &amp;gt;provider = Provider.find(params[:provider_id])
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.new
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.new
     &amp;lt; at &amp;gt;quota = Quota.new
     require_privilege(Privilege::CREATE, CloudAccount, &amp;lt; at &amp;gt;provider)
   end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -44,32 +44,32 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
   def create
     &amp;lt; at &amp;gt;provider = Provider.find(params[:provider_id])
     require_privilege(Privilege::CREATE, ProviderAccount, &amp;lt; at &amp;gt;provider)
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.new(params[:cloud_account])
-    &amp;lt; at &amp;gt;cloud_account.provider = &amp;lt; at &amp;gt;provider
-    &amp;lt; at &amp;gt;cloud_account.quota = &amp;lt; at &amp;gt;quota = Quota.new
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.new(params[:provider_account])
+    &amp;lt; at &amp;gt;provider_account.provider = &amp;lt; at &amp;gt;provider
+    &amp;lt; at &amp;gt;provider_account.quota = &amp;lt; at &amp;gt;quota = Quota.new
 
     if params[:test_account]
-      test_account(&amp;lt; at &amp;gt;cloud_account)
+      test_account(&amp;lt; at &amp;gt;provider_account)
       render :action =&amp;gt; 'new' and return
     end
 
     limit = params[:quota][:maximum_running_instances] if params[:quota]
-    &amp;lt; at &amp;gt;cloud_account.quota.set_maximum_running_instances(limit)
+    &amp;lt; at &amp;gt;provider_account.quota.set_maximum_running_instances(limit)
 
-    if &amp;lt; at &amp;gt;cloud_account.invalid?
-      if not &amp;lt; at &amp;gt;cloud_account.valid_credentials?
+    if &amp;lt; at &amp;gt;provider_account.invalid?
+      if not &amp;lt; at &amp;gt;provider_account.valid_credentials?
         flash.now[:error] = "The entered credential information is incorrect"
-      elsif &amp;lt; at &amp;gt;cloud_account.errors.on(:username)
-        flash.now[:error] = "The access key '#{params[:cloud_account][:username]}' has already been taken."
+      elsif &amp;lt; at &amp;gt;provider_account.errors.on(:username)
+        flash.now[:error] = "The access key '#{params[:provider_account][:username]}' has already been taken."
       else
         flash.now[:error] = "You must fill in all the required fields"
       end
       render :action =&amp;gt; 'new' and return
     end
 
-    &amp;lt; at &amp;gt;cloud_account.pool_families &amp;lt;&amp;lt; PoolFamily.default
-    &amp;lt; at &amp;gt;cloud_account.save!
-    if &amp;lt; at &amp;gt;cloud_account.populate_realms
+    &amp;lt; at &amp;gt;provider_account.pool_families &amp;lt;&amp;lt; PoolFamily.default
+    &amp;lt; at &amp;gt;provider_account.save!
+    if &amp;lt; at &amp;gt;provider_account.populate_realms
       flash[:notice] = "Provider account added."
     end
     redirect_to provider_accounts_path(&amp;lt; at &amp;gt;provider)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -77,10 +77,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
   end
 
   def edit
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.find(params[:id])
-    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;cloud_account.quota
-    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;cloud_account.provider
-    require_privilege(Privilege::MODIFY, &amp;lt; at &amp;gt;cloud_account)
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.find(params[:id])
+    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;provider_account.quota
+    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;provider_account.provider
+    require_privilege(Privilege::MODIFY, &amp;lt; at &amp;gt;provider_account)
   end
 
   def update_accounts
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -89,15 +89,15 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
     &amp;lt; at &amp;gt;providers = Provider.list_for_user(&amp;lt; at &amp;gt;current_user, Privilege::VIEW)
 
     success = true
-    &amp;lt; at &amp;gt;provider.provider_accounts.each do |cloud_account|
-      attributes = params[:cloud_accounts][cloud_account.id.to_s]
+    &amp;lt; at &amp;gt;provider.provider_accounts.each do |provider_account|
+      attributes = params[:provider_accounts][provider_account.id.to_s]
 
       password = attributes[:password]
       # blank password means the user didn't change it -- don't update it then
       if password.blank?
         attributes.delete :password
       end
-      cloud_account.quota.maximum_running_instances = quota_from_string(params[:quota][cloud_account.id.to_s][:maximum_running_instances])
+      provider_account.quota.maximum_running_instances = quota_from_string(params[:quota][provider_account.id.to_s][:maximum_running_instances])
 
       private_cert = attributes[:x509_cert_priv_file]
       unless private_cert.blank?
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -112,8 +112,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
       attributes.delete :x509_cert_pub_file
 
       begin
-        cloud_account.update_attributes!(attributes)
-        cloud_account.quota.save!
+        provider_account.update_attributes!(attributes)
+        provider_account.quota.save!
       rescue
         success = false
       end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -128,14 +128,14 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
   end
 
   def update
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.find(params[:id])
-    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;cloud_account.provider
-    require_privilege(Privilege::MODIFY, &amp;lt; at &amp;gt;cloud_account)
-    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;cloud_account.quota
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.find(params[:id])
+    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;provider_account.provider
+    require_privilege(Privilege::MODIFY, &amp;lt; at &amp;gt;provider_account)
+    &amp;lt; at &amp;gt;quota = &amp;lt; at &amp;gt;provider_account.quota
 
     limit = params[:quota][:maximum_running_instances] if params[:quota]
-    &amp;lt; at &amp;gt;cloud_account.quota.set_maximum_running_instances(limit)
-    if &amp;lt; at &amp;gt;cloud_account.update_attributes(params[:cloud_account])
+    &amp;lt; at &amp;gt;provider_account.quota.set_maximum_running_instances(limit)
+    if &amp;lt; at &amp;gt;provider_account.update_attributes(params[:provider_account])
       flash[:notice] = "Cloud Account updated!"
       redirect_to provider_accounts_path(&amp;lt; at &amp;gt;provider)
     else
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -144,10 +144,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccountsController &amp;lt; ApplicationController
   end
 
   def key
-    &amp;lt; at &amp;gt;cloud_account = ProviderAccount.find(params[:id])
+    &amp;lt; at &amp;gt;provider_account = ProviderAccount.find(params[:id])
     require_privilege(Privilege::MODIFY,&amp;lt; at &amp;gt;provider_account)
-    unless &amp;lt; at &amp;gt;cloud_account.instance_key.nil?
-      render :text =&amp;gt; &amp;lt; at &amp;gt;cloud_account.instance_key.pem
+    unless &amp;lt; at &amp;gt;provider_account.instance_key.nil?
+      render :text =&amp;gt; &amp;lt; at &amp;gt;provider_account.instance_key.pem
     end
   end
 
diff --git a/src/app/models/image.rb b/src/app/models/image.rb
index 0852016..5dd0bbb 100644
--- a/src/app/models/image.rb
+++ b/src/app/models/image.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -52,7 +52,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class Image &amp;lt; ActiveRecord::Base
   INACTIVE_STATES = [STATE_COMPLETE, STATE_FAILED, STATE_CANCELED]
 
   def self.available_targets
-    return YAML.load_file("#{RAILS_ROOT}/config/image_descriptor_targets.yml")
+    Provider::PROVIDERS.invert
   end
 
   def generate_uuid
diff --git a/src/app/models/provider.rb b/src/app/models/provider.rb
index 8539391..37d7026 100644
--- a/src/app/models/provider.rb
+++ b/src/app/models/provider.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -29,7 +29,16 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class Provider &amp;lt; ActiveRecord::Base
   require 'util/deltacloud'
   include PermissionedObject
 
-  PROVIDERS = { 0 =&amp;gt; "mock", 1 =&amp;gt; "AWS", 2 =&amp;gt; "GoGrid" , 3 =&amp;gt; "Rackspace", 4 =&amp;gt; "RHEVM", 5 =&amp;gt; "OpenNebula" }
+  MOCK = 0
+  AWS = 1
+  GOGRID = 2
+  RACKSPACE = 3
+  RHEVM = 4
+  OPENNEBULA = 5
+
+  PROVIDERS = { MOCK =&amp;gt; "mock", AWS =&amp;gt; "AWS",
+    GOGRID =&amp;gt; "GoGrid", RACKSPACE =&amp;gt; "Rackspace", RHEVM =&amp;gt; "RHEVM",
+    OPENNEBULA =&amp;gt; "OpenNebula" }
 
   has_many :provider_accounts, :dependent =&amp;gt; :destroy
   has_many :hardware_profiles, :dependent =&amp;gt; :destroy
diff --git a/src/app/models/provider_account.rb b/src/app/models/provider_account.rb
index 6ec1311..38958fd 100644
--- a/src/app/models/provider_account.rb
+++ b/src/app/models/provider_account.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -50,15 +50,17 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class ProviderAccount &amp;lt; ActiveRecord::Base
   validates_presence_of :username
   validates_uniqueness_of :username, :scope =&amp;gt; :provider_id
   validates_presence_of :password
-  validates_presence_of :account_number
+  validates_presence_of :account_number,:if =&amp;gt; Proc.new{ |account| account.provider.cloud_type == Provider::AWS}
   validate :validate_presence_of_x509_certs
   validate :validate_credentials
 
   # We're using this instead of &amp;lt;tt&amp;gt;validates_presence_of&amp;lt;/tt&amp;gt; helper because
   # we want to show errors on different attributes ending with '_file'.
   def validate_presence_of_x509_certs
-    errors.add(:x509_cert_pub_file, "can't be blank") if x509_cert_pub.blank?
-    errors.add(:x509_cert_priv_file, "can't be blank") if x509_cert_priv.blank?
+    if self.provider.cloud_type == Provider::AWS 
+      errors.add(:x509_cert_pub_file, "can't be blank") if x509_cert_pub.blank?
+      errors.add(:x509_cert_priv_file, "can't be blank") if x509_cert_priv.blank?
+    end
   end
 
   def validate_credentials
diff --git a/src/app/views/admin/provider_accounts/_mock.haml b/src/app/views/admin/provider_accounts/_mock.haml
new file mode 100644
index 0000000..65b5998
--- /dev/null
+++ b/src/app/views/admin/provider_accounts/_mock.haml
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,16 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+%fieldset.clear
+  = label_tag "Account name:"
+  = text_field :provider_account, :label
+%fieldset.clear
+  = label_tag :username, "API Key:"
+  = text_field :provider_account,:username
+%fieldset.clear
+  = label_tag :password, "Secret:"
+  = password_field :provider_account,:password
+  = label_tag "Quota"
+  = text_field :quota, :maximum_running_instances, :title =&amp;gt; t('cloud_accounts.form.quota_instances'), :value =&amp;gt; &amp;lt; at &amp;gt;quota.maximum_running_instances || "unlimited", :id =&amp;gt; "quota_instances", :class =&amp;gt; "grid_3 omega"
+.grid_3.omega
+  (
+  %button.linkbutton.nospace{ :type =&amp;gt; 'submit', :value =&amp;gt; t('cloud_accounts.form.test_account'), :name =&amp;gt; 'test_account', :id =&amp;gt; 'test_account' }&amp;lt;&amp;gt;
+    = t('cloud_accounts.form.test_account')
+  )
diff --git a/src/app/views/admin/provider_accounts/_provider_selection.haml b/src/app/views/admin/provider_accounts/_provider_selection.haml
index 334f314..f767896 100644
--- a/src/app/views/admin/provider_accounts/_provider_selection.haml
+++ b/src/app/views/admin/provider_accounts/_provider_selection.haml
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1,5 +1,5 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 %fieldset#cloud_type.clear
-  = select_tag ("select_provider", options_for_select(&amp;lt; at &amp;gt;providers.map{ |p| [p.name, p.id] }, :selected =&amp;gt; &amp;lt; at &amp;gt;selected_provider.id))
+  = select_tag("select_provider", options_for_select(&amp;lt; at &amp;gt;providers.map{ |p| [p.name, p.id] }, :selected =&amp;gt; &amp;lt; at &amp;gt;selected_provider.id))
   = restful_submit_tag "Choose", 'set_selected_provider',set_selected_provider_admin_provider_accounts_path, 'GET', :class =&amp;gt; 'button'
   = label_tag "Cloud type: "
   = t(Provider::PROVIDERS[&amp;lt; at &amp;gt;selected_provider.cloud_type])
diff --git a/src/app/views/admin/provider_accounts/new.haml b/src/app/views/admin/provider_accounts/new.haml
index 4b45ac1..ef369db 100644
--- a/src/app/views/admin/provider_accounts/new.haml
+++ b/src/app/views/admin/provider_accounts/new.haml
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1,10 +1,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 #details.grid_13
+  = error_messages_for :provider_account
   %h2
     = t('cloud_accounts.new.new_provider_account')
     %label{ :for =&amp;gt; :provider_id }
       Provider
     %fieldset.clear
-    - form_tag (admin_provider_accounts_path, :multipart =&amp;gt; true)  do
+    - form_tag(admin_provider_accounts_path, :multipart =&amp;gt; true)  do
       = render :partial =&amp;gt; 'provider_selection'
       %section
         %p.requirement
diff --git a/src/app/views/admin/providers/_form.haml b/src/app/views/admin/providers/_form.haml
index c980c0a..d262c53 100644
--- a/src/app/views/admin/providers/_form.haml
+++ b/src/app/views/admin/providers/_form.haml
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -13,7 +13,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
   )
 %fieldset.clear
   = form.label :cloud_type
-  = form.select (:cloud_type, Provider::PROVIDERS.collect {|id, cloud_type| [t(cloud_type),id] }, :prompt =&amp;gt; "Select type of provider")
+  = form.select(:cloud_type, Provider::PROVIDERS.collect {|id, cloud_type| [t(cloud_type),id] }, :prompt =&amp;gt; "Select type of provider")
 
 %fieldset.clear
   = form.submit "Save",  :class =&amp;gt; "submit formbutton"
diff --git a/src/app/views/builds/new.haml b/src/app/views/builds/new.haml
index 2cb159e..68f78ce 100644
--- a/src/app/views/builds/new.haml
+++ b/src/app/views/builds/new.haml
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -46,10 +46,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
   %label Choose Provider Format:
   %section.clearfix.gap
     %ul.block
-      - &amp;lt; at &amp;gt;all_targets.each do |target_id, target|
+      - &amp;lt; at &amp;gt;all_targets.each do |target, target_id|
         %li
-        = check_box_tag 'targets[]', target_id, false, :id =&amp;gt; target_id
-        = label_tag target_id, target['name']
+        = check_box_tag 'targets[]', target_id, false, :id =&amp;gt; target
+        = label_tag target
 
   = submit_tag "Submit to Build", :name =&amp;gt; "build"
   = submit_tag "Cancel", :name =&amp;gt; "cancel"
diff --git a/src/db/development_structure.sql b/src/db/development_structure.sql
new file mode 100644
index 0000000..5f9b7d0
--- /dev/null
+++ b/src/db/development_structure.sql
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,89 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+CREATE TABLE "base_permission_objects" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "cloud_accounts_pool_families" ("cloud_account_id" integer NOT NULL, "pool_family_id" integer NOT NULL);
+CREATE TABLE "deployables" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "hardware_profile_map" ("aggregator_hardware_profile_id" integer, "provider_hardware_profile_id" integer);
+CREATE TABLE "hardware_profile_properties" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "kind" varchar(255) NOT NULL, "unit" varchar(255) NOT NULL, "value" varchar(255) NOT NULL, "range_first" varchar(255), "range_last" varchar(255), "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "hardware_profiles" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "external_key" varchar(255) NOT NULL, "name" varchar(1024) NOT NULL, "memory_id" integer, "storage_id" integer, "cpu_id" integer, "architecture_id" integer, "provider_id" integer, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "images" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255), "name" varchar(255) NOT NULL, "build_id" varchar(255), "uri" varchar(255), "status" varchar(255), "target" varchar(255), "template_id" integer, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "instance_events" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "instance_id" integer NOT NULL, "event_type" varchar(255) NOT NULL, "event_time" datetime, "status" varchar(255), "message" varchar(255), "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "instance_hwps" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "memory" varchar(255), "cpu" varchar(255), "architecture" varchar(255), "storage" varchar(255), "lock_version" integer DEFAULT 0);
+CREATE TABLE "instance_keys" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "provider_account_id" integer NOT NULL, "name" varchar(255) NOT NULL, "pem" text, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "instances" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "external_key" varchar(255), "name" varchar(1024) NOT NULL, "hardware_profile_id" integer NOT NULL, "template_id" integer NOT NULL, "realm_id" integer, "owner_id" integer, "pool_id" integer NOT NULL, "provider_account_id" integer, "instance_hwp_id" integer, "public_addresses" varchar(255), "private_addresses" varchar(255), "state" varchar(255), "condor_job_id" varchar(255), "last_error" text(255), "instance_key_id" integer, "lock_version" integer DEFAULT 0, "acc_pending_time" integer DEFAULT 0, "acc_running_time" integer DEFAULT 0, "acc_shutting_down_time" integer DEFAULT 0, "acc_stopped_time" integer DEFAULT 0, "time_last_pending" datetime, "time_last_running" datetime, "time_last_shutting_down" datetime, "time_la
 st_stopped" datetime, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "metadata_objects" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "key" varchar(255) NOT NULL, "value" varchar(255) NOT NULL, "object_type" varchar(255), "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "permissions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "role_id" integer NOT NULL, "user_id" integer NOT NULL, "permission_object_id" integer, "permission_object_type" varchar(255), "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "pool_families" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "description" varchar(255), "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "pools" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "exported_as" varchar(255), "quota_id" integer, "pool_family_id" integer NOT NULL, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "privileges" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "privileges_roles" ("privilege_id" integer NOT NULL, "role_id" integer NOT NULL);
+CREATE TABLE "property_enum_entries" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "hardware_profile_property_id" integer NOT NULL, "value" varchar(255) NOT NULL, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "provider_accounts" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "label" varchar(255) NOT NULL, "username" varchar(255) NOT NULL, "password" varchar(255) NOT NULL, "provider_id" integer NOT NULL, "quota_id" integer, "lock_version" integer DEFAULT 0, "account_number" varchar(255) NOT NULL, "x509_cert_priv" text NOT NULL, "x509_cert_pub" text NOT NULL, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "providers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "cloud_type" integer(255) NOT NULL, "url" varchar(255) NOT NULL, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "quotas" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "running_instances" integer DEFAULT 0, "total_instances" integer DEFAULT 0, "maximum_running_instances" integer, "maximum_total_instances" integer, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "realm_map" ("frontend_realm_id" integer, "backend_realm_id" integer);
+CREATE TABLE "realms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "external_key" varchar(255) NOT NULL, "name" varchar(1024) NOT NULL, "provider_id" integer, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "replicated_images" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "image_id" integer NOT NULL, "provider_id" integer NOT NULL, "provider_image_key" varchar(255), "uploaded" boolean DEFAULT 'f', "registered" boolean DEFAULT 'f');
+CREATE TABLE "roles" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) NOT NULL, "scope" varchar(255) NOT NULL, "lock_version" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL);
+CREATE TABLE "sessions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "session_id" varchar(255) NOT NULL, "data" text, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "user" varchar(255), "type" varchar(255), "action" varchar(255), "state" varchar(255), "task_target_id" integer, "task_target_type" varchar(255), "args" varchar(255), "created_at" datetime, "time_submitted" datetime, "time_started" datetime, "time_ended" datetime, "message" text, "failure_code" varchar(255), "lock_version" integer DEFAULT 0);
+CREATE TABLE "templates" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255) NOT NULL, "xml" blob NOT NULL, "uri" varchar(255), "name" varchar(255), "platform" varchar(255), "platform_version" varchar(255), "architecture" varchar(255), "summary" text, "complete" boolean DEFAULT 'f', "uploaded" boolean DEFAULT 'f', "imported" boolean DEFAULT 'f', "images_count" integer, "created_at" datetime, "updated_at" datetime);
+CREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "login" varchar(255) NOT NULL, "email" varchar(255) NOT NULL, "crypted_password" varchar(255) NOT NULL, "password_salt" varchar(255) NOT NULL, "persistence_token" varchar(255) NOT NULL, "single_access_token" varchar(255) NOT NULL, "perishable_token" varchar(255) NOT NULL, "first_name" varchar(255), "last_name" varchar(255), "quota_id" integer, "login_count" integer DEFAULT 0 NOT NULL, "failed_login_count" integer DEFAULT 0 NOT NULL, "last_request_at" datetime, "current_login_at" datetime, "last_login_at" datetime, "current_login_ip" varchar(255), "last_login_ip" varchar(255), "created_at" datetime, "updated_at" datetime);
+CREATE INDEX "index_sessions_on_session_id" ON "sessions" ("session_id");
+CREATE INDEX "index_sessions_on_updated_at" ON "sessions" ("updated_at");
+CREATE INDEX "index_users_on_last_request_at" ON "users" ("last_request_at");
+CREATE INDEX "index_users_on_login" ON "users" ("login");
+CREATE INDEX "index_users_on_persistence_token" ON "users" ("persistence_token");
+CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version");
+INSERT INTO schema_migrations (version) VALUES ('200909011700');
+
+INSERT INTO schema_migrations (version) VALUES ('20090731200741');
+
+INSERT INTO schema_migrations (version) VALUES ('20090801045212');
+
+INSERT INTO schema_migrations (version) VALUES ('20090802000000');
+
+INSERT INTO schema_migrations (version) VALUES ('20090803000000');
+
+INSERT INTO schema_migrations (version) VALUES ('20090803141507');
+
+INSERT INTO schema_migrations (version) VALUES ('20090804135630');
+
+INSERT INTO schema_migrations (version) VALUES ('20090804140143');
+
+INSERT INTO schema_migrations (version) VALUES ('20090804141600');
+
+INSERT INTO schema_migrations (version) VALUES ('20090804142049');
+
+INSERT INTO schema_migrations (version) VALUES ('20090831140000');
+
+INSERT INTO schema_migrations (version) VALUES ('20090917192602');
+
+INSERT INTO schema_migrations (version) VALUES ('20091008153046');
+
+INSERT INTO schema_migrations (version) VALUES ('20091008153058');
+
+INSERT INTO schema_migrations (version) VALUES ('20091008153106');
+
+INSERT INTO schema_migrations (version) VALUES ('20091019215838');
+
+INSERT INTO schema_migrations (version) VALUES ('20100707000000');
+
+INSERT INTO schema_migrations (version) VALUES ('20100810221250');
+
+INSERT INTO schema_migrations (version) VALUES ('20100830150014');
+
+INSERT INTO schema_migrations (version) VALUES ('20100902081651');
+
+INSERT INTO schema_migrations (version) VALUES ('20101018174458');
+
+INSERT INTO schema_migrations (version) VALUES ('20101021172441');
+
+INSERT INTO schema_migrations (version) VALUES ('20110103160939');
+
+INSERT INTO schema_migrations (version) VALUES ('20110112094108');
+
+INSERT INTO schema_migrations (version) VALUES ('20110117140824');
+
+INSERT INTO schema_migrations (version) VALUES ('20110125122737');
+
+INSERT INTO schema_migrations (version) VALUES ('20110125123410');
\ No newline at end of file
diff --git a/src/db/migrate/20110117140824_rename_cloud_account_to_provider_account.rb b/src/db/migrate/20110117140824_rename_cloud_account_to_provider_account.rb
index 2ccadb4..beaabc5 100644
--- a/src/db/migrate/20110117140824_rename_cloud_account_to_provider_account.rb
+++ b/src/db/migrate/20110117140824_rename_cloud_account_to_provider_account.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -5,6 +5,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; class RenameCloudAccountToProviderAccount &amp;lt; ActiveRecord::Migration
   end
 
   def self.down
-    drop_table :provider_accounts
+    change_column (:providers, :cloud_type, :string, :null =&amp;gt; false)
+    rename_table (:provider_accounts, :cloud_accounts)
   end
 end
diff --git a/src/db/migrate/20110125122737_rename_cloud_accout_id_for_instance_keys.rb b/src/db/migrate/20110125122737_rename_cloud_accout_id_for_instance_keys.rb
new file mode 100644
index 0000000..79acc02
--- /dev/null
+++ b/src/db/migrate/20110125122737_rename_cloud_accout_id_for_instance_keys.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+class RenameCloudAccoutIdForInstanceKeys &amp;lt; ActiveRecord::Migration
+  def self.up
+    rename_column :instance_keys, :cloud_account_id, :provider_account_id
+  end
+
+  def self.down
+    rename_column :instance_keys, :provider_account_id, :cloud_account_id
+  end
+end
diff --git a/src/db/migrate/20110125123410_rename_cloud_account_id_for_instances.rb b/src/db/migrate/20110125123410_rename_cloud_account_id_for_instances.rb
new file mode 100644
index 0000000..674fc2d
--- /dev/null
+++ b/src/db/migrate/20110125123410_rename_cloud_account_id_for_instances.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+class RenameCloudAccountIdForInstances &amp;lt; ActiveRecord::Migration
+  def self.up
+    rename_column :instances, :cloud_account_id, :provider_account_id
+  end
+
+  def self.down
+    rename_column :instances, :provider_account_id, :cloud_account_id
+  end
+end
diff --git a/src/db/migrate/20110125154113_rename_cloud_accounts_pool_families_to_provider_accounts_pool_families.rb b/src/db/migrate/20110125154113_rename_cloud_accounts_pool_families_to_provider_accounts_pool_families.rb
new file mode 100644
index 0000000..d1ae154
--- /dev/null
+++ b/src/db/migrate/20110125154113_rename_cloud_accounts_pool_families_to_provider_accounts_pool_families.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+class RenameCloudAccountsPoolFamiliesToProviderAccountsPoolFamilies &amp;lt; ActiveRecord::Migration
+  def self.up
+    rename_table :cloud_accounts_pool_families, :pool_families_provider_accounts
+    rename_column :pool_families_provider_accounts, :cloud_account_id, :provider_account_id
+  end
+
+  def self.down
+    rename_column :pool_families_provider_accounts, :provider_account_id, :cloud_account_id
+    rename_table :pool_families_provider_accounts, :cloud_accounts_pool_families
+  end
+end
diff --git a/src/db/migrate/20110126161751_change_null_properties_of_columns_in_provider_accounts.rb b/src/db/migrate/20110126161751_change_null_properties_of_columns_in_provider_accounts.rb
new file mode 100644
index 0000000..7e6707e
--- /dev/null
+++ b/src/db/migrate/20110126161751_change_null_properties_of_columns_in_provider_accounts.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+class ChangeNullPropertiesOfColumnsInProviderAccounts &amp;lt; ActiveRecord::Migration
+  def self.up
+    change_column :provider_accounts, :account_number, :string, :null =&amp;gt; true
+    change_column :provider_accounts, :x509_cert_priv, :text, :null =&amp;gt; true
+    change_column :provider_accounts, :x509_cert_pub, :text, :null =&amp;gt; true
+  end
+
+  def self.down
+    change_column :provider_accounts, :account_number, :string, :null =&amp;gt; false
+    change_column :provider_accounts, :x509_cert_priv, :text, :null =&amp;gt; false
+    change_column :provider_accounts, :x509_cert_pub, :text, :null =&amp;gt; false
+  end
+end
diff --git a/src/features/provider.feature b/src/features/provider.feature
index 08704dd..ff9c05b 100644
--- a/src/features/provider.feature
+++ b/src/features/provider.feature
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -35,6 +35,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Providers
     Then I should be on the new admin provider page
     When I fill in "provider[name]" with "testprovider"
     And I fill in "provider[url]" with "http://localhost:3001/api"
+    And I select "Amazon EC2" from "Cloud type"
     And I press "Save"
     Then I should be on the admin providers page
     And I should see "Provider added"
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -64,14 +65,14 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Providers
     And this provider has 5 replicated images
     And this provider has 5 hardware profiles
     And this provider has a realm
-    And this provider has a cloud account
+    And this provider has a provider account
     When I go to the admin providers page
     And I check "provider1" provider
     And I press "Delete"
     And there should not exist a provider named "provider1"
     And there should not be any replicated images
     And there should not be any hardware profiles
-    And there should not be a cloud account
+    And there should not be a provider account
     And there should not be a realm
 
   Scenario: Search for hardware profiles
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -94,4 +95,4 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Providers
     And I press "Search"
     Then I should see "Mock"
     And I should not see "Test"
-    And I should not see "Other"
\ No newline at end of file
+    And I should not see "Other"
diff --git a/src/features/provider_account.feature b/src/features/provider_account.feature
index 964aba2..d4ebd34 100644
--- a/src/features/provider_account.feature
+++ b/src/features/provider_account.feature
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -22,21 +22,17 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Provider Accounts
     When I follow "New Account"
     Then I should be on the new admin provider account page
     And I should see "New Account"
-    When I select "testprovider" from "provider_id"
-    And I fill in "cloud_account[label]" with "testaccount"
-    And I fill in "cloud_account[username]" with "mockuser"
-    And I fill in "cloud_account[password]" with "mockpassword"
+    When I select "testprovider" from "select_provider"
+    And I fill in "provider_account[label]" with "testaccount"
+    And I fill in "provider_account[username]" with "mockuser"
+    And I fill in "provider_account[password]" with "mockpassword"
     And I fill in "quota[maximum_running_instances]" with "13"
-    And I fill in "cloud_account[account_number]" with "222222"
-    And I attach the "private.key" file to "cloud_account[x509_cert_priv_file]"
-    And I attach the "public.key" file to "cloud_account[x509_cert_pub_file]"
     And I press "Add"
     Then I should be on testaccount's provider account page
     And I should see "Provider account added"
     And I should have a provider account named "testaccount"
     And I should see "Properties for testaccount"
     And I should see "Running instances quota: 13"
-    And I should see "Account ID: 222222"
 
   Scenario: Test Provider Account Connection Successful
     Given there is a provider named "testprovider"
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -44,8 +40,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Provider Accounts
     And I am on the admin provider accounts page
     When I follow "New Account"
     Then I should be on the new admin provider account page
-    When I fill in "cloud_account[username]" with "mockuser"
-    And I fill in "cloud_account[password]" with "mockpassword"
+    When I fill in "provider_account[username]" with "mockuser"
+    And I fill in "provider_account[password]" with "mockpassword"
     And I press "Test Account"
     Then I should see "Test Connection Success"
 
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -55,8 +51,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Provider Accounts
     And I am on the admin provider accounts page
     When I follow "New Account"
     Then I should be on the new admin provider account page
-    When I fill in "cloud_account[username]" with "mockuser"
-    And I fill in "cloud_account[password]" with "wrong password"
+    When I fill in "provider_account[username]" with "mockuser"
+    And I fill in "provider_account[password]" with "wrong password"
     And I press "Test Account"
     Then I should see "Test Connection Failed"
 
diff --git a/src/features/step_definitions/provider_account_steps.rb b/src/features/step_definitions/provider_account_steps.rb
index 63620c5..b3ffc09 100644
--- a/src/features/step_definitions/provider_account_steps.rb
+++ b/src/features/step_definitions/provider_account_steps.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -17,7 +17,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; end
 
 Given /^there is a provider account named "([^"]*)"$/ do |label|
   &amp;lt; at &amp;gt;provider = Provider.find_by_name('testprovider')
-  &amp;lt; at &amp;gt;cloud_account = Factory(:mock_cloud_account, :provider =&amp;gt; &amp;lt; at &amp;gt;provider, :label =&amp;gt; label)
+  &amp;lt; at &amp;gt;provider_account = Factory(:mock_provider_account, :provider =&amp;gt; &amp;lt; at &amp;gt;provider, :label =&amp;gt; label)
 end
 
 Given /^there is a second provider account named "([^"]*)"$/ do |label|
diff --git a/src/features/step_definitions/provider_steps.rb b/src/features/step_definitions/provider_steps.rb
index 7dd57a7..4d57030 100644
--- a/src/features/step_definitions/provider_steps.rb
+++ b/src/features/step_definitions/provider_steps.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -49,8 +49,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Given /^this provider has a realm$/ do
   Factory(:realm, :provider =&amp;gt; &amp;lt; at &amp;gt;provider)
 end
 
-Given /^this provider has a cloud account$/ do
-  Factory(:mock_cloud_account, :provider =&amp;gt; &amp;lt; at &amp;gt;provider)
+Given /^this provider has a provider account$/ do
+  Factory(:mock_provider_account, :provider =&amp;gt; &amp;lt; at &amp;gt;provider)
 end
 
 Then /^there should not be any replicated images$/ do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -61,7 +61,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Then /^there should not be any hardware profiles$/ do
   HardwareProfile.find(:all, :conditions =&amp;gt; { :provider_id =&amp;gt; &amp;lt; at &amp;gt;provider.id} ).size.should == 0
 end
 
-Then /^there should not be a cloud account$/ do
+Then /^there should not be a provider account$/ do
   ProviderAccount.find(:all, :conditions =&amp;gt; { :provider_id =&amp;gt; &amp;lt; at &amp;gt;provider.id} ).size.should == 0
 end
 
diff --git a/src/features/step_definitions/template_steps.rb b/src/features/step_definitions/template_steps.rb
index e0ab543..c4f986c 100644
--- a/src/features/step_definitions/template_steps.rb
+++ b/src/features/step_definitions/template_steps.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -92,13 +92,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; When /^I choose this template$/ do
   choose("ids__#{&amp;lt; at &amp;gt;template.id}")
 end
 
-Given /^there is ec2 cloud account$/ do
-  account = Factory.build(:ec2_cloud_account)
+Given /^there is Amazon AWS provider account$/ do
+  account = Factory.build(:ec2_provider_account)
   account.save!
 end
 
-Given /^there is ec2 build for this template$/ do
-  Image.build(&amp;lt; at &amp;gt;template, 'ec2')
+Given /^there is Amazon AWS build for this template$/ do
+  Image.build(&amp;lt; at &amp;gt;template, Provider::AWS)
 end
 
 Given /^there is an imported template$/ do
diff --git a/src/features/template.feature b/src/features/template.feature
index b7d75a8..74ab316 100644
--- a/src/features/template.feature
+++ b/src/features/template.feature
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -91,31 +91,31 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Templates
 
   Scenario: Build template
     Given there is a "mock1" template
-    And there is ec2 cloud account
+    And there is Amazon AWS provider account
     And I am on the templates page
     When I choose this template
     And I press "Build"
     Then I should be on the new template build page
     And I should see "Build Request"
-    When I check "ec2"
+    When I check "Aws"
     And I press "Submit to Build"
     Then I should be on the template builds page
     And I should see "mock1"
 
   Scenario: Build template which is already built
     Given there is a "mock1" template
-    And there is ec2 cloud account
+    And there is Amazon AWS provider account
     And I am on the templates page
-    And there is ec2 build for this template
+    And there is Amazon AWS build for this template
     When I choose this template
     And I press "Build"
     Then I should be on the new template build page
     And I should see "Build Request"
-    When I check "ec2"
+    When I check "Aws"
     And I press "Submit to Build"
     Then I should be on the template builds page
     And I should see "mock1"
-    And I should see "An attempted build of this template for the target 'ec2' already exists"
+    And I should see "An attempted build of this template for the target '1' already exists"
 
   Scenario: Build imported template
     Given there is an imported template
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -166,4 +166,4 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Feature: Manage Templates
     And I press "Search"
     Then I should not see "Test1"
     And I should see "Other"
-    And I should not see "Mock"
\ No newline at end of file
+    And I should not see "Mock"
diff --git a/src/spec/controllers/builds_controller_spec.rb b/src/spec/controllers/builds_controller_spec.rb
index ef4f3d4..3432bef 100644
--- a/src/spec/controllers/builds_controller_spec.rb
+++ b/src/spec/controllers/builds_controller_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -18,19 +18,19 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe BuildsController do
       hydra = Typhoeus::Hydra.hydra
       hydra.stub(:put, %r{http://localhost:9090/templates/.*}).and_return(
         Typhoeus::Response.new(:code =&amp;gt; 200))
-      Factory.create(:mock_cloud_account)
+      Factory.create(:mock_provider_account)
       Factory.create(:mock_provider)
     end
 
     it "should create a new Image" do
       lambda do
-        post :create, :template_id =&amp;gt; &amp;lt; at &amp;gt;template.id, :targets =&amp;gt; ["mock"]
+        post :create, :template_id =&amp;gt; &amp;lt; at &amp;gt;template.id, :targets =&amp;gt; ["0"]
       end.should change(Image, :count).by(1)
     end
 
     it "should create a new ReplicatedImage" do
       lambda do
-        post :create, :template_id =&amp;gt; &amp;lt; at &amp;gt;template.id, :targets =&amp;gt; ["mock"]
+        post :create, :template_id =&amp;gt; &amp;lt; at &amp;gt;template.id, :targets =&amp;gt; ["0"]
       end.should change(ReplicatedImage, :count).by(1)
     end
   end
diff --git a/src/spec/controllers/provider_accounts_controller_spec.rb b/src/spec/controllers/provider_accounts_controller_spec.rb
index 7471b30..6369eab 100644
--- a/src/spec/controllers/provider_accounts_controller_spec.rb
+++ b/src/spec/controllers/provider_accounts_controller_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -4,8 +4,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccountsController do
 
   fixtures :all
   before(:each) do
-    &amp;lt; at &amp;gt;cloud_account = Factory :mock_cloud_account
-    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;cloud_account.provider
+    &amp;lt; at &amp;gt;provider_account = Factory :mock_provider_account
+    &amp;lt; at &amp;gt;provider = &amp;lt; at &amp;gt;provider_account.provider
 
     &amp;lt; at &amp;gt;admin_permission = Permission.create :role =&amp;gt; Role.find(:first, :conditions =&amp;gt; ['name = ?', 'Provider Administrator']),
                                           :permission_object =&amp;gt; &amp;lt; at &amp;gt;provider,
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -23,7 +23,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccountsController do
 
   it "allows test account validity on create when passing test_account param" do
     UserSession.create(&amp;lt; at &amp;gt;admin)
-    post :create, :provider_id =&amp;gt; &amp;lt; at &amp;gt;provider.id, :cloud_account =&amp;gt; {}, :test_account =&amp;gt; true
+    post :create, :provider_id =&amp;gt; &amp;lt; at &amp;gt;provider.id, :provider_account =&amp;gt; {}, :test_account =&amp;gt; true
     response.should be_success
     response.should render_template("new")
     response.flash[:error].should == "Test Connection Failed: Invalid Account Details"
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -31,7 +31,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccountsController do
 
   it "doesn't allow to save provider's account if not valid credentials" do
     UserSession.create(&amp;lt; at &amp;gt;admin)
-    post :create, :provider_id =&amp;gt; &amp;lt; at &amp;gt;provider.id, :cloud_account =&amp;gt; {}
+    post :create, :provider_id =&amp;gt; &amp;lt; at &amp;gt;provider.id, :provider_account =&amp;gt; {}
     response.should be_success
     response.should render_template("new")
     response.flash[:error].should == "The entered credential information is incorrect"
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -39,7 +39,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccountsController do
 
   it "should permit users with account modify permission to access edit cloud account interface" do
     UserSession.create(&amp;lt; at &amp;gt;admin)
-    get :edit, :id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id
+    get :edit, :id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id
     response.should be_success
     response.should render_template("edit")
   end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -47,33 +47,33 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccountsController do
   it "should allow users with account modify password to update a cloud account" do
     UserSession.create(&amp;lt; at &amp;gt;admin)
 
-    &amp;lt; at &amp;gt;cloud_account.password = "foobar"
-    &amp;lt; at &amp;gt;cloud_account.stub!(:valid_credentials?).and_return(true)
-    &amp;lt; at &amp;gt;cloud_account.quota = Quota.new
-    &amp;lt; at &amp;gt;cloud_account.save.should be_true
+    &amp;lt; at &amp;gt;provider_account.password = "foobar"
+    &amp;lt; at &amp;gt;provider_account.stub!(:valid_credentials?).and_return(true)
+    &amp;lt; at &amp;gt;provider_account.quota = Quota.new
+    &amp;lt; at &amp;gt;provider_account.save.should be_true
 
-    post :update, :id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id, :cloud_account =&amp;gt; { :password =&amp;gt; 'mockpassword' }
+    post :update, :id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id, :provider_account =&amp;gt; { :password =&amp;gt; 'mockpassword' }
     response.should redirect_to provider_accounts_path(&amp;lt; at &amp;gt;provider)
-    ProviderAccount.find(&amp;lt; at &amp;gt;cloud_account.id).password.should == "mockpassword"
+    ProviderAccount.find(&amp;lt; at &amp;gt;provider_account.id).password.should == "mockpassword"
   end
 
   it "should allow users with account modify permission to delete a cloud account" do
     UserSession.create(&amp;lt; at &amp;gt;admin)
     lambda do
-      get :destroy, :id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id
+      get :destroy, :id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id
     end.should change(ProviderAccount, :count).by(-1)
     response.should redirect_to provider_accounts_path(&amp;lt; at &amp;gt;provider)
-    ProviderAccount.find_by_id(&amp;lt; at &amp;gt;cloud_account.id).should be_nil
+    ProviderAccount.find_by_id(&amp;lt; at &amp;gt;provider_account.id).should be_nil
   end
 
   it "should deny access to users without account modify permission" do
-    get :edit, :id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id
+    get :edit, :id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id
     response.should_not be_success
 
-    post :update, :id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id, :cloud_account =&amp;gt; { :password =&amp;gt; 'foobar' }
+    post :update, :id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id, :provider_account =&amp;gt; { :password =&amp;gt; 'foobar' }
     response.should_not be_success
 
-    post :destroy, :id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id
+    post :destroy, :id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id
     response.should_not be_success
   end
 
diff --git a/src/spec/factories/instance.rb b/src/spec/factories/instance.rb
index 7533ba9..87938bd 100644
--- a/src/spec/factories/instance.rb
+++ b/src/spec/factories/instance.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -2,7 +2,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Factory.define :instance do |i|
   i.sequence(:name) { |n| "instance#{n}" }
   i.sequence(:external_key) { |n| "key#{n}" }
   i.association :hardware_profile, :factory =&amp;gt; :mock_hwp1
-  i.association :cloud_account, :factory =&amp;gt; :mock_cloud_account
+  i.association :provider_account, :factory =&amp;gt; :mock_provider_account
   i.association :template, :factory =&amp;gt; :template
   i.association :pool, :factory =&amp;gt; :pool
   i.association :owner, :factory =&amp;gt; :user
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -23,6 +23,6 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; end
 
 Factory.define :ec2_instance, :parent =&amp;gt; :instance do |i|
   i.association :hardware_profile, :factory =&amp;gt; :ec2_hwp1
-  i.association :cloud_account, :factory =&amp;gt; :ec2_cloud_account
+  i.association :provider_account, :factory =&amp;gt; :ec2_provider_account
   i.association :instance_key, :factory =&amp;gt; :ec2_instance_key1
 end
diff --git a/src/spec/factories/provider.rb b/src/spec/factories/provider.rb
index 76fb4af..b26cff4 100644
--- a/src/spec/factories/provider.rb
+++ b/src/spec/factories/provider.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1,11 +1,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 Factory.define :provider do |p|
   p.sequence(:name) { |n| "provider#{n}" }
-  p.cloud_type 'mock'
+  p.cloud_type '0'
   p.url { |p| "http://www." + p.name + ".com/api" }
 end
 
 Factory.define :mock_provider, :parent =&amp;gt; :provider do |p|
-  p.cloud_type 'mock'
+  p.cloud_type '0'
   p.url 'http://localhost:3001/api'
   p.hardware_profiles { |hp| [hp.association(:mock_hwp1), hp.association(:mock_hwp2)] }
   p.after_create { |p| p.realms &amp;lt;&amp;lt; Factory(:realm1, :provider =&amp;gt; p) &amp;lt;&amp;lt; Factory(:realm2, :provider =&amp;gt; p) }
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -13,14 +13,14 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; end
 
 Factory.define :mock_provider2, :parent =&amp;gt; :provider do |p|
   p.name 'mock2'
-  p.cloud_type 'mock'
+  p.cloud_type '0'
   p.url 'http://localhost:3001/api'
   p.after_create { |p| p.realms &amp;lt;&amp;lt; Factory(:realm3, :provider =&amp;gt; p) }
 end
 
 Factory.define :ec2_provider, :parent =&amp;gt; :provider do |p|
   p.name 'amazon-ec2'
-  p.cloud_type 'ec2'
+  p.cloud_type '1'
   p.url 'http://localhost:3001/api'
   p.hardware_profiles { |hp| [hp.association(:ec2_hwp1)] }
   p.after_create { |p| p.realms &amp;lt;&amp;lt; Factory(:realm4, :provider =&amp;gt; p) }
diff --git a/src/spec/factories/provider_account.rb b/src/spec/factories/provider_account.rb
index ff42702..dae7047 100644
--- a/src/spec/factories/provider_account.rb
+++ b/src/spec/factories/provider_account.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -8,13 +8,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; Factory.define :provider_account do |f|
   f.association :provider
 end
 
-Factory.define :mock_cloud_account, :parent =&amp;gt; :provider_account do |f|
+Factory.define :mock_provider_account, :parent =&amp;gt; :provider_account do |f|
   f.username "mockuser"
   f.password "mockpassword"
   f.provider { |p| p.association(:mock_provider) }
 end
 
-Factory.define :ec2_cloud_account, :parent =&amp;gt; :provider_account do |f|
+Factory.define :ec2_provider_account, :parent =&amp;gt; :provider_account do |f|
   f.username "mockuser"
   f.password "mockpassword"
   f.provider { |p| p.association(:ec2_provider) }
diff --git a/src/spec/models/image_spec.rb b/src/spec/models/image_spec.rb
index dbd5ba8..e489fb6 100644
--- a/src/spec/models/image_spec.rb
+++ b/src/spec/models/image_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -42,12 +42,12 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Image do
   end
 
   it "should build image if there is provider and cloud account for specified target" do
-    acc = Factory.build(:mock_cloud_account)
+    acc = Factory.build(:mock_provider_account)
     acc.stub!(:valid_credentials?).and_return(true)
     acc.save!
     tpl = Factory.build(:template)
     tpl.save!
-    img = Image.build(tpl, 'mock')
+    img = Image.build(tpl, '0')
     Image.find(img).should == img
     ReplicatedImage.find_by_image_id(img.id).should_not be_nil
   end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -55,7 +55,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Image do
   it "should import image" do
     image = OpenStruct.new(:id =&amp;gt; 'mock', :name =&amp;gt; 'mock', :description =&amp;gt; 'imported mock', :architecture =&amp;gt; 'i386')
     client = mock('DeltaCloud', :feature? =&amp;gt; false, :image =&amp;gt; image)
-    account = Factory.build(:ec2_cloud_account)
+    account = Factory.build(:ec2_provider_account)
     account.stub!(:connect).and_return(client)
     account.stub!(:valid_credentials?).and_return(true)
     account.save!
diff --git a/src/spec/models/instance_observer_spec.rb b/src/spec/models/instance_observer_spec.rb
index be2665e..4acb78c 100644
--- a/src/spec/models/instance_observer_spec.rb
+++ b/src/spec/models/instance_observer_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -3,10 +3,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; require 'spec_helper'
 describe InstanceObserver do
 
   before(:each) do
-   Timecop.travel(Time.local(2008, 9, 1, 10, 5, 0, 0, 0))
-
-   &amp;lt; at &amp;gt;cloud_account_quota = Factory :quota
-   &amp;lt; at &amp;gt;cloud_account = Factory(:mock_cloud_account, :quota_id =&amp;gt; &amp;lt; at &amp;gt;cloud_account_quota.id)
+   &amp;lt; at &amp;gt;provider_account_quota = Factory :quota
+   &amp;lt; at &amp;gt;provider_account = Factory(:mock_provider_account, :quota_id =&amp;gt; &amp;lt; at &amp;gt;provider_account_quota.id)
 
    &amp;lt; at &amp;gt;pool_quota = Factory :quota
    &amp;lt; at &amp;gt;pool = Factory(:pool, :quota_id =&amp;gt; &amp;lt; at &amp;gt;pool_quota.id)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -15,7 +13,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe InstanceObserver do
    &amp;lt; at &amp;gt;user = Factory(:user, :quota_id =&amp;gt; &amp;lt; at &amp;gt;user_quota.id)
 
    &amp;lt; at &amp;gt;hwp = Factory :mock_hwp1
-   &amp;lt; at &amp;gt;instance = Factory(:new_instance, :pool =&amp;gt; &amp;lt; at &amp;gt;pool, :hardware_profile =&amp;gt; &amp;lt; at &amp;gt;hwp, :cloud_account_id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id, :owner =&amp;gt; &amp;lt; at &amp;gt;user)
+   &amp;lt; at &amp;gt;instance = Factory(:new_instance, :pool =&amp;gt; &amp;lt; at &amp;gt;pool, :hardware_profile =&amp;gt; &amp;lt; at &amp;gt;hwp, :provider_account_id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id, :owner =&amp;gt; &amp;lt; at &amp;gt;user)
+
+   Timecop.travel(Time.local(2008, 9, 1, 10, 5, 0, 0, 0))
   end
 
   after(:each) do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -102,14 +102,14 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe InstanceObserver do
   end
 
   it "should not update quota on pool, user and cloud account when an instance is state new" do
-    [&amp;lt; at &amp;gt;cloud_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
+    [&amp;lt; at &amp;gt;provider_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
       quota = Quota.find(quota)
       quota.total_instances.should == 0
     end
   end
 
   it "should update quota on pool, user and cloud account when an instance goes to state pending" do
-    [&amp;lt; at &amp;gt;cloud_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
+    [&amp;lt; at &amp;gt;provider_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
       &amp;lt; at &amp;gt;instance.state = Instance::STATE_PENDING
       &amp;lt; at &amp;gt;instance.save!
 
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -122,7 +122,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe InstanceObserver do
     &amp;lt; at &amp;gt;instance.state = Instance::STATE_CREATE_FAILED
     &amp;lt; at &amp;gt;instance.save!
 
-    [&amp;lt; at &amp;gt;cloud_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
+    [&amp;lt; at &amp;gt;provider_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
       quota = Quota.find(quota)
       quota.total_instances.should == 0
     end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -132,7 +132,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe InstanceObserver do
     &amp;lt; at &amp;gt;instance.state = Instance::STATE_RUNNING
     &amp;lt; at &amp;gt;instance.save!
 
-    [&amp;lt; at &amp;gt;cloud_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
+    [&amp;lt; at &amp;gt;provider_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
       quota = Quota.find(quota.id)
       quota.running_instances.should == 1
       quota.total_instances.should == 1
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -146,7 +146,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe InstanceObserver do
     &amp;lt; at &amp;gt;instance.state = Instance::STATE_SHUTTING_DOWN
     &amp;lt; at &amp;gt;instance.save!
 
-    [&amp;lt; at &amp;gt;cloud_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
+    [&amp;lt; at &amp;gt;provider_account_quota, &amp;lt; at &amp;gt;pool_quota, &amp;lt; at &amp;gt;user_quota].each do |quota|
       quota = Quota.find(quota.id)
 
       quota.running_instances.should == 0
diff --git a/src/spec/models/instance_spec.rb b/src/spec/models/instance_spec.rb
index 625718d..e4d3a9f 100644
--- a/src/spec/models/instance_spec.rb
+++ b/src/spec/models/instance_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -86,16 +86,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Instance do
 
   describe "with time capsule" do
 
-    before(:each) do
-      Timecop.travel(Time.local(2008, 9, 1, 10, 5, 0, 0, 0))
-    end
-
-    after(:each) do
-      Timecop.return
-    end
-
     it "should properly calculate the total time that the instance has been in a monitored state" do
       instance = Factory :new_instance
+      Timecop.travel(Time.local(2008, 9, 1, 10, 5, 0, 0, 0))
 
       [ Instance::STATE_PENDING, Instance::STATE_RUNNING, Instance::STATE_SHUTTING_DOWN, Instance::STATE_STOPPED ].each do |s|
 
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -121,18 +114,19 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Instance do
         instance.total_state_time(s).should &amp;gt;= 3
         instance.total_state_time(s).should &amp;lt;= 4
       end
+      Timecop.return
     end
 
   end
 
   it "should return empty list of instance actions when connect to provider fails" do
     provider = Factory.build(:mock_provider2)
-    cloud_account = Factory.build(:cloud_account, :provider =&amp;gt; provider,
+    cloud_account = Factory.build(:provider_account, :provider =&amp;gt; provider,
                                                   :username =&amp;gt; 'john doe',
                                                   :password =&amp;gt; 'asdf')
     cloud_account.stub!(:connect).and_return(nil)
     cloud_account.stub!(:valid_credentials?).and_return(true)
-    instance = Factory.create(:instance, :cloud_account =&amp;gt; cloud_account)
+    instance = Factory.create(:instance, :provider_account =&amp;gt; cloud_account)
     instance.get_action_list.should be_empty
   end
 
diff --git a/src/spec/models/pool_family_spec.rb b/src/spec/models/pool_family_spec.rb
index 58c18ec..68dfb42 100644
--- a/src/spec/models/pool_family_spec.rb
+++ b/src/spec/models/pool_family_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -5,9 +5,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe PoolFamily do
   before(:each) do
     &amp;lt; at &amp;gt;pool = Factory :pool
     &amp;lt; at &amp;gt;pool_family = &amp;lt; at &amp;gt;pool.pool_family
-    &amp;lt; at &amp;gt;cloud_account = Factory :mock_cloud_account
-    &amp;lt; at &amp;gt;cloud_account.pool_families &amp;lt;&amp;lt; &amp;lt; at &amp;gt;pool_family
-    &amp;lt; at &amp;gt;cloud_account.save!
+    &amp;lt; at &amp;gt;provider_account = Factory :mock_provider_account
+    &amp;lt; at &amp;gt;provider_account.pool_families &amp;lt;&amp;lt; &amp;lt; at &amp;gt;pool_family
+    &amp;lt; at &amp;gt;provider_account.save!
   end
 
   it "should validate default pool family" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -28,7 +28,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe PoolFamily do
 
   it "should have account" do
     &amp;lt; at &amp;gt;pool_family.provider_accounts.size.should == 1
-    &amp;lt; at &amp;gt;pool_family.provider_accounts[0].id.should == &amp;lt; at &amp;gt;cloud_account.id
+    &amp;lt; at &amp;gt;pool_family.provider_accounts[0].id.should == &amp;lt; at &amp;gt;provider_account.id
   end
 
 end
diff --git a/src/spec/models/provider_account_spec.rb b/src/spec/models/provider_account_spec.rb
index 57d0611..48678e8 100644
--- a/src/spec/models/provider_account_spec.rb
+++ b/src/spec/models/provider_account_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -3,33 +3,33 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; require 'spec_helper'
 describe ProviderAccount do
   fixtures :all
   before(:each) do
-    &amp;lt; at &amp;gt;cloud_account = Factory :mock_cloud_account
+    &amp;lt; at &amp;gt;provider_account = Factory :mock_provider_account
   end
 
   it "should not be destroyable if it has instances" do
-    &amp;lt; at &amp;gt;cloud_account.instances &amp;lt;&amp;lt; Instance.new
-    &amp;lt; at &amp;gt;cloud_account.destroyable?.should be_false
-    &amp;lt; at &amp;gt;cloud_account.destroy.should be_false
+    &amp;lt; at &amp;gt;provider_account.instances &amp;lt;&amp;lt; Instance.new
+    &amp;lt; at &amp;gt;provider_account.destroyable?.should be_false
+    &amp;lt; at &amp;gt;provider_account.destroy.should be_false
 
-    &amp;lt; at &amp;gt;cloud_account.instances.clear
-    &amp;lt; at &amp;gt;cloud_account.destroyable?.should be_true
-    &amp;lt; at &amp;gt;cloud_account.destroy.equal?(&amp;lt; at &amp;gt;cloud_account).should be_true
-    &amp;lt; at &amp;gt;cloud_account.should be_frozen
+    &amp;lt; at &amp;gt;provider_account.instances.clear
+    &amp;lt; at &amp;gt;provider_account.destroyable?.should be_true
+    &amp;lt; at &amp;gt;provider_account.destroy.equal?(&amp;lt; at &amp;gt;provider_account).should be_true
+    &amp;lt; at &amp;gt;provider_account.should be_frozen
   end
 
   it "should check the validitiy of the cloud account login credentials" do
     mock_provider = Factory :mock_provider
 
-    invalid_cloud_account = Factory.build(:cloud_account, :username =&amp;gt; "wrong_username", :password =&amp;gt; "wrong_password", :provider =&amp;gt; mock_provider)
-    invalid_cloud_account.should_not be_valid
+    invalid_provider_account = Factory.build(:provider_account, :username =&amp;gt; "wrong_username", :password =&amp;gt; "wrong_password", :provider =&amp;gt; mock_provider)
+    invalid_provider_account.should_not be_valid
 
-    valid_cloud_account = Factory.build(:mock_cloud_account, :provider =&amp;gt; mock_provider)
-    valid_cloud_account.should be_valid
+    valid_provider_account = Factory.build(:mock_provider_account, :provider =&amp;gt; mock_provider)
+    valid_provider_account.should be_valid
   end
 
   it "should fail to create a cloud account if the provider credentials are invalid" do
-    cloud_account = Factory.build(:mock_cloud_account, :password =&amp;gt; "wrong_password")
-    cloud_account.save.should == false
+    provider_account = Factory.build(:mock_provider_account, :password =&amp;gt; "wrong_password")
+    provider_account.save.should == false
   end
 
   it "should create an instance_key if provider is EC2" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -41,18 +41,18 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccount do
     &amp;lt; at &amp;gt;client.stub!(:"feature?").and_return(true)
     &amp;lt; at &amp;gt;client.stub!(:"create_key").and_return(&amp;lt; at &amp;gt;key)
 
-    cloud_account = Factory.build :ec2_cloud_account
-    cloud_account.stub!(:connect).and_return(&amp;lt; at &amp;gt;client)
-    cloud_account.save
-    cloud_account.instance_key.should_not == nil
-    cloud_account.instance_key.pem == "PEM"
-    cloud_account.instance_key.id == "1_user"
+    provider_account = Factory.build :ec2_provider_account
+    provider_account.stub!(:connect).and_return(&amp;lt; at &amp;gt;client)
+    provider_account.save
+    provider_account.instance_key.should_not == nil
+    provider_account.instance_key.pem == "PEM"
+    provider_account.instance_key.id == "1_user"
   end
 
   it "when calling connect and it fails with exception it will return nil" do
     DeltaCloud.should_receive(:new).and_raise(Exception.new)
 
-    &amp;lt; at &amp;gt;cloud_account.connect.should be_nil
+    &amp;lt; at &amp;gt;provider_account.connect.should be_nil
   end
 
   it "should generate credentials xml" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -68,13 +68,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe ProviderAccount do
   &amp;lt;/ec2_credentials&amp;gt;
 &amp;lt;/provider_credentials&amp;gt;
 EOT
-    cloud_account = Factory.build(:mock_cloud_account,
+    provider_account = Factory.build(:mock_provider_account,
                                   :username =&amp;gt; 'user',
                                   :password =&amp;gt; 'pass',
                                   :account_number =&amp;gt; '1234',
                                   :x509_cert_priv =&amp;gt; 'priv_key',
                                   :x509_cert_pub =&amp;gt; 'cert'
                                  )
-    cloud_account.build_credentials.should eql(expected_xml)
+    provider_account.build_credentials.should eql(expected_xml)
   end
 end
diff --git a/src/spec/models/provider_spec.rb b/src/spec/models/provider_spec.rb
index e3af313..7d11633 100644
--- a/src/spec/models/provider_spec.rb
+++ b/src/spec/models/provider_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -66,7 +66,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Provider do
     it "should set valid cloud type" do
       &amp;lt; at &amp;gt;client.driver_name = &amp;lt; at &amp;gt;provider.cloud_type
       &amp;lt; at &amp;gt;provider.cloud_type = nil
-      &amp;lt; at &amp;gt;provider.set_cloud_type!
+      &amp;lt; at &amp;gt;provider.cloud_type = 0
       &amp;lt; at &amp;gt;provider.should be_valid
     end
 
diff --git a/src/spec/models/quota_spec.rb b/src/spec/models/quota_spec.rb
index 9620e83..960b417 100644
--- a/src/spec/models/quota_spec.rb
+++ b/src/spec/models/quota_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -3,8 +3,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; require 'spec_helper'
 describe Quota do
 
   before(:each) do
-   &amp;lt; at &amp;gt;cloud_account_quota = Factory :quota
-   &amp;lt; at &amp;gt;cloud_account = Factory(:mock_cloud_account, :quota_id =&amp;gt; &amp;lt; at &amp;gt;cloud_account_quota.id)
+   &amp;lt; at &amp;gt;provider_account_quota = Factory :quota
+   &amp;lt; at &amp;gt;provider_account = Factory(:mock_provider_account, :quota_id =&amp;gt; &amp;lt; at &amp;gt;provider_account_quota.id)
 
    &amp;lt; at &amp;gt;pool_quota = Factory :quota
    &amp;lt; at &amp;gt;pool = Factory(:pool, :quota_id =&amp;gt; &amp;lt; at &amp;gt;pool_quota.id)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -13,12 +13,12 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Quota do
    &amp;lt; at &amp;gt;user = Factory(:user, :quota_id =&amp;gt; &amp;lt; at &amp;gt;user_quota.id)
 
    &amp;lt; at &amp;gt;hwp = Factory :mock_hwp1
-   &amp;lt; at &amp;gt;instance = Factory(:new_instance, :pool =&amp;gt; &amp;lt; at &amp;gt;pool, :hardware_profile =&amp;gt; &amp;lt; at &amp;gt;hwp, :cloud_account_id =&amp;gt; &amp;lt; at &amp;gt;cloud_account.id, :owner =&amp;gt; &amp;lt; at &amp;gt;user)
+   &amp;lt; at &amp;gt;instance = Factory(:new_instance, :pool =&amp;gt; &amp;lt; at &amp;gt;pool, :hardware_profile =&amp;gt; &amp;lt; at &amp;gt;hwp, :provider_account_id =&amp;gt; &amp;lt; at &amp;gt;provider_account.id, :owner =&amp;gt; &amp;lt; at &amp;gt;user)
   end
 
   it "should return true when asking if an instance can be created/started when there is sufficient quota space" do
-    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == true
-    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == true
+    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == true
+    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == true
   end
 
   it "should return true when asking if an instance can be created/started when using unlimited Quotas" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -28,11 +28,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Quota do
     &amp;lt; at &amp;gt;pool.quota = Factory :unlimited_quota
     &amp;lt; at &amp;gt;pool.save!
 
-    &amp;lt; at &amp;gt;cloud_account.quota = Factory :unlimited_quota
-    &amp;lt; at &amp;gt;cloud_account.save!
+    &amp;lt; at &amp;gt;provider_account.quota = Factory :unlimited_quota
+    &amp;lt; at &amp;gt;provider_account.save!
 
-    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == true
-    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == true
+    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == true
+    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == true
   end
 
   it "should return false when asking if an instance can be created/started when the user quota is reached" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -40,8 +40,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Quota do
     &amp;lt; at &amp;gt;user_quota.running_instances = &amp;lt; at &amp;gt;user_quota.maximum_running_instances
     &amp;lt; at &amp;gt;user_quota.save!
 
-    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
-    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
+    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
+    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
   end
 
   it "should return false when asking if an instance can be created/started when the pool quota is reached" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -49,17 +49,17 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Quota do
     &amp;lt; at &amp;gt;pool_quota.running_instances = &amp;lt; at &amp;gt;pool_quota.maximum_running_instances
     &amp;lt; at &amp;gt;pool_quota.save!
 
-    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
-    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
+    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
+    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
   end
 
   it "should return false when asking if an instance can be created/started when the cloud account quota is reached" do
-    &amp;lt; at &amp;gt;cloud_account_quota.total_instances = &amp;lt; at &amp;gt;cloud_account_quota.maximum_total_instances
-    &amp;lt; at &amp;gt;cloud_account_quota.running_instances = &amp;lt; at &amp;gt;cloud_account_quota.maximum_running_instances
-    &amp;lt; at &amp;gt;cloud_account_quota.save!
+    &amp;lt; at &amp;gt;provider_account_quota.total_instances = &amp;lt; at &amp;gt;provider_account_quota.maximum_total_instances
+    &amp;lt; at &amp;gt;provider_account_quota.running_instances = &amp;lt; at &amp;gt;provider_account_quota.maximum_running_instances
+    &amp;lt; at &amp;gt;provider_account_quota.save!
 
-    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
-    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
+    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
+    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
   end
 
   it "should return false when asking if an instance can be created/started when the all quotas are reached" do
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -71,12 +71,12 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe Quota do
     &amp;lt; at &amp;gt;pool_quota.running_instances = &amp;lt; at &amp;gt;pool_quota.maximum_running_instances
     &amp;lt; at &amp;gt;pool_quota.save!
 
-    &amp;lt; at &amp;gt;cloud_account_quota.total_instances = &amp;lt; at &amp;gt;cloud_account_quota.maximum_total_instances
-    &amp;lt; at &amp;gt;cloud_account_quota.running_instances = &amp;lt; at &amp;gt;cloud_account_quota.maximum_running_instances
-    &amp;lt; at &amp;gt;cloud_account_quota.save!
+    &amp;lt; at &amp;gt;provider_account_quota.total_instances = &amp;lt; at &amp;gt;provider_account_quota.maximum_total_instances
+    &amp;lt; at &amp;gt;provider_account_quota.running_instances = &amp;lt; at &amp;gt;provider_account_quota.maximum_running_instances
+    &amp;lt; at &amp;gt;provider_account_quota.save!
 
-    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
-    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;cloud_account).should == false
+    Quota.can_create_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
+    Quota.can_start_instance?(&amp;lt; at &amp;gt;instance, &amp;lt; at &amp;gt;provider_account).should == false
   end
 
-end
\ No newline at end of file
+end
diff --git a/src/spec/services/data_service_active_record_spec.rb b/src/spec/services/data_service_active_record_spec.rb
index b443fa9..45b07bf 100644
--- a/src/spec/services/data_service_active_record_spec.rb
+++ b/src/spec/services/data_service_active_record_spec.rb
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -11,13 +11,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     data = [[25, 10], [40, 20], [20, 20]]
     free = 0
     for i in 0..2
-      cloud_account = Factory.build(:cloud_account, :provider =&amp;gt; provider, :username =&amp;gt; "username" + i.to_s)
-      cloud_account.stub!(:valid_credentials?).and_return(true)
-      cloud_account.save!
+      provider_account = Factory.build(:provider_account, :provider =&amp;gt; provider, :username =&amp;gt; "username" + i.to_s)
+      provider_account.stub!(:valid_credentials?).and_return(true)
+      provider_account.save!
 
       quota = Factory(:quota, :maximum_total_instances =&amp;gt; data[i][0], :total_instances =&amp;gt; data[i][1])
-      cloud_account.quota_id = quota.id
-      cloud_account.save!
+      provider_account.quota_id = quota.id
+      provider_account.save!
 
       free += (data[i][0] - data[i][1])
     end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -36,24 +36,24 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     provider.stub!(:connect).and_return(client)
     provider.save!
 
-    cloud_account = Factory.build(:cloud_account, :provider =&amp;gt; provider)
-    cloud_account.stub!(:valid_credentials?).and_return(true)
-    cloud_account.save!
+    provider_account = Factory.build(:provider_account, :provider =&amp;gt; provider)
+    provider_account.stub!(:valid_credentials?).and_return(true)
+    provider_account.save!
 
     quota = Factory(:quota,
                     :maximum_running_instances =&amp;gt; 40,
                     :maximum_total_instances =&amp;gt; 50,
                     :running_instances =&amp;gt; 20,
                     :total_instances =&amp;gt; 20)
-    cloud_account.quota_id = quota.id
+    provider_account.quota_id = quota.id
 
-    data_point = DataServiceActiveRecord.quota_usage(cloud_account, Quota::RESOURCE_RUNNING_INSTANCES)
+    data_point = DataServiceActiveRecord.quota_usage(provider_account, Quota::RESOURCE_RUNNING_INSTANCES)
     data_point.should == DataServiceActiveRecord::QuotaUsagePoint.new(20, 40)
 
-    data_point = DataServiceActiveRecord.quota_usage(cloud_account, Quota::RESOURCE_TOTAL_INSTANCES)
+    data_point = DataServiceActiveRecord.quota_usage(provider_account, Quota::RESOURCE_TOTAL_INSTANCES)
     data_point.should == DataServiceActiveRecord::QuotaUsagePoint.new(20, 50)
 
-    data_point = DataServiceActiveRecord.quota_usage(cloud_account, Quota::RESOURCE_OVERALL)
+    data_point = DataServiceActiveRecord.quota_usage(provider_account, Quota::RESOURCE_OVERALL)
     data_point.should == DataServiceActiveRecord::QuotaUsagePoint.new(20, 40)
   end
 
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -127,13 +127,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     provider.stub!(:connect).and_return(client)
     provider.save!
 
-    cloud_accounts = []
+    provider_accounts = []
     expected_averages.each do |expected_average|
-      cloud_account = Factory.build(:cloud_account, :provider =&amp;gt; provider, :username =&amp;gt; "username" + expected_average[0].to_s)
-      cloud_account.stub!(:valid_credentials?).and_return(true)
-      cloud_account.save!
+      provider_account = Factory.build(:provider_account, :provider =&amp;gt; provider, :username =&amp;gt; "username" + expected_average[0].to_s)
+      provider_account.stub!(:valid_credentials?).and_return(true)
+      provider_account.save!
 
-      instance = Factory(:instance, :cloud_account_id =&amp;gt; cloud_account.id, :pool_id =&amp;gt; pool.id)
+      instance = Factory(:instance, :provider_account_id =&amp;gt; provider_account.id, :pool_id =&amp;gt; pool.id)
       generate_tasks(start_time, interval_length, instance, expected_average)
     end
 
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -163,11 +163,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     runtimes = [runtime1, runtime2, runtime3]
 
     pool = Factory(:pool)
-    cloud_account = Factory :mock_cloud_account
+    provider_account = Factory :mock_provider_account
 
     for i in 0..2 do
        runtimes[i].each do |runtime|
-         instance = Factory(:instance, :pool =&amp;gt; pool, :cloud_account =&amp;gt; cloud_account, :state =&amp;gt; Instance::STATE_STOPPED)
+         instance = Factory(:instance, :pool =&amp;gt; pool, :provider_account =&amp;gt; provider_account, :state =&amp;gt; Instance::STATE_STOPPED)
          instance.save!
 
          instance.time_last_pending = start_times[i] + (interval_length / 2)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -177,7 +177,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
        end
     end
 
-    stats = DataServiceActiveRecord.qos_instance_runtime_stats(cloud_account, start_time, end_time, interval_length)
+    stats = DataServiceActiveRecord.qos_instance_runtime_stats(provider_account, start_time, end_time, interval_length)
     stats[0].should == DataServiceActiveRecord::QoSDataPoint.new(start_times[0], 15, 25, 5)
     stats[1].should == DataServiceActiveRecord::QoSDataPoint.new(start_times[1], 30, 50, 10)
     stats[2].should == DataServiceActiveRecord::QoSDataPoint.new(start_times[2], 300, 500, 100)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -187,11 +187,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
   it "should generate the mean max and min instance runtimes of instances for a given cloud account or pool" do
     pool = Factory(:pool)
 
-    cloud_account = Factory :mock_cloud_account
+    provider_account = Factory :mock_provider_account
 
     start_time = Time.utc(2010,"jan",1,20,15,1)
     [50, 100, 150, 200, 250].each do |runtime|
-      instance = Factory(:new_instance, :pool =&amp;gt; pool, :cloud_account =&amp;gt; cloud_account)
+      instance = Factory(:new_instance, :pool =&amp;gt; pool, :provider_account =&amp;gt; provider_account)
       instance.time_last_pending = start_time
       instance.time_last_running = start_time
       instance.acc_running_time = runtime
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -205,8 +205,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
 
   it "should calculate the average time it takes a provider to complete a task between two times" do
     pool = Factory(:pool)
-    cloud_account = Factory(:mock_cloud_account)
-    instance = Factory(:instance, :pool =&amp;gt; pool, :cloud_account =&amp;gt; cloud_account)
+    provider_account = Factory(:mock_provider_account)
+    instance = Factory(:instance, :pool =&amp;gt; pool, :provider_account =&amp;gt; provider_account)
 
     start_time = Time.utc(2010,"jan",1,20,15,1)
     task_completion_times = [10, 20, 30, 40, 50]
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -230,7 +230,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     end
 
     expected_average_time = total_time / task_completion_times.length
-    average_time = DataServiceActiveRecord.qos_task_completion_mean_max_min(cloud_account.provider, start_time, Time.now, InstanceTask::ACTION_CREATE)
+    average_time = DataServiceActiveRecord.qos_task_completion_mean_max_min(provider_account.provider, start_time, Time.now, InstanceTask::ACTION_CREATE)
 
     average_time[:average].should == expected_average_time
     average_time[:min].should == 10
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -243,8 +243,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     end_time = create_time + 1
 
     pool = Factory(:pool)
-    cloud_account = Factory :mock_cloud_account
-    instance = Factory(:instance, :pool =&amp;gt; pool, :cloud_account =&amp;gt; cloud_account)
+    provider_account = Factory :mock_provider_account
+    instance = Factory(:instance, :pool =&amp;gt; pool, :provider_account =&amp;gt; provider_account)
 
     failures = 5
     non_failures = 20
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -289,8 +289,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; describe DataServiceActiveRecord do
     number_of_instances = 20
 
     pool = Factory(:pool)
-    cloud_account = Factory :mock_cloud_account
-    instance = Factory(:instance, :pool =&amp;gt; pool, :cloud_account =&amp;gt; cloud_account)
+    provider_account = Factory :mock_provider_account
+    instance = Factory(:instance, :pool =&amp;gt; pool, :provider_account =&amp;gt; provider_account)
 
     for i in 0..2
       for j in 1..failures[i]
&lt;/pre&gt;</description>
    <dc:creator>jzigmund-H+wXaHxf7aLQT0dZR+AlfA&lt; at &gt;public.gmane.org</dc:creator>
    <dc:date>2011-01-27T15:37:53</dc:date>
  </item>
  <textinput rdf:about="http://search.gmane.org/?group=$group=gmane.comp.lib.deltacloud.devel">
    <title>Search Engine</title>
    <description>Search the mailing list at Gmane</description>
    <name>query</name>
    <link>http://search.gmane.org/?group=$group=gmane.comp.lib.deltacloud.devel</link>
  </textinput>
</rdf:RDF>

