diff --git a/api/src/com/cloud/api/commands/DeleteVpnConnectionCmd.java b/api/src/com/cloud/api/commands/DeleteVpnConnectionCmd.java index 53cc112620e..8b13f4738d9 100644 --- a/api/src/com/cloud/api/commands/DeleteVpnConnectionCmd.java +++ b/api/src/com/cloud/api/commands/DeleteVpnConnectionCmd.java @@ -16,20 +16,19 @@ import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; import com.cloud.api.BaseAsyncCmd; -import com.cloud.api.BaseAsyncCreateCmd; import com.cloud.api.BaseCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; import com.cloud.api.ServerApiException; -import com.cloud.api.response.Site2SiteVpnConnectionResponse; +import com.cloud.api.response.SuccessResponse; import com.cloud.event.EventTypes; import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.Site2SiteVpnConnection; import com.cloud.user.Account; import com.cloud.user.UserContext; -@Implementation(description="Delete site to site vpn connection", responseObject=Site2SiteVpnConnectionResponse.class) +@Implementation(description="Delete site to site vpn connection", responseObject=SuccessResponse.class) public class DeleteVpnConnectionCmd extends BaseAsyncCmd { public static final Logger s_logger = Logger.getLogger(DeleteVpnConnectionCmd.class.getName()); @@ -103,8 +102,7 @@ public class DeleteVpnConnectionCmd extends BaseAsyncCmd { try { Site2SiteVpnConnection result = _s2sVpnService.deleteVpnConnection(this); if (result != null) { - Site2SiteVpnConnectionResponse response = _responseGenerator.createSite2SiteVpnConnectionResponse(result); - response.setResponseName(getCommandName()); + SuccessResponse response = new SuccessResponse(getCommandName()); this.setResponseObject(response); } else { throw new ServerApiException(BaseCmd.INTERNAL_ERROR, "Failed to delete site to site VPN connection"); diff --git a/api/src/com/cloud/api/commands/DeleteVpnCustomerGatewayCmd.java b/api/src/com/cloud/api/commands/DeleteVpnCustomerGatewayCmd.java index 17528a95af8..a244be0b47c 100644 --- a/api/src/com/cloud/api/commands/DeleteVpnCustomerGatewayCmd.java +++ b/api/src/com/cloud/api/commands/DeleteVpnCustomerGatewayCmd.java @@ -16,19 +16,18 @@ import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; import com.cloud.api.BaseAsyncCmd; -import com.cloud.api.BaseAsyncCreateCmd; import com.cloud.api.BaseCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; import com.cloud.api.ServerApiException; -import com.cloud.api.response.Site2SiteCustomerGatewayResponse; +import com.cloud.api.response.SuccessResponse; import com.cloud.event.EventTypes; import com.cloud.network.Site2SiteCustomerGateway; import com.cloud.user.Account; import com.cloud.user.UserContext; -@Implementation(description="Delete site to site vpn customer gateway", responseObject=Site2SiteCustomerGatewayResponse.class) +@Implementation(description="Delete site to site vpn customer gateway", responseObject=SuccessResponse.class) public class DeleteVpnCustomerGatewayCmd extends BaseAsyncCmd { public static final Logger s_logger = Logger.getLogger(DeleteVpnCustomerGatewayCmd.class.getName()); @@ -101,8 +100,7 @@ public class DeleteVpnCustomerGatewayCmd extends BaseAsyncCmd { public void execute(){ Site2SiteCustomerGateway result = _s2sVpnService.deleteCustomerGateway(this); if (result != null) { - Site2SiteCustomerGatewayResponse response = _responseGenerator.createSite2SiteCustomerGatewayResponse(result); - response.setResponseName(getCommandName()); + SuccessResponse response = new SuccessResponse(getCommandName()); this.setResponseObject(response); } else { throw new ServerApiException(BaseCmd.INTERNAL_ERROR, "Failed to delete customer VPN gateway"); diff --git a/api/src/com/cloud/api/commands/DeleteVpnGatewayCmd.java b/api/src/com/cloud/api/commands/DeleteVpnGatewayCmd.java index b8569691864..2c9c209168d 100644 --- a/api/src/com/cloud/api/commands/DeleteVpnGatewayCmd.java +++ b/api/src/com/cloud/api/commands/DeleteVpnGatewayCmd.java @@ -23,12 +23,13 @@ import com.cloud.api.Implementation; import com.cloud.api.Parameter; import com.cloud.api.ServerApiException; import com.cloud.api.response.Site2SiteVpnGatewayResponse; +import com.cloud.api.response.SuccessResponse; import com.cloud.event.EventTypes; import com.cloud.network.Site2SiteVpnGateway; import com.cloud.user.Account; import com.cloud.user.UserContext; -@Implementation(description="Delete site to site vpn gateway", responseObject=Site2SiteVpnGatewayResponse.class) +@Implementation(description="Delete site to site vpn gateway", responseObject=SuccessResponse.class) public class DeleteVpnGatewayCmd extends BaseAsyncCmd { public static final Logger s_logger = Logger.getLogger(DeleteVpnGatewayCmd.class.getName()); @@ -101,8 +102,7 @@ public class DeleteVpnGatewayCmd extends BaseAsyncCmd { public void execute(){ Site2SiteVpnGateway result = _s2sVpnService.deleteVpnGateway(this); if (result != null) { - Site2SiteVpnGatewayResponse response = _responseGenerator.createSite2SiteVpnGatewayResponse(result); - response.setResponseName(getCommandName()); + SuccessResponse response = new SuccessResponse(getCommandName()); this.setResponseObject(response); } else { throw new ServerApiException(BaseCmd.INTERNAL_ERROR, "Failed to delete customer VPN gateway");