You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@whirr.apache.org by "Tom White (JIRA)" <ji...@apache.org> on 2010/08/18 23:16:16 UTC
[jira] Created: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Use Commons Configuration to manage cluster specs
-------------------------------------------------
Key: WHIRR-75
URL: https://issues.apache.org/jira/browse/WHIRR-75
Project: Whirr
Issue Type: Improvement
Components: core
Reporter: Tom White
Assignee: Tom White
Fix For: 0.1.0
Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Adrian Cole (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12900575#action_12900575 ]
Adrian Cole commented on WHIRR-75:
----------------------------------
patch applies clean and unit tests pass.
The design looks cleaner than before and it looks positive.
I'd like to see an example of creating the configuration without using properties files.
for some reason, only hadoop seems to pass integration tests now. perhaps it is transient...
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Adrian Cole (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12900850#action_12900850 ]
Adrian Cole commented on WHIRR-75:
----------------------------------
latest patch tests out fine on cassandra, hadoop, and zookeeper
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tom White updated WHIRR-75:
---------------------------
Attachment: WHIRR-75.patch
New patch which makes ClusterSpec a POJO, and has a static fromConfiguration() factory method. Does this look OK?
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tom White updated WHIRR-75:
---------------------------
Attachment: WHIRR-75.patch
There was a bug in the previous patch that meant client CIDRs were being ignored. ZK and Cassandra tests work for me now with this patch.
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12900756#action_12900756 ]
Tom White commented on WHIRR-75:
--------------------------------
Thanks for taking a look, Adrian.
> I'd like to see an example of creating the configuration without using properties files.
See DestroyClusterCommandTest which constructs a PropertiesConfiguration in code, without loading it from a properties file. Is this what you mean?
> for some reason, only hadoop seems to pass integration tests now. perhaps it is transient...
Could it be that your originating IP changes between calls? To work around this you could create a properties file called _.whirr-test.properties_ in your home directory containing
{noformat}
whirr.client-cidrs=0.0.0.0/0
{noformat}
(or a more restrictive CIDR). Then run tests using
{noformat}
mvn verify -DargLine="-Dwhirr.test.identity=$AWS_ACCESS_KEY_ID -Dwhirr.test.credential=$AWS_SECRET_ACCESS_KEY -Dconfig=.whirr-test.properties"
{noformat}
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Adrian Cole (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12900858#action_12900858 ]
Adrian Cole commented on WHIRR-75:
----------------------------------
thanks for the notes on usage. I would prefer our objects to not require commons configuration. For example, It would be a bit cleaner to have ClusterSpec as a pojo and a utility that allows you to create it from a commons configuration object.
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tom White updated WHIRR-75:
---------------------------
Attachment: WHIRR-75.patch
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Adrian Cole (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12900879#action_12900879 ]
Adrian Cole commented on WHIRR-75:
----------------------------------
I'd kindof prefer clusterspec to be immutable (ex. all final fields or no setters), but I feel its nit-picky
I'm happy with how this is
+1
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tom White resolved WHIRR-75.
----------------------------
Resolution: Fixed
I've just committed this.
Happy to make further changes to ClusterSpec - perhaps we can discuss in another issue?
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tom White updated WHIRR-75:
---------------------------
Attachment: WHIRR-75.patch
Adrian noticed that there was a missing trim() on the FirewallSettings.getOriginatingIp() method. New patch to remedy.
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch, WHIRR-75.patch, WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WHIRR-75) Use Commons Configuration to manage
cluster specs
Posted by "Tom White (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WHIRR-75?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tom White updated WHIRR-75:
---------------------------
Attachment: WHIRR-75.patch
This is quite a big change, but should make Whirr easier to use and more flexible. Summary of changes:
* Commons Configuration is now used for managing configuration. This is shared between tests and the CLI, which means there are fewer places to change when adding new configuration options.
* ClusterSpec is now immutable and backed by a configuration object.
* The CLI is simplified. Service and cluster names are set using options, and it's possible to bundle up all the options into a properties file, like so: whirr launch-cluster --config mycluster.properties. (This makes it easy to define clusters with different properties - e.g. a 3-node ZK cluster vs a 5-node cross-DC cluster.) You can still specify options on the command line, and these take precedence over those in the config.
* Tests have a properties file to drive them. This makes it easy to run the tests with overridden settings (using -Dconfig=mycluster.properties, I use this to set whirr.client-cidrs, for example), and reduces the amount of code duplication for creating a ClusterSpec object.
All tests pass.
> Use Commons Configuration to manage cluster specs
> -------------------------------------------------
>
> Key: WHIRR-75
> URL: https://issues.apache.org/jira/browse/WHIRR-75
> Project: Whirr
> Issue Type: Improvement
> Components: core
> Reporter: Tom White
> Assignee: Tom White
> Fix For: 0.1.0
>
> Attachments: WHIRR-75.patch
>
>
> Apache Commons Configuration (http://commons.apache.org/configuration/index.html) would be useful to share configuration information between the CLI and the tests.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.