Skip to content

Commit 89fa121

Browse files
author
Sateesh Chodapuneedi
committed
2 parents 3ec7f8b + 4c397da commit 89fa121

28 files changed

Lines changed: 680 additions & 138 deletions

File tree

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
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+
-->
18+
19+
<!ENTITY PRODUCT "CloudStack">
20+
<!ENTITY BOOKID "Technical Documentation">
21+
<!ENTITY YEAR "2013">
22+
<!ENTITY HOLDER "Apache Software Foundation">
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
<?xml version='1.0' encoding='utf-8' ?>
2+
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
3+
<!ENTITY % BOOK_ENTITIES SYSTEM "CloudStack_GSoC_Guide.ent">
4+
%BOOK_ENTITIES;
5+
<!ENTITY % xinclude SYSTEM "http://www.docbook.org/xml/4.4/xinclude.mod">
6+
%xinclude;
7+
]>
8+
9+
<!-- Licensed to the Apache Software Foundation (ASF) under one
10+
or more contributor license agreements. See the NOTICE file
11+
distributed with this work for additional information
12+
regarding copyright ownership. The ASF licenses this file
13+
to you under the Apache License, Version 2.0 (the
14+
"License"); you may not use this file except in compliance
15+
with the License. You may obtain a copy of the License at
16+
17+
http://www.apache.org/licenses/LICENSE-2.0
18+
19+
Unless required by applicable law or agreed to in writing,
20+
software distributed under the License is distributed on an
21+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
22+
KIND, either express or implied. See the License for the
23+
specific language governing permissions and limitations
24+
under the License.
25+
-->
26+
27+
<book>
28+
<bookinfo id="cloudstack_gsoc_2013">
29+
<title>&PRODUCT; Guide for the 2013 Google Summer of Code</title>
30+
<productname>Apache CloudStack</productname>
31+
<productnumber>4.3.0</productnumber>
32+
<edition>1</edition>
33+
<pubsnumber></pubsnumber>
34+
<abstract>
35+
<para>
36+
Guide for 2013 Google Summer of Code Projects.
37+
</para>
38+
</abstract>
39+
<corpauthor>
40+
<inlinemediaobject>
41+
<imageobject>
42+
<imagedata fileref="Common_Content/images/title_logo.svg" format="SVG" />
43+
</imageobject>
44+
</inlinemediaobject>
45+
</corpauthor>
46+
<xi:include href="Common_Content/Legal_Notice.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />
47+
<xi:include href="Author_Group.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />
48+
</bookinfo>
49+
<xi:include href="gsoc-tuna.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />
50+
51+
</book>
52+

‎docs/en-US/gsoc-tuna.xml‎

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?xml version='1.0' encoding='utf-8' ?>
2+
<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
3+
<!ENTITY % BOOK_ENTITIES SYSTEM "CloudStack_GSoC_Guide.ent">
4+
%BOOK_ENTITIES;
5+
]>
6+
7+
<!-- Licensed to the Apache Software Foundation (ASF) under one
8+
or more contributor license agreements. See the NOTICE file
9+
distributed with this work for additional information
10+
regarding copyright ownership. The ASF licenses this file
11+
to you under the Apache License, Version 2.0 (the
12+
"License"); you may not use this file except in compliance
13+
with the License. You may obtain a copy of the License at
14+
15+
http://www.apache.org/licenses/LICENSE-2.0
16+
17+
Unless required by applicable law or agreed to in writing,
18+
software distributed under the License is distributed on an
19+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
20+
KIND, either express or implied. See the License for the
21+
specific language governing permissions and limitations
22+
under the License.
23+
-->
24+
25+
<chapter id="gsoc-tuna">
26+
<title>Nguyen's 2013 GSoC Proposal</title>
27+
<para>This chapter describes Nguyen 2013 Google Summer of Code project within the &PRODUCT; ASF project. It is a copy paste of the submitted proposal.</para>
28+
</chapter>

‎docs/en-US/multiple-ip-range.xml‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@
2727
Basic zones and security groups-enabled Advanced zones. For security groups-enabled Advanced
2828
zones, it implies multiple subnets can be added to the same VLAN. With the addition of this
2929
feature, you will be able to add IP address ranges from the same subnet or from a different one
30-
when IP address are exhausted. To support this feature, the capability of
30+
when IP address are exhausted. This would in turn allows you to employ higher number of subnets
31+
and thus reduce the address management overhead. To support this feature, the capability of
3132
<code>createVlanIpRange</code> API is extended to add IP ranges also from a different
3233
subnet.</para>
3334
<para>Ensure that you manually configure the gateway of the new subnet before adding the IP range.

‎docs/en-US/pvlan.xml‎

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
<?xml version='1.0' encoding='utf-8' ?>
2+
<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
3+
<!ENTITY % BOOK_ENTITIES SYSTEM "cloudstack.ent">
4+
%BOOK_ENTITIES;
5+
]>
6+
7+
<!-- Licensed to the Apache Software Foundation (ASF) under one
8+
or more contributor license agreements. See the NOTICE file
9+
distributed with this work for additional information
10+
regarding copyright ownership. The ASF licenses this file
11+
to you under the Apache License, Version 2.0 (the
12+
"License"); you may not use this file except in compliance
13+
with the License. You may obtain a copy of the License at
14+
http://www.apache.org/licenses/LICENSE-2.0
15+
Unless required by applicable law or agreed to in writing,
16+
software distributed under the License is distributed on an
17+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18+
KIND, either express or implied. See the License for the
19+
specific language governing permissions and limitations
20+
under the License.
21+
-->
22+
<section id="pvlan">
23+
<title>Isolation in Advanced Zone Using Private VLAN</title>
24+
<para/>
25+
<section id="about-pvlan">
26+
<title>About Private VLAN</title>
27+
<para>In an Ethernet switch, a VLAN is a broadcast domain in which hosts can establish direct
28+
communication with each another at Layer 2. Private VLAN is designed as an extension of VLAN
29+
standard to add further segmentation of the logical broadcast domain. A regular VLAN is a
30+
single broadcast domain, whereas a private VLAN partitions a larger VLAN broadcast domain into
31+
smaller sub-domains. A sub-domain is represented by a pair of VLANs: a Primary VLAN and a
32+
Secondary VLAN. The original VLAN that is being divided into smaller groups is called
33+
Primary, That implies all VLAN pairs in a private VLAN share the same Primary VLAN. All the
34+
secondary VLANs exist only inside the Primary. Each Secondary VLAN has a specific VLAN ID
35+
associated to it, which differentiates one sub-domain from another.</para>
36+
<para>For further reading:</para>
37+
<itemizedlist>
38+
<listitem>
39+
<para><ulink
40+
url="http://www.cisco.com/en/US/docs/switches/lan/catalyst3750/software/release/12.2_25_see/configuration/guide/swpvlan.html#wp1038379"
41+
>Understanding Private VLANs</ulink></para>
42+
</listitem>
43+
<listitem>
44+
<para><ulink url="http://tools.ietf.org/html/rfc5517">Cisco Systems' Private VLANs: Scalable
45+
Security in a Multi-Client Environment</ulink></para>
46+
</listitem>
47+
<listitem>
48+
<para><ulink url="http://kb.vmware.com">Private VLAN (PVLAN) on vNetwork Distributed Switch
49+
- Concept Overview (1010691)</ulink></para>
50+
</listitem>
51+
</itemizedlist>
52+
</section>
53+
<section id="prereq-pvlan">
54+
<title>Prerequisites</title>
55+
<para>Ensure that you configure private VLAN on your physical switches out-of-band.</para>
56+
</section>
57+
</section>

‎docs/publican-gsoc-2013.cfg‎

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Publican configuration file for CloudStack Complete Documentation Set
2+
# Contains all technical docs except release notes
3+
# Config::Simple 4.58
4+
# Tue May 29 00:57:27 2012
5+
#
6+
# Licensed to the Apache Software Foundation (ASF) under one
7+
# or more contributor license agreements. See the NOTICE file
8+
# distributed with this work for additional information#
9+
# regarding copyright ownership. The ASF licenses this file
10+
# to you under the Apache License, Version 2.0 (the
11+
# "License"); you may not use this file except in compliance
12+
# with the License. You may obtain a copy of the License at
13+
# http://www.apache.org/licenses/LICENSE-2.0
14+
#
15+
# Unless required by applicable law or agreed to in writing,
16+
# software distributed under the License is distributed on an
17+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18+
# KIND, either express or implied. See the License for the
19+
# specific language governing permissions and limitations
20+
# under the License.
21+
22+
xml_lang: en-US
23+
type: Book
24+
docname: CloudStack_GSoC_Guide
25+
brand: cloudstack
26+
chunk_first: 1
27+
chunk_section_depth: 1

‎engine/schema/src/com/cloud/vm/dao/UserVmDao.java‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,9 @@ public interface UserVmDao extends GenericDao<UserVmVO, Long> {
5454
/**
5555
* List user vm instances with virtualized networking (i.e. not direct attached networking) for the given account and datacenter
5656
* @param accountId will search for vm instances belonging to this account
57-
* @param dcId will search for vm instances in this zone
5857
* @return the list of vm instances owned by the account in the given data center that have virtualized networking (not direct attached networking)
5958
*/
60-
List<UserVmVO> listVirtualNetworkInstancesByAcctAndZone(long accountId, long dcId, long networkId);
59+
List<UserVmVO> listVirtualNetworkInstancesByAcctAndNetwork(long accountId, long networkId);
6160

6261
List<UserVmVO> listByNetworkIdAndStates(long networkId, State... states);
6362

‎engine/schema/src/com/cloud/vm/dao/UserVmDaoImpl.java‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,11 +283,10 @@ public List<UserVmVO> listRunningByHostId(long hostId) {
283283
}
284284

285285
@Override
286-
public List<UserVmVO> listVirtualNetworkInstancesByAcctAndZone(long accountId, long dcId, long networkId) {
286+
public List<UserVmVO> listVirtualNetworkInstancesByAcctAndNetwork(long accountId, long networkId) {
287287

288288
SearchCriteria<UserVmVO> sc = AccountDataCenterVirtualSearch.create();
289289
sc.setParameters("account", accountId);
290-
sc.setParameters("dc", dcId);
291290
sc.setJoinParameters("nicSearch", "networkId", networkId);
292291

293292
return listBy(sc);

‎server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1835,9 +1835,8 @@ public List<UserVmVO> listLoadBalancerInstances(ListLoadBalancerRuleInstancesCmd
18351835
}
18361836
}
18371837

1838-
IPAddressVO addr = _ipAddressDao.findById(loadBalancer.getSourceIpAddressId());
1839-
List<UserVmVO> userVms = _vmDao.listVirtualNetworkInstancesByAcctAndZone(loadBalancer.getAccountId(),
1840-
addr.getDataCenterId(), loadBalancer.getNetworkId());
1838+
List<UserVmVO> userVms = _vmDao.listVirtualNetworkInstancesByAcctAndNetwork(loadBalancer.getAccountId(),
1839+
loadBalancer.getNetworkId());
18411840

18421841
for (UserVmVO userVm : userVms) {
18431842
// if the VM is destroyed, being expunged, in an error state, or in

‎server/src/com/cloud/vm/UserVmManagerImpl.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4709,7 +4709,7 @@ public boolean unplugNic(Network network, NicTO nic, VirtualMachineTO vm,
47094709

47104710
@Override
47114711
public void prepareStop(VirtualMachineProfile<UserVmVO> profile) {
4712-
UserVmVO vm = profile.getVirtualMachine();
4712+
UserVmVO vm = _vmDao.findById(profile.getId());
47134713
if (vm.getState() == State.Running)
47144714
collectVmDiskStatistics(vm);
47154715
}

0 commit comments

Comments
 (0)