Return-Path: X-Original-To: apmail-cloudstack-dev-archive@www.apache.org Delivered-To: apmail-cloudstack-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C891810692 for ; Thu, 4 Jul 2013 15:20:47 +0000 (UTC) Received: (qmail 24278 invoked by uid 500); 4 Jul 2013 15:20:47 -0000 Delivered-To: apmail-cloudstack-dev-archive@cloudstack.apache.org Received: (qmail 24246 invoked by uid 500); 4 Jul 2013 15:20:46 -0000 Mailing-List: contact dev-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list dev@cloudstack.apache.org Received: (qmail 24238 invoked by uid 99); 4 Jul 2013 15:20:46 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Jul 2013 15:20:46 +0000 X-ASF-Spam-Status: No, hits=0.0 required=5.0 tests= X-Spam-Check-By: apache.org Received-SPF: error (nike.apache.org: local policy) Received: from [162.210.70.53] (HELO us2.outbound.mailhostbox.com) (162.210.70.53) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Jul 2013 15:20:40 +0000 Received: from localhost (unknown [49.205.181.238]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: tsp@v0g0n.org) by us2.outbound.mailhostbox.com (Postfix) with ESMTPSA id 47BF28F0494 for ; Thu, 4 Jul 2013 15:19:56 +0000 (GMT) Date: Thu, 4 Jul 2013 20:49:52 +0530 From: Prasanna Santhanam To: dev@cloudstack.apache.org Subject: Re: Using the ACS simulator for jclouds "live" tests - some questions. =) Message-ID: <20130704151952.GB3799@cloud-2.local> Mail-Followup-To: dev@cloudstack.apache.org References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-CTCH-RefID: str=0001.0A02020A.51D5929E.00D3,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CTCH-SenderID: tsp@apache.org X-CTCH-SenderID-TotalMessages: 1 X-CTCH-SenderID-TotalSpam: 0 X-CTCH-SenderID-TotalSuspected: 0 X-CTCH-SenderID-TotalBulk: 0 X-CTCH-SenderID-TotalConfirmed: 0 X-CTCH-SenderID-TotalRecipients: 0 X-CTCH-SenderID-TotalVirus: 0 X-CTCH-SenderID-BlueWhiteFlag: 0 X-Scanned-By: MIMEDefang 2.72 on 172.16.214.8 X-Virus-Checked: Checked by ClamAV on apache.org Andrew - Firstly, apologize for the delayed response. You caught me at a bad time when I was attempting to fix the simulator which was broken when you sent this email. It took longer than expected to fix and get it back in shape. My comments are inline. On Mon, Jun 24, 2013 at 11:08:20AM -0700, Andrew Bayer wrote: > Hey all - > > So, at David Nalley's suggestion, I'm trying to run jclouds' live tests for > ACS against a simulator instance, so that I can actually run the full > battery of API tests (including global admin, advanced and basic > networking, etc) without having to set up a ton of CloudStack instances. In > a perfect world, it'd be great if there was a standalone war that used h2 > for the DB and had different flags to pass to it for different starting > settings, but I'd be immensely happy to be able to get the following in > place on startup (or an easy script to run to do this on top of the base > setup): > Indeed, this is something David discussed with me and it's a great way to run the live tests of jclouds. Right now the simulator jar is packaged as a plugin. But there's a few spring related connections to be made to get it to work with CloudStack installs. I'll figure out how we can package (may be a simulator cloudstack rpm) so you can have this running. The simulator itself only provides the ability to mock hypervisor commands but the setup of the network model, zone type etc needs to be done from the outside. This can be done with the help of marvin's json configuration commands. It's just an API driver that can set things up for you. There are samples in our code base under setup/dev/advanced.cfg and setup/dev/basic.cfg. The tutorial on marvin also has this information on how to generate your own style of deployment. [1] [1] https://cwiki.apache.org/confluence/x/QQzMAQ > - A hardcoded API/secret key for admin, so that I don't have to go click > through to create/get it, and can instead just use the same thing every > time. The regular setup of the simulator can be followed by a couple of cloudmonkey (ACS CLI) commands to achieve this. > > - At least one available simulator template (best-case would be Ubuntu > 10.04 or 12.04) that can be "booted up" out of the box - for whatever > reason (I honestly can't tell, from the brief dive I did through the code), > all the builtin templates come up with isready=false in the listTemplates > output, which makes jclouds think there are no templates, etc, etc... I > thought this is because they're all in Allocated state, not Ready, but even > changing them to Ready in the DB didn't do the trick. The guest OS is something that doesn't matter to the simulator. Whatever you ask for will be deployed. One limitation of the simulator is that it keeps CloudStack 'happy' by telling it it's got whatever is requested. So any negative scenarios will be harder to test without a change in the simulator. The templates issue still exists but with cloudmonkey you can register your template and it will come to ready state: cloudmonkey>> register template format=RAW hypervisor=Simulator isfeatured=true ispublic=true name=tiny displaytext=tiny url=http://test.url.com/test.raw ostypeid=bb62589e-e3cd-11e2-ad39-ea6434daa8ba zoneid=55318568-8d4b-412c-8c10-82f47651eb51 > > - A fake host for starting fake instances on - this may already be there, > but I never got far enough to be sure. Which tutorial are you following to get through this? Here's the right link: https://cwiki.apache.org/confluence/display/CLOUDSTACK/Marvin+-+Testing+with+Python#Marvin-TestingwithPython- > > The above would at least get me able to run the most recent set of live > tests I've been working on (testing the new CloudStack implementation of > jclouds' cross-compute abstraction for image creation/destruction), but in > the longer term, I'd absolutely love to be able to run our whole suite > against the simulator - obviously, it'd just be an approximation of the > real thing, and I'd still try to find real existing ACS setups to finagle > access to in order to run the tests against real, live setups, but anything > I can automate is a huge win for jclouds, and I imagine it'd be very useful > for libcloud, deltacloud, fog, etc as well! > thanks - indeed it will be. I hope to hear more from your tests. -- Prasanna., ------------------------ Powered by BigRock.com