cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alena1...@apache.org
Subject [45/50] [abbrv] git commit: updated refs/heads/internallb to ca2fc30
Date Wed, 24 Apr 2013 16:24:09 GMT
CLOUDSTACK-2120: mixed zone management - extend listNetworks API to return zone type.


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/16ba999b
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/16ba999b
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/16ba999b

Branch: refs/heads/internallb
Commit: 16ba999bf1102938779f0b773984695b75ccd77e
Parents: 35e2072
Author: Jessica Wang <jessicawang@apache.org>
Authored: Tue Apr 23 12:25:34 2013 -0700
Committer: Jessica Wang <jessicawang@apache.org>
Committed: Tue Apr 23 13:01:55 2013 -0700

----------------------------------------------------------------------
 .../cloudstack/api/response/NetworkResponse.java   |    7 +++++++
 server/src/com/cloud/api/ApiResponseHelper.java    |    1 +
 2 files changed, 8 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/16ba999b/api/src/org/apache/cloudstack/api/response/NetworkResponse.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/response/NetworkResponse.java b/api/src/org/apache/cloudstack/api/response/NetworkResponse.java
index cd32ded..3f366e2 100644
--- a/api/src/org/apache/cloudstack/api/response/NetworkResponse.java
+++ b/api/src/org/apache/cloudstack/api/response/NetworkResponse.java
@@ -66,6 +66,9 @@ public class NetworkResponse extends BaseResponse implements ControlledEntityRes
 
     @SerializedName(ApiConstants.ZONE_NAME) @Param(description="the name of the zone the
network belongs to")
     private String zoneName;
+    
+    @SerializedName(ApiConstants.ZONE_TYPE) @Param(description="the networktype of the zone
the network belongs to")
+    private String zoneType;
 
     @SerializedName("networkofferingid") @Param(description="network offering id the network
is created from")
     private String networkOfferingId;
@@ -291,6 +294,10 @@ public class NetworkResponse extends BaseResponse implements ControlledEntityRes
         this.zoneName = zoneName;
     }
 
+    public void setZoneType(String zoneType) {
+        this.zoneType = zoneType;
+    }
+    
     public void setCidr(String cidr) {
         this.cidr = cidr;
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/16ba999b/server/src/com/cloud/api/ApiResponseHelper.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/ApiResponseHelper.java b/server/src/com/cloud/api/ApiResponseHelper.java
index a7d6165..84dc46e 100755
--- a/server/src/com/cloud/api/ApiResponseHelper.java
+++ b/server/src/com/cloud/api/ApiResponseHelper.java
@@ -2354,6 +2354,7 @@ public class ApiResponseHelper implements ResponseGenerator {
         if (zone != null) {
             response.setZoneId(zone.getUuid());
             response.setZoneName(zone.getName());
+            response.setZoneType(zone.getNetworkType().toString());
         }
         if (network.getPhysicalNetworkId() != null) {
             PhysicalNetworkVO pnet = ApiDBUtils.findPhysicalNetworkById(network.getPhysicalNetworkId());


Mime
View raw message