brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From henev...@apache.org
Subject [20/22] incubator-brooklyn git commit: better warnings and comments on use of `networkName` in JcloudsLocation
Date Wed, 24 Jun 2015 08:05:31 GMT
better warnings and comments on use of `networkName` in JcloudsLocation


Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/8e996741
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/8e996741
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/8e996741

Branch: refs/heads/master
Commit: 8e9967413913a3982a6e6d6e57735a13fdbc696d
Parents: 56285ad
Author: Alex Heneveld <alex.heneveld@cloudsoftcorp.com>
Authored: Tue Jun 23 23:12:07 2015 -0700
Committer: Alex Heneveld <alex.heneveld@cloudsoftcorp.com>
Committed: Wed Jun 24 01:04:24 2015 -0700

----------------------------------------------------------------------
 .../brooklyn/location/jclouds/JcloudsLocation.java  | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/8e996741/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
----------------------------------------------------------------------
diff --git a/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
b/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
index 969d41d..7797138 100644
--- a/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
+++ b/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
@@ -1257,14 +1257,20 @@ public class JcloudsLocation extends AbstractCloudMachineProvisioningLocation
im
                             ((AWSEC2TemplateOptions)t).subnetId((String)v);
                             
                         } else {
-                            if (t instanceof SoftLayerTemplateOptions) {
-                                LOG.warn("networkName may not be supported in SoftLayer;
use `templateOptions` with `primaryNetworkComponentNetworkVlanId` or `primaryNetworkBackendComponentNetworkVlanId`");
+                            if (t instanceof GoogleComputeEngineTemplateOptions) {
+                                // no warning needed
+                                // we think this is the only jclouds endpoint which supports
this option
+                                
+                            } else if (t instanceof SoftLayerTemplateOptions) {
+                                LOG.warn("networkName is not be supported in SoftLayer; use
`templateOptions` with `primaryNetworkComponentNetworkVlanId` or `primaryNetworkBackendComponentNetworkVlanId`");
                             } else if (!(t instanceof CloudStackTemplateOptions) &&
!(t instanceof NovaTemplateOptions)) {
-                                LOG.warn("networkName may not be supported in this cloud;
only known to work in CloudStack and OpenStack");
+                                LOG.warn("networkName is experimental in many jclouds endpoints
may not be supported in this cloud");
+                                // NB, from @andreaturli
+//                                Cloudstack uses custom securityGroupIds and networkIds
not the generic networks
+//                                Openstack Nova uses securityGroupNames which is marked
as @deprecated (suggests to use groups which is maybe even more confusing)
+//                                Azure supports the custom networkSecurityGroupName
                             }
                             
-                            // looks like this is only supported in Cloudstack and Openstack
-                            // should we log warning if using another cloud?
                             t.networks((String)v);
                         }
                     }})


Mime
View raw message