Skip to content

Commit

Permalink
Merge branch 'master' into vim51_win8
Browse files Browse the repository at this point in the history
  • Loading branch information
minchen07 committed Feb 11, 2013
2 parents 14ef915 + 52b81f8 commit 6320cad
Show file tree
Hide file tree
Showing 561 changed files with 11,004 additions and 2,142 deletions.
31 changes: 16 additions & 15 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,21 @@ Apache CloudStack uses some ports, make sure at least those used by the manageme
server are available and not blocked by any local firewall. Following ports are
used by Apache CloudStack and its entities:

8787: Apache CloudStack (Tomcat) debug socket
9090, 8250, 8080: Apache CloudStack Management Server, User/Client API
8096: User/Client to CloudStack Management Server (unauthenticated)
7080: AWS API Server
3306: MySQL Server
3922, 8250, 80/443, 111/2049, 53: Secondary Storage VM
3922, 8250, 53: Console Proxy VM
3922, 8250, 53: Virtual Router
8080: API Server (authenticated), browser or CLI client to management server
8096: API Server (unauthenticated), browser or CLI client to management server
8787: Remote java debug debugging port, from IDE to management server
9090: Management server to management server (cluster)
7080: AWS API Server to which an AWS client can connect
80/443: HTTP client to Secondary Storage VM (template download)
111/2049: Secondary Storage to NFS server
3922: Port used to ssh/scp into system vms (SSVM, CPVM, VR)
8250: Agent (SSVM, CPVM, VR) to management server
22, 80, 443: XenServer, XAPI
22: KVM
443: vCenter
DNS: 53
NFS: 111/2049
53: DNS
111/2049: NFS
3306: MySQL Server to which the management server connects

### Configuring MySQL Server

Expand Down Expand Up @@ -93,8 +95,7 @@ For example, for master:

Clean and build:

$ mvn clean
$ mvn install
$ mvn clean install -P systemvm,developer

In case you want support for VMWare, SRX and other non-Apache (referred to as nonoss)
compliant libs, you may download the following jar artifacts from respective vendors:
Expand All @@ -112,17 +113,17 @@ Install them to ~/.m2 so maven can get them as dependencies:
$ cd deps
$ ./install-non-oss.sh

And build them with the nonoss flag:
To build with nonoss components, use the build command with the nonoss flag:

$ mvn install -Dnonoss
$ mvn clean install -P systemvm,developer -Dnonoss

Clear old database (if any) and deploy the database schema:

$ mvn -P developer -pl developer -Ddeploydb

Export the following variable if you need to run and debug the management server:

$ export MAVEN_OPTS="-Xmx1024m -Xdebug -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"
$ export MAVEN_OPTS="-Xmx1024m -XX:MaxPermSize=500m -Xdebug -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"

Start the management server:

Expand Down
7 changes: 5 additions & 2 deletions api/src/com/cloud/network/NetworkModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

import com.cloud.dc.Vlan;
import com.cloud.exception.InsufficientAddressCapacityException;
import com.cloud.exception.InvalidParameterValueException;
import com.cloud.hypervisor.Hypervisor.HypervisorType;
import com.cloud.network.Network.Capability;
import com.cloud.network.Network.Provider;
Expand Down Expand Up @@ -249,7 +250,9 @@ Map<PublicIpAddress, Set<Service>> getIpToServices(List<? extends PublicIpAddres

boolean isNetworkInlineMode(Network network);

Vlan getVlanForNetwork(long networkId);
boolean isIP6AddressAvailableInNetwork(long networkId);

boolean isIP6AddressAvailable(long networkId);
boolean isIP6AddressAvailableInVlan(long vlanId);

void checkIp6Parameters(String startIPv6, String endIPv6, String ip6Gateway, String ip6Cidr) throws InvalidParameterValueException;
}
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public class CreateVlanIpRangeCmd extends BaseCmd {
description="optional parameter. Have to be specified for Direct Untagged vlan only.")
private Long podId;

@Parameter(name=ApiConstants.START_IP, type=CommandType.STRING, required=true, description="the beginning IP address in the VLAN IP range")
@Parameter(name=ApiConstants.START_IP, type=CommandType.STRING, description="the beginning IP address in the VLAN IP range")
private String startIp;

@Parameter(name=ApiConstants.VLAN, type=CommandType.STRING, description="the ID or VID of the VLAN. If not specified," +
Expand All @@ -94,6 +94,19 @@ public class CreateVlanIpRangeCmd extends BaseCmd {
description="the physical network id")
private Long physicalNetworkId;

@Parameter(name=ApiConstants.START_IPV6, type=CommandType.STRING, description="the beginning IPv6 address in the IPv6 network range")
private String startIpv6;

@Parameter(name=ApiConstants.END_IPV6, type=CommandType.STRING, description="the ending IPv6 address in the IPv6 network range")
private String endIpv6;

@Parameter(name=ApiConstants.IP6_GATEWAY, type=CommandType.STRING, description="the gateway of the IPv6 network. Required " +
"for Shared networks and Isolated networks when it belongs to VPC")
private String ip6Gateway;

@Parameter(name=ApiConstants.IP6_CIDR, type=CommandType.STRING, description="the CIDR of IPv6 network, must be at least /64")
private String ip6Cidr;

/////////////////////////////////////////////////////
/////////////////// Accessors ///////////////////////
/////////////////////////////////////////////////////
Expand Down Expand Up @@ -141,6 +154,35 @@ public Long getZoneId() {
public Long getProjectId() {
return projectId;
}

public String getStartIpv6() {
if (startIpv6 == null) {
return null;
}
return startIpv6.toLowerCase();
}

public String getEndIpv6() {
if (endIpv6 == null) {
return null;
}
return endIpv6.toLowerCase();
}

public String getIp6Gateway() {
if (ip6Gateway == null) {
return null;
}
return ip6Gateway.toLowerCase();
}

public String getIp6Cidr() {
if (ip6Cidr == null) {
return null;
}
return ip6Cidr.toLowerCase();
}

/////////////////////////////////////////////////////
/////////////// API Implementation///////////////////
/////////////////////////////////////////////////////
Expand All @@ -153,7 +195,6 @@ public Long getPhysicalNetworkId() {
return physicalNetworkId;
}


@Override
public String getCommandName() {
return s_name;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ public void execute(){
response.setProjectInviteRequired((Boolean)capabilities.get("projectInviteRequired"));
response.setAllowUsersCreateProjects((Boolean)capabilities.get("allowusercreateprojects"));
response.setDiskOffMaxSize((Long)capabilities.get("customDiskOffMaxSize"));
response.setApiLimitInterval((Integer)capabilities.get("apiLimitInterval"));
response.setApiLimitMax((Integer)capabilities.get("apiLimitMax"));
response.setObjectName("capability");
response.setResponseName(getCommandName());
this.setResponseObject(response);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,12 @@ public class CapabilitiesResponse extends BaseResponse {
"create disk from disk offering with custom size")
private Long diskOffMaxSize;

@SerializedName("apilimitinterval") @Param(description="time interval (in seconds) to reset api count")
private Integer apiLimitInterval;

@SerializedName("apilimitmax") @Param(description="Max allowed number of api requests within the specified interval")
private Integer apiLimitMax;


public void setSecurityGroupsEnabled(boolean securityGroupsEnabled) {
this.securityGroupsEnabled = securityGroupsEnabled;
Expand Down Expand Up @@ -75,4 +81,13 @@ public void setDiskOffMaxSize(Long diskOffMaxSize) {
this.diskOffMaxSize = diskOffMaxSize;
}

public void setApiLimitInterval(Integer apiLimitInterval) {
this.apiLimitInterval = apiLimitInterval;
}

public void setApiLimitMax(Integer apiLimitMax) {
this.apiLimitMax = apiLimitMax;
}


}
Loading

0 comments on commit 6320cad

Please sign in to comment.