Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-21 Thread CloudBees pull request builder plugin
[jclouds-java-7-pull-requests #877](https://jclouds.ci.cloudbees.com/job/jclouds-java-7-pull-requests/877/) SUCCESS This pull request looks good --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-29012046

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-21 Thread CloudBees pull request builder plugin
[jclouds-pull-requests #414](https://jclouds.ci.cloudbees.com/job/jclouds-pull-requests/414/) UNSTABLE Looks like there's a problem with this pull request --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-29011257

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-19 Thread Andrew Phillips
jclouds » jclouds #633 UNSTABLE Looks like another timing-related [test

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-19 Thread Andrew Phillips
@@ -153,8 +155,9 @@ protected EC2ComputeService(ComputeServiceContext context, MapString, Credentia if (client.getTagApiForRegion(region).isPresent()) { MapString, String common = metadataAndTagsAsValuesOfEmptyString(template.getOptions()); - if (common.size()

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-19 Thread Andrew Phillips
@@ -362,6 +364,30 @@ public void testCreateTwoNodesWithRunScript() throws Exception { checkOsMatchesTemplate(node2); } + @Test(enabled = true, dependsOnMethods = testCreateTwoNodesWithRunScript) + public void testCreateTwoNodesWithOneSpecifiedName() throws Exception { +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-19 Thread Andrew Phillips
One question about `||` vs ``, but that should be easily answered. Otherwise, +1 - looks good to me. Thanks for the adjustments, @abayer! --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-28865289

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
@@ -153,8 +154,10 @@ protected EC2ComputeService(ComputeServiceContext context, MapString, Credentia if (client.getTagApiForRegion(region).isPresent()) { MapString, String common = metadataAndTagsAsValuesOfEmptyString(template.getOptions()); - if (common.size()

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
+ requestResponseMap.put(authorizeSecurityGroupIngressRequestGroup, authorizeSecurityGroupIngressResponse); + requestResponseMap.put(runInstancesRequest, runInstancesResponse); + requestResponseMap.put(describeInstanceRequest, describeNamedInstanceResponse); +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
@@ -100,8 +100,12 @@ public NodeMetadata apply(ServerInZone serverInZone) { builder.hostname(from.getName()); builder.location(from.getHostId() != null ? new LocationBuilder().scope(LocationScope.HOST).id(from.getHostId())

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
if (generateInstanceNames !common.containsKey(Name)) { for (Map.EntryString, ? extends NodeMetadata entry : instancesById.entrySet()) { String id = entry.getKey(); -NodeMetadata instance = entry.getValue(); - +String name; +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
} catch (IllegalArgumentException iae) { // no op } } builder.hostname(from.getName()); builder.location(findLocationForResourceInVDC.apply(from.getVDC())); -

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
@@ -180,6 +186,15 @@ protected CreateNodesWithGroupEncodedIntoNameThenAddToSet( */ protected SetString getNextNames(final String group, final Template template, int count) { SetString names = newLinkedHashSet(); + if (!template.getOptions().getNodeNames().isEmpty()) {

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
@@ -353,7 +355,7 @@ public void testCreateTwoNodesWithRunScript() throws Exception { NodeMetadata node2 = nodes.last(); // credentials aren't always the same // assertEquals(node1.getCredentials(), node2.getCredentials()); - + Fixed. --- Reply to this email

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
@@ -362,6 +364,30 @@ public void testCreateTwoNodesWithRunScript() throws Exception { checkOsMatchesTemplate(node2); } + @Test(enabled = true, dependsOnMethods = testCreateTwoNodesWithRunScript) + public void testCreateTwoNodesWithOneSpecifiedName() throws Exception { +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread Andrew Bayer
} + if (groupName.equals()) { + groupName = nodeNamingConvention.groupInUniqueNameOrNull(from.getHostname()); + } + builder.group(groupName); Done above. --- Reply to this email directly or view it on GitHub:

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-18 Thread CloudBees pull request builder plugin
[jclouds-pull-requests #410](https://jclouds.ci.cloudbees.com/job/jclouds-pull-requests/410/) SUCCESS This pull request looks good --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-28718362

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-16 Thread Andrew Phillips
@@ -153,8 +154,10 @@ protected EC2ComputeService(ComputeServiceContext context, MapString, Credentia if (client.getTagApiForRegion(region).isPresent()) { MapString, String common = metadataAndTagsAsValuesOfEmptyString(template.getOptions()); - if (common.size()

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-16 Thread Andrew Phillips
+ requestResponseMap.put(authorizeSecurityGroupIngressRequestGroup, authorizeSecurityGroupIngressResponse); + requestResponseMap.put(runInstancesRequest, runInstancesResponse); + requestResponseMap.put(describeInstanceRequest, describeNamedInstanceResponse); +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-16 Thread Andrew Phillips
@@ -100,8 +100,12 @@ public NodeMetadata apply(ServerInZone serverInZone) { builder.hostname(from.getName()); builder.location(from.getHostId() != null ? new LocationBuilder().scope(LocationScope.HOST).id(from.getHostId())

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-16 Thread Andrew Phillips
@@ -362,6 +364,30 @@ public void testCreateTwoNodesWithRunScript() throws Exception { checkOsMatchesTemplate(node2); } + @Test(enabled = true, dependsOnMethods = testCreateTwoNodesWithRunScript) + public void testCreateTwoNodesWithOneSpecifiedName() throws Exception { +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-16 Thread Andrew Phillips
} + if (groupName.equals()) { + groupName = nodeNamingConvention.groupInUniqueNameOrNull(from.getHostname()); + } + builder.group(groupName); See comment about perhaps initializing with `null` rather than the empty string above? --- Reply to this email

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-15 Thread Ignasi Barrera
I've had a look and looks good to me. I'd be extremely happy to have this merged once tests pass! (I can only vote once in jira, though :D) --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-28552805

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-15 Thread Andrew Bayer
@@ -353,7 +355,7 @@ public void testCreateTwoNodesWithRunScript() throws Exception { NodeMetadata node2 = nodes.last(); // credentials aren't always the same // assertEquals(node1.getCredentials(), node2.getCredentials()); - + System.err.println(node 1 baby +

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-15 Thread BuildHive
[jclouds » jclouds #626](https://buildhive.cloudbees.com/job/jclouds/job/jclouds/626/) SUCCESS This pull request looks good [(what's this?)](https://www.cloudbees.com/what-is-buildhive) --- Reply to this email directly or view it on GitHub:

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-15 Thread Andrew Bayer
Yup, looks like I need to add logic to every API/provider to save the group in instance metadata or somewhere similar, which is gonna necessitate a fair amount of work. I think I can probably get it done this weekend, though. --- Reply to this email directly or view it on GitHub:

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-15 Thread Andrew Bayer
Ok, actually, turned out to be less than an hour of work. woo? Softlayer still only supports old groups, but every other provider in core should be good. I've done live tests against EC2, HP Cloud, and (with a yet-to-be-pushed branch) GCE. --- Reply to this email directly or view it on GitHub:

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-15 Thread CloudBees pull request builder plugin
[jclouds-pull-requests #408](https://jclouds.ci.cloudbees.com/job/jclouds-pull-requests/408/) SUCCESS This pull request looks good --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-28610325

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-14 Thread CloudBees pull request builder plugin
[jclouds-pull-requests #401](https://jclouds.ci.cloudbees.com/job/jclouds-pull-requests/401/) UNSTABLE Looks like there's a problem with this pull request --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-28543862

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-14 Thread CloudBees pull request builder plugin
[jclouds-java-7-pull-requests #864](https://jclouds.ci.cloudbees.com/job/jclouds-java-7-pull-requests/864/) UNSTABLE Looks like there's a problem with this pull request --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/206#issuecomment-28543887

Re: [jclouds] JCLOUDS-381. Allow explicit naming of nodes via TemplateOptions. (#206)

2013-11-14 Thread BuildHive
[jclouds » jclouds #622](https://buildhive.cloudbees.com/job/jclouds/job/jclouds/622/) UNSTABLE Looks like there's a problem with this pull request [(what's this?)](https://www.cloudbees.com/what-is-buildhive) --- Reply to this email directly or view it on GitHub: