mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-03 04:12:31 +01:00
bug 9154: Add isRedundantRouter to DomainRouterResponse
This commit is contained in:
parent
1616084f47
commit
9466106c40
@ -119,6 +119,9 @@ public class DomainRouterResponse extends BaseResponse {
|
|||||||
@SerializedName("serviceofferingname") @Param(description="the name of the service offering of the virtual machine")
|
@SerializedName("serviceofferingname") @Param(description="the name of the service offering of the virtual machine")
|
||||||
private String serviceOfferingName;
|
private String serviceOfferingName;
|
||||||
|
|
||||||
|
@SerializedName("isredundantrouter") @Param(description="if this router is an redundant virtual router")
|
||||||
|
private boolean isRedundantRouter;
|
||||||
|
|
||||||
@SerializedName("redundantstate") @Param(description="the state of redundant virtual router")
|
@SerializedName("redundantstate") @Param(description="the state of redundant virtual router")
|
||||||
private String redundantState;
|
private String redundantState;
|
||||||
|
|
||||||
@ -382,4 +385,12 @@ public class DomainRouterResponse extends BaseResponse {
|
|||||||
public void setRedundantState(String redundantState) {
|
public void setRedundantState(String redundantState) {
|
||||||
this.redundantState = redundantState;
|
this.redundantState = redundantState;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean getIsRedundantRouter() {
|
||||||
|
return isRedundantRouter;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setIsRedundantRouter(boolean isRedundantRouter) {
|
||||||
|
this.isRedundantRouter = isRedundantRouter;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -29,6 +29,7 @@ public interface VirtualRouter extends VirtualMachine {
|
|||||||
DHCP_USERDATA
|
DHCP_USERDATA
|
||||||
}
|
}
|
||||||
Role getRole();
|
Role getRole();
|
||||||
|
boolean getIsRedundantRouter();
|
||||||
public enum RedundantState {
|
public enum RedundantState {
|
||||||
UNKNOWN,
|
UNKNOWN,
|
||||||
MASTER,
|
MASTER,
|
||||||
|
|||||||
@ -139,6 +139,7 @@ public class DomainRouterVO extends VMInstanceVO implements VirtualRouter {
|
|||||||
this.role = role;
|
this.role = role;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
public boolean getIsRedundantRouter() {
|
public boolean getIsRedundantRouter() {
|
||||||
return this.isRedundantRouter;
|
return this.isRedundantRouter;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1257,6 +1257,7 @@ public class ApiResponseHelper implements ResponseGenerator {
|
|||||||
routerResponse.setTemplateId(router.getTemplateId());
|
routerResponse.setTemplateId(router.getTemplateId());
|
||||||
routerResponse.setCreated(router.getCreated());
|
routerResponse.setCreated(router.getCreated());
|
||||||
routerResponse.setState(router.getState());
|
routerResponse.setState(router.getState());
|
||||||
|
routerResponse.setIsRedundantRouter(router.getIsRedundantRouter());
|
||||||
routerResponse.setRedundantState(router.getRedundantState().toString());
|
routerResponse.setRedundantState(router.getRedundantState().toString());
|
||||||
|
|
||||||
if (router.getHostId() != null) {
|
if (router.getHostId() != null) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user