Skip to content

Commit 18aeef3

Browse files
committed
Merge branch 'master' (up to commit
c30d9be) into object_store.
2 parents ec55c2e + c30d9be commit 18aeef3

424 files changed

Lines changed: 23782 additions & 5630 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,3 +81,4 @@ debian/*.debhelper
8181
replace.properties.tmp
8282
build-indep-stamp
8383
configure-stamp
84+
*_flymake.js

INSTALL.md

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
This document describes how to develop, build, package and install Apache CloudStack
2-
(Incubating). For more information please refer to the project's website:
1+
This document describes how to develop, build, package and install Apache
2+
CloudStack. For more information please refer to:
33

44
http://cloudstack.apache.org
55

@@ -10,7 +10,7 @@ Refer to the [wiki](http://cwiki.apache.org/confluence/display/CLOUDSTACK/Index)
1010
for the latest information, especially:
1111

1212
- [Setting up development environment](https://cwiki.apache.org/confluence/display/CLOUDSTACK/Setting+up+CloudStack+Development+Environment) for Apache CloudStack.
13-
- [Building](https://cwiki.apache.org/confluence/display/CLOUDSTACK/Building) Apache CloudStack.
13+
- [Building](https://cwiki.apache.org/confluence/display/CLOUDSTACK/How+to+build+on+master+branch) Apache CloudStack.
1414

1515
## Setting up Development Environment
1616

@@ -21,12 +21,12 @@ Install tools and dependencies used for development:
2121
$ yum install git ant ant-devel java-1.6.0-openjdk java-1.6.0-openjdk-devel
2222
mysql mysql-server tomcat6 mkisofs gcc python MySQL-python openssh-clients wget
2323

24-
Set up Maven (3.0.4):
24+
Set up Maven (3.0.5):
2525

26-
$ wget http://www.us.apache.org/dist/maven/maven-3/3.0.4/binaries/apache-maven-3.0.4-bin.tar.gz
26+
$ wget http://www.us.apache.org/dist/maven/maven-3/3.0.5/binaries/apache-maven-3.0.5-bin.tar.gz
2727
$ cd /usr/local/ # or any path
28-
$ tar -zxvf apache-maven-3.0.4-bin.tar.gz
29-
$ echo export M2_HOME=/usr/local/apache-maven-3.0.4 >> ~/.bashrc # or .zshrc or .profile
28+
$ tar -zxvf apache-maven-3.0.5-bin.tar.gz
29+
$ echo export M2_HOME=/usr/local/apache-maven-3.0.5 >> ~/.bashrc # or .zshrc or .profile
3030
$ echo export PATH=${M2_HOME}/bin:${PATH} >> ~/.bashrc # or .zshrc or .profile
3131

3232
Note: Tomcat 6.0.35 has some known issue with Apache CloudStack, please use Tomcat
@@ -77,10 +77,10 @@ Start the MySQL service:
7777

7878
You may get the source code from the repository hosted on Apache:
7979

80-
$ git clone https://git-wip-us.apache.org/repos/asf/cloudstack.git
80+
$ git clone git://git.apache.org/cloudstack.git
8181

8282
Or, you may fork a repository from the official Apache CloudStack mirror by
83-
Apache on [Github](https://github.com/apache/incubator-cloudstack)
83+
Apache on [Github](https://github.com/apache/cloudstack)
8484

8585
To keep yourself updated on a branch, do:
8686

@@ -92,7 +92,6 @@ For example, for master:
9292

9393
## Building
9494

95-
9695
Clean and build:
9796

9897
$ mvn clean install -P systemvm,developer

agent-simulator/tomcatconf/components-simulator.xml.in

Lines changed: 0 additions & 54 deletions
This file was deleted.

agent/bindir/cloud-setup-agent.in

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,11 @@ if __name__ == '__main__':
9595
parser.add_option("--prvNic", dest="prvNic", help="Private traffic interface")
9696
parser.add_option("--guestNic", dest="guestNic", help="Guest traffic interface")
9797

98+
old_config = configFileOps("@AGENTSYSCONFDIR@/agent.properties")
99+
bridgeType = old_config.getEntry("network.bridge.type").lower()
100+
if bridgeType:
101+
glbEnv.bridgeType = bridgeType
102+
98103
(options, args) = parser.parse_args()
99104
if options.auto is None:
100105
userInputs = getUserInputs()
@@ -104,7 +109,7 @@ if __name__ == '__main__':
104109
glbEnv.pod = userInputs[3]
105110
glbEnv.cluster = userInputs[4]
106111
#generate UUID
107-
glbEnv.uuid = configFileOps("@AGENTSYSCONFDIR@/agent.properties").getEntry("guid")
112+
glbEnv.uuid = old_config.getEntry("guid")
108113
if glbEnv.uuid == "":
109114
glbEnv.uuid = bash("uuidgen").getStdout()
110115
else:

agent/conf/agent.properties

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,11 @@ domr.scripts.dir=scripts/network/domr/kvm
8484
# set the hypervisor type, values are: kvm, lxc
8585
# hypervisor.type=kvm
8686

87+
# set the hypervisor URI. Usually there is no need for changing this
88+
# For KVM: qemu:///system
89+
# For LXC: lxc:///
90+
# hypervisor.uri=qemu:///system
91+
8792
# settings to enable direct networking in libvirt, should not be used
8893
# on hosts that run system vms, values for mode are: private, bridge, vepa
8994
# libvirt.vif.driver=com.cloud.hypervisor.kvm.resource.DirectVifDriver

api/src/com/cloud/agent/api/to/DnsmasqTO.java

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,14 @@ public class DnsmasqTO {
2020
String routerIp;
2121
String gateway;
2222
String netmask;
23+
String startIpOfSubnet;
2324

24-
public DnsmasqTO(String routerIp, String gateway, String netmask) {
25+
public DnsmasqTO(String routerIp, String gateway, String netmask, String StartIpOfSubnet) {
2526
this.routerIp = routerIp;
27+
this.startIpOfSubnet = StartIpOfSubnet;
2628
this.gateway = gateway;
2729
this.netmask =netmask;
30+
2831
}
2932

3033
public void setRouterIp(String routerIp){
@@ -39,6 +42,10 @@ public void setNetmask(String netmask) {
3942
this.netmask = netmask ;
4043
}
4144

45+
public void setStartIpOfSubnet( String ipOfSubNet) {
46+
startIpOfSubnet = ipOfSubNet;
47+
}
48+
4249
public String getRouterIp() {
4350
return routerIp;
4451
}
@@ -50,4 +57,8 @@ public String getGateway() {
5057
public String getNetmask() {
5158
return netmask;
5259
}
60+
public String getStartIpOfSubnet() {
61+
return startIpOfSubnet;
62+
}
63+
5364
}

api/src/com/cloud/agent/api/to/VirtualMachineTO.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public class VirtualMachineTO {
5252
boolean rebootOnCrash;
5353
boolean enableHA;
5454
boolean limitCpuUse;
55+
boolean enableDynamicallyScaleVm;
5556
String vncPassword;
5657
String vncAddr;
5758
Map<String, String> params;
@@ -102,6 +103,14 @@ public void setId(long id) {
102103
this.id = id;
103104
}
104105

106+
public boolean isEnableDynamicallyScaleVm() {
107+
return enableDynamicallyScaleVm;
108+
}
109+
110+
public void setEnableDynamicallyScaleVm(boolean enableDynamicallyScaleVm) {
111+
this.enableDynamicallyScaleVm = enableDynamicallyScaleVm;
112+
}
113+
105114
public String getName() {
106115
return name;
107116
}
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
// Licensed to the Apache Software Foundation (ASF) under one
2+
// or more contributor license agreements. See the NOTICE file
3+
// distributed with this work for additional information
4+
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
6+
// "License"); you may not use this file except in compliance
7+
// with the License. You may obtain a copy of the License at
8+
//
9+
// http://www.apache.org/licenses/LICENSE-2.0
10+
//
11+
// Unless required by applicable law or agreed to in writing,
12+
// software distributed under the License is distributed on an
13+
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
// KIND, either express or implied. See the License for the
15+
// specific language governing permissions and limitations
16+
// under the License.
17+
package com.cloud.dc;
18+
19+
import org.apache.cloudstack.acl.InfrastructureEntity;
20+
import org.apache.cloudstack.api.Identity;
21+
import org.apache.cloudstack.api.InternalIdentity;
22+
23+
public interface DedicatedResources extends InfrastructureEntity, InternalIdentity, Identity{
24+
long getId();
25+
Long getDataCenterId();
26+
Long getPodId();
27+
Long getClusterId();
28+
Long getHostId();
29+
Long getDomainId();
30+
Long getAccountId();
31+
String getUuid();
32+
33+
}

api/src/com/cloud/deploy/DeploymentClusterPlanner.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
import java.util.List;
2020

21+
import com.cloud.deploy.DeploymentPlanner.ExcludeList;
2122
import com.cloud.exception.InsufficientServerCapacityException;
2223
import com.cloud.vm.VirtualMachine;
2324
import com.cloud.vm.VirtualMachineProfile;
@@ -40,6 +41,7 @@ public interface DeploymentClusterPlanner extends DeploymentPlanner {
4041
List<Long> orderClusters(VirtualMachineProfile<? extends VirtualMachine> vm, DeploymentPlan plan, ExcludeList avoid)
4142
throws InsufficientServerCapacityException;
4243

43-
PlannerResourceUsage getResourceUsage();
44+
PlannerResourceUsage getResourceUsage(VirtualMachineProfile<? extends VirtualMachine> vmProfile,
45+
DeploymentPlan plan, ExcludeList avoid) throws InsufficientServerCapacityException;
4446

4547
}

api/src/com/cloud/event/EventTypes.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public class EventTypes {
103103
public static final String EVENT_NET_IP_ASSIGN = "NET.IPASSIGN";
104104
public static final String EVENT_NET_IP_RELEASE = "NET.IPRELEASE";
105105
public static final String EVENT_PORTABLE_IP_ASSIGN = "PORTABLE.IPASSIGN";
106-
public static final String EVENT_PORTABLE_IP_RELEASE = "PORTABLEIPRELEASE";
106+
public static final String EVENT_PORTABLE_IP_RELEASE = "PORTABLE.IPRELEASE";
107107
public static final String EVENT_NET_RULE_ADD = "NET.RULEADD";
108108
public static final String EVENT_NET_RULE_DELETE = "NET.RULEDELETE";
109109
public static final String EVENT_NET_RULE_MODIFY = "NET.RULEMODIFY";
@@ -436,6 +436,11 @@ public class EventTypes {
436436

437437
public static final String EVENT_PORTABLE_IP_RANGE_CREATE = "PORTABLE.IP.RANGE.CREATE";
438438
public static final String EVENT_PORTABLE_IP_RANGE_DELETE = "PORTABLE.IP.RANGE.DELETE";
439+
public static final String EVENT_PORTABLE_IP_TRANSFER = "PORTABLE.IP.TRANSFER";
440+
441+
// Dedicated Resources
442+
public static final String EVENT_DEDICATE_RESOURCE = "DEDICATE.RESOURCE";
443+
public static final String EVENT_DEDICATE_RESOURCE_RELEASE = "DEDICATE.RESOURCE.RELEASE";
439444

440445
static {
441446

0 commit comments

Comments
 (0)