mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
Moving out XenServer support code into plugins/hypervisors/xen
This commit is contained in:
parent
367e32adbc
commit
550b22576f
@ -198,8 +198,8 @@
|
||||
|
||||
<!-- ===================== Hypervisors ========================= -->
|
||||
|
||||
<target name="compile-hypervisors" depends="compile-ovm" description="Compile all hypervisors"/>
|
||||
<target name="build-hypervisors" depends="build-ovm" description="Builds all hypervisors"/>
|
||||
<target name="compile-hypervisors" depends="compile-ovm, compile-xen" description="Compile all hypervisors"/>
|
||||
<target name="build-hypervisors" depends="build-ovm, build-xen" description="Builds all hypervisors"/>
|
||||
|
||||
<target name="compile-ovm" depends="-init, compile-server" description="Compile OVM">
|
||||
<ant antfile="${base.dir}/plugins/hypervisors/ovm/build.xml" target="build"/>
|
||||
@ -207,6 +207,12 @@
|
||||
<target name="build-ovm" depends="compile-ovm" />
|
||||
|
||||
|
||||
<target name="compile-xen" depends="-init, compile-server" description="Compiles Xen ">
|
||||
<ant antfile="${base.dir}/plugins/hypervisors/xen/build.xml" target="build"/>
|
||||
</target>
|
||||
<target name="build-xen" depends="compile-xen" />
|
||||
|
||||
|
||||
<!-- ===================== Deployment Planners ================= -->
|
||||
|
||||
<target name="compile-deployment-planners" depends="compile-dp-user-dispersing, compile-dp-user-concentrated-pod" description="Compile all dp's"/>
|
||||
|
||||
11
plugins/hypervisors/xen/.classpath
Executable file
11
plugins/hypervisors/xen/.classpath
Executable file
@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/core"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/utils"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/server"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/api"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/deps"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
23
plugins/hypervisors/xen/.project
Executable file
23
plugins/hypervisors/xen/.project
Executable file
@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>Xen</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.python.pydev.PyDevBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.python.pydev.pythonNature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
||||
135
plugins/hypervisors/xen/build.xml
Executable file
135
plugins/hypervisors/xen/build.xml
Executable file
@ -0,0 +1,135 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
contributor license agreements. See the NOTICE file distributed with
|
||||
this work for additional information regarding copyright ownership.
|
||||
The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
(the "License"); you may not use this file except in compliance with
|
||||
the License. You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
-->
|
||||
|
||||
|
||||
<project name="Cloud Stack Xen" default="help" basedir=".">
|
||||
<description>
|
||||
Cloud Stack ant build file
|
||||
</description>
|
||||
|
||||
<dirname property="xen.base.dir" file="${ant.file.Cloud Stack Xen}/"/>
|
||||
<!-- This directory must be set -->
|
||||
<property name="top.dir" location="${xen.base.dir}/../../.."/>
|
||||
<property name="build.dir" location="${top.dir}/build"/>
|
||||
|
||||
<echo message="build.dir=${build.dir}; top.dir=${top.dir}; xen.base.dir=${xen.base.dir}"/>
|
||||
|
||||
<!-- Import anything that the user wants to set-->
|
||||
<!-- Import properties files and environment variables here -->
|
||||
|
||||
<property environment="env" />
|
||||
|
||||
<condition property="build-cloud.properties.file" value="${build.dir}/override/build-cloud.properties" else="${build.dir}/build-cloud.properties">
|
||||
<available file="${build.dir}/override/build-cloud.properties" />
|
||||
</condition>
|
||||
|
||||
<condition property="cloud.properties.file" value="${build.dir}/override/cloud.properties" else="${build.dir}/cloud.properties">
|
||||
<available file="${build.dir}/override/cloud.properties" />
|
||||
</condition>
|
||||
|
||||
<condition property="override.file" value="${build.dir}/override/replace.properties" else="${build.dir}/replace.properties">
|
||||
<available file="${build.dir}/override/replace.properties" />
|
||||
</condition>
|
||||
|
||||
<echo message="Using build parameters from ${build-cloud.properties.file}" />
|
||||
<property file="${build-cloud.properties.file}" />
|
||||
|
||||
<echo message="Using company info from ${cloud.properties.file}" />
|
||||
<property file="${cloud.properties.file}" />
|
||||
|
||||
<echo message="Using override file from ${override.file}" />
|
||||
<property file="${override.file}" />
|
||||
|
||||
<property file="${build.dir}/build.number" />
|
||||
|
||||
<!-- In case these didn't get defined in the build-cloud.properties -->
|
||||
<property name="branding.name" value="default" />
|
||||
<property name="deprecation" value="off" />
|
||||
<property name="target.compat.version" value="1.6" />
|
||||
<property name="source.compat.version" value="1.6" />
|
||||
<property name="debug" value="true" />
|
||||
<property name="debuglevel" value="lines,source"/>
|
||||
|
||||
<echo message="target.dir=${target.dir}; top.dir=${top.dir}"/>
|
||||
<!-- directories for build and distribution -->
|
||||
<property name="target.dir" location="${top.dir}/target" />
|
||||
<property name="classes.dir" location="${target.dir}/classes" />
|
||||
<property name="jar.dir" location="${target.dir}/jar" />
|
||||
<property name="dep.cache.dir" location="${target.dir}/dep-cache" />
|
||||
<property name="build.log" location="${target.dir}/ant_verbose.txt" />
|
||||
|
||||
<property name="deps.dir" location="${top.dir}/deps" />
|
||||
|
||||
<property name="xen.jar" value="cloud-xen.jar" />
|
||||
<property name="xen-scripts.dir" location="${base.dir}/plugins/hypervisors/xen/scripts" />
|
||||
|
||||
<import file="${build.dir}/build-common.xml"/>
|
||||
|
||||
<echo message="target.dir=${target.dir}; top.dir=${top.dir}"/>
|
||||
|
||||
<!-- This section needs to be replaced by some kind of dependency library-->
|
||||
<path id="deps.classpath">
|
||||
<!--filelist files="${deps.classpath}" /-->
|
||||
<fileset dir="${deps.dir}" erroronmissingdir="false">
|
||||
<include name="*.jar" />
|
||||
</fileset>
|
||||
</path>
|
||||
|
||||
<path id="cloudstack.classpath">
|
||||
<fileset dir="${jar.dir}">
|
||||
<include name="*.jar"/>
|
||||
</fileset>
|
||||
</path>
|
||||
|
||||
<path id="xen.classpath">
|
||||
<path refid="deps.classpath"/>
|
||||
<path refid="cloudstack.classpath"/>
|
||||
</path>
|
||||
|
||||
<!-- This section needs to be replaced by some kind of dependency library-->
|
||||
|
||||
<target name="deploy-xen" >
|
||||
<copy todir="${server.deploy.to.dir}/webapps/client/WEB-INF/lib/scripts">
|
||||
<fileset dir="${xen-scripts.dir}">
|
||||
<include name="**/*"/>
|
||||
</fileset>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="init" description="Initialize binaries directory">
|
||||
<mkdir dir="${classes.dir}/${xen.jar}"/>
|
||||
<mkdir dir="${jar.dir}"/>
|
||||
</target>
|
||||
|
||||
<target name="compile-xen" depends="init" description="Compiles Xen ">
|
||||
<compile-java jar.name="${xen.jar}" top.dir="${xen.base.dir}" classpath="xen.classpath" />
|
||||
</target>
|
||||
|
||||
<target name="help" description="help">
|
||||
<echo level="info" message="This is the build file for xenserver"/>
|
||||
<echo level="info" message="You can do a build by doing ant build or clean by ant clean" />
|
||||
</target>
|
||||
|
||||
<target name="clean-xen">
|
||||
<delete dir="${classes.dir}/${xen.jar}"/>
|
||||
</target>
|
||||
|
||||
<target name="build" depends="compile-xen"/>
|
||||
<target name="clean" depends="clean-xen"/>
|
||||
|
||||
</project>
|
||||
@ -53,7 +53,6 @@ import com.cloud.api.ApiConstants;
|
||||
import com.cloud.host.Host.Type;
|
||||
import com.cloud.hypervisor.Hypervisor;
|
||||
import com.cloud.hypervisor.kvm.resource.KvmDummyResourceBase;
|
||||
import com.cloud.hypervisor.xen.resource.CitrixResourceBase;
|
||||
import com.cloud.resource.ServerResource;
|
||||
import com.cloud.utils.exception.CloudRuntimeException;
|
||||
import com.cloud.utils.script.OutputInterpreter;
|
||||
|
||||
@ -36,7 +36,6 @@ import com.cloud.domain.dao.DomainDao;
|
||||
import com.cloud.host.HostVO;
|
||||
import com.cloud.host.dao.HostDao;
|
||||
import com.cloud.hypervisor.Hypervisor.HypervisorType;
|
||||
import com.cloud.hypervisor.xen.resource.XenServerConnectionPool;
|
||||
import com.cloud.resource.ResourceManager;
|
||||
import com.cloud.user.Account;
|
||||
import com.cloud.user.dao.AccountDao;
|
||||
@ -81,6 +80,9 @@ public class Db21to22MigrationUtil {
|
||||
|
||||
/* add guid in cluster table */
|
||||
private void setupClusterGuid() {
|
||||
|
||||
//FIXME moving out XenServer code out of server. This upgrade step need to be taken care of
|
||||
/*
|
||||
XenServerConnectionPool _connPool = XenServerConnectionPool.getInstance();
|
||||
List<ClusterVO> clusters = _clusterDao.listByHyTypeWithoutGuid(HypervisorType.XenServer.toString());
|
||||
for (ClusterVO cluster : clusters) {
|
||||
@ -114,8 +116,10 @@ public class Db21to22MigrationUtil {
|
||||
break;
|
||||
}
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This method migrates the zones based on bug: 7204
|
||||
* based on the param direct.attach.untagged.vlan.enabled, we update zone to basic or advanced for 2.2
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user