This Confluence has been LDAP enabled, if you are an ASF Committer, please use your LDAP Credentials to login. Any problems file an INFRA jira ticket please.

Child pages
  • How To Contribute
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

This page describes the mechanics of how to contribute software to Apache Whirr.

Getting the source code

First of all, you need the Whirr source code. Checkout subversion "trunk" using:

svn checkout whirr-trunk

Setting up Eclipse

Generate the Eclipse project and classpath files:

mvn eclipse:eclipse -DdownloadSources=true -DdownloadJavadocs

Set the M2_REPO classpath variable
1. File, Preferences, Java, Build Path, Classpath Variables
2. New

  • Name: M2_REPO
  • Path: /path/to/.m2/repository

Import all projects
1. File, import, General, Existing projects into workspace
2. Choose the whirr-trunk directory
3. Choose all modules

It's also covenient to add the top-level project too.

Building Whirr

Build and install the JARs from the top-level with

mvn install

To check the code adheres to the style guidelines, which are Sun's conventions except 2 spaces for tabs,, you can use

mvn checkstyle:checkstyle

Running Tests

You can run the unit tests, which run locally without using any cloud providers, by typing:

mvn test

To run integration tests you need to have an account with a cloud provider, and you need to set the necessary credentials. In theory, Whirr runs against any provider supported by jclouds, but this hasn't been tested yet.

To run the tests for a given service, change into the services/<service> directory and type the following. Alternatively, run this from the top level to run the tests for all services.

mvn verify -DargLine='-Dwhirr.test.provider=<cloud-provider> -Dwhirr.test.user=<cloud-provider-user> -Dwhirr.test.key=<cloud-provider-secret-key>'

For Amazon EC2, whirr.test.provider should be set to ec2 (the default). The user is the access key ID, and the key is the secret access key.

The tests also rely on having an SSH keypair. By default they use .ssh/id_rsa and .ssh/ in the user's home directory, but you can override this by setting whirr.test.ssh.keyfile to the private key's filename.

  • No labels