src/Extra/org/objectweb/proactive/extra/gcmdeployment/schema/DeploymentDescriptorSchema.xsd - scheduling in OW2 ProActive - Gitorious

#

eg. 'wrapper', 'category:python' or '"document database"'

- Blob contents
- Blob history
- Raw blob data

This file looks large and may slow your browser down if we attempt to syntax highlight it, so we are showing it without any pretty colors. Highlight it anyway.

1

    <?xml version="1.0" encoding="UTF-8"?>

2

    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"

3

    	targetNamespace="urn:gcm:deployment:1.0"

4

    	xmlns="urn:gcm:deployment:1.0"

5

    	elementFormDefault="qualified">

6

7

    	<!-- <include schemaLocation="CommonTypes.xsd"></include>  -->

8

     	<xsd:include schemaLocation="CommonTypes.xsd"/>

9

10

    	<xsd:complexType name="abstractGroupElementType" abstract="true">

11

    		<xsd:sequence>

12

    			<xsd:element name="environment" type="environmentVariablesType" minOccurs="0" />

13

    			<xsd:element name="scriptPath" type="pathElementType" minOccurs="0" />

14

    		</xsd:sequence>

15

    		<xsd:attribute name="id" type="idType" use="required" />

16

    		<xsd:attribute name="username" type="usernameType" />

17

    		<xsd:attribute name="commandPath" type="pathElementGeneralType" />

18

    		<xsd:attribute name="bookedNodesAccess">

19

    			<xsd:simpleType>

20

    				<xsd:restriction base="xsd:string">

21

    					<xsd:enumeration value="rsh" />

22

    					<xsd:enumeration value="ssh" />

23

    					<xsd:enumeration value="oarsh" />

24

    				</xsd:restriction>

25

    			</xsd:simpleType>

26

    		</xsd:attribute>

27

    	</xsd:complexType>

28

29

    	<xsd:element name="abstractShElement" type="abstractGroupElementType"></xsd:element>

30

31

    	<xsd:complexType name="peerSetType">

32

    		<xsd:sequence>

33

    			<xsd:element name="peer" type="xsd:string" maxOccurs="unbounded" />

34

    		</xsd:sequence>

35

    	</xsd:complexType>

36

37

    	<!-- a 'MAX' xsd:string constant -->

38

    	<xsd:simpleType name="MAX">

39

    		<xsd:restriction base="xsd:string">

40

    			<xsd:enumeration value="MAX"></xsd:enumeration>

41

    		</xsd:restriction>

42

    	</xsd:simpleType>

43

44

    	<xsd:simpleType name="lookupProtocolType">

45

    		<xsd:restriction base="xsd:string">

46

    			<xsd:enumeration value="RMI"></xsd:enumeration>

47

    			<xsd:enumeration value="HTTP"></xsd:enumeration>

48

    			<xsd:enumeration value="IBIS"></xsd:enumeration>

49

    		</xsd:restriction>

50

    	</xsd:simpleType>

51

52

    	<xsd:complexType name="localClientType">

53

    		<xsd:attribute name="protocol" type="lookupProtocolType"></xsd:attribute>

54

    		<xsd:attribute name="port" type="xsd:positiveInteger"></xsd:attribute>

55

    	</xsd:complexType>

56

57

    	<xsd:complexType name="p2pType">

58

    		<xsd:sequence>

59

    			<xsd:element name="localClient" type="localClientType"></xsd:element>

60

    			<xsd:element name="peerSet" type="peerSetType"></xsd:element>

61

    		</xsd:sequence>

62

    		<xsd:attribute name="nodesAsked">

63

    			<xsd:simpleType>

64

    				<xsd:union memberTypes="xsd:positiveInteger MAX" />

65

    			</xsd:simpleType>

66

    		</xsd:attribute>

67

    	</xsd:complexType>

68

69

    	<xsd:complexType name="lookupType">

70

    		<xsd:attribute name="type" type="lookupProtocolType"></xsd:attribute>

71

    		<xsd:attribute name="hostList" type="xsd:string"></xsd:attribute>

72

    		<xsd:attribute name="port" type="xsd:positiveInteger"></xsd:attribute>

73

    	</xsd:complexType>

74

75

76

    	<xsd:complexType name="acquisitionType">

77

    		<xsd:sequence>

78

    			<xsd:element name="lookup" type="lookupType" minOccurs="1" maxOccurs="1" />

79

    			<xsd:element name="p2p" type="p2pType" minOccurs="0" />

80

    		</xsd:sequence>

81

    	</xsd:complexType>

82

83

    	<xsd:complexType name="abstractResourceType"></xsd:complexType>

84

85

    	<xsd:complexType name="groupRefType">

86

    		<xsd:complexContent>

87

    			<xsd:extension base="abstractResourceType">

88

    				<xsd:sequence>

89

    					<xsd:element name="host" type="hostRefType"></xsd:element>

90

    				</xsd:sequence>

91

    				<xsd:attribute name="refid" type="idType" use="required" />

92

    			</xsd:extension>

93

    		</xsd:complexContent>

94

    	</xsd:complexType>

95

96

    	<xsd:complexType name="bridgeRefType">

97

    		<xsd:complexContent>

98

    			<xsd:extension base="abstractResourceType">

99

    				<!-- FIXME: At least one of these elements mustbe present - but this can't be done

100

    					because there must be at most one host, so either we turn this into a xsd:sequence of elements

101

    					of an abstract common type, and then we have to check in the parser that there is at most one host,

102

    					or we keep it as it is and check in the parser that at least one element is present -->

103

    				<xsd:sequence>

104

    					<xsd:element name="group" type="groupRefType" minOccurs="0" maxOccurs="unbounded"></xsd:element>

105

    					<xsd:element name="bridge" type="bridgeRefType" minOccurs="0" maxOccurs="unbounded"></xsd:element>

106

    					<xsd:element name="host" type="hostRefType" minOccurs="0" maxOccurs="1" />

107

    				</xsd:sequence>

108

    				<xsd:attribute name="refid" type="idType" use="required" />

109

    				<xsd:attribute name="relay" type="xsd:string"></xsd:attribute>

110

    			</xsd:extension>

111

    		</xsd:complexContent>

112

    	</xsd:complexType>

113

114

    	<xsd:element name="abstractResourceElement" abstract="true" type="abstractResourceType"></xsd:element>

115

116

    	<xsd:element name="group" substitutionGroup="abstractResourceElement" type="groupRefType"></xsd:element>

117

118

    	<xsd:element name="bridge" substitutionGroup="abstractResourceElement" type="bridgeRefType"></xsd:element>

119

120

    	<xsd:complexType name="resourceType">

121

    		<xsd:sequence>

122

    			<xsd:element name="host" type="hostRefType" minOccurs="0" maxOccurs="1"></xsd:element>

123

    			<xsd:element ref="abstractResourceElement" minOccurs="0" maxOccurs="unbounded"></xsd:element>

124

    		</xsd:sequence>

125

    	</xsd:complexType>

126

127

    	<xsd:complexType name="toolType">

128

    		<xsd:attribute name="id" type="xsd:string"></xsd:attribute>

129

    		<xsd:attribute name="path" type="pathElementGeneralType"></xsd:attribute>

130

    		<xsd:attribute name="version" type="xsd:string"></xsd:attribute>

131

    	</xsd:complexType>

132

133

    	<xsd:complexType name="homeDirectoryType">

134

    		<xsd:complexContent>

135

    			<xsd:restriction base="pathElementType">

136

    				<xsd:attribute name="base" type="pathElementBaseType" fixed="root" use="required"></xsd:attribute>

137

    				<xsd:attribute name="relpath" type="pathElementGeneralType" use="required"></xsd:attribute>

138

    			</xsd:restriction>

139

    		</xsd:complexContent>

140

    	</xsd:complexType>

141

142

    	<xsd:complexType name="hostType">

143

    		<xsd:sequence>

144

    			<xsd:element name="homeDirectory" type="homeDirectoryType"></xsd:element>

145

    			<xsd:element name="tool" type="toolType" minOccurs="0" maxOccurs="unbounded"></xsd:element>

146

    		</xsd:sequence>

147

    		<xsd:attribute name="id" type="idType" use="required"></xsd:attribute>

148

    		<xsd:attribute name="os" type="osType" use="required"></xsd:attribute>

149

    		<xsd:attribute name="username" type="xsd:string"></xsd:attribute>

150

    		<xsd:attribute name="hostCapacity" type="xsd:positiveInteger" use="optional" />

151

    		<xsd:attribute name="vmCapacity" type="xsd:positiveInteger" use="optional" />

152

    	</xsd:complexType>

153

154

    	<xsd:complexType name="hostRefType">

155

    		<xsd:attribute name="refid" type="idType" use="required" />

156

    	</xsd:complexType>

157

158

    	<xsd:complexType name="abstractInfrastructureType"></xsd:complexType>

159

160

    	<xsd:complexType name="hostsType">

161

    		<xsd:sequence>

162

    			<xsd:element name="host" type="hostType" minOccurs="1" maxOccurs="unbounded" />

163

    		</xsd:sequence>

164

    	</xsd:complexType>

165

166

    	<xsd:complexType name="groupsType">

167

    		<xsd:sequence minOccurs="1">

168

    			<xsd:element ref="abstractShElement" minOccurs="1" maxOccurs="unbounded"></xsd:element>

169

    		</xsd:sequence>

170

    	</xsd:complexType>

171

172

    	<xsd:complexType name="abstractBridgeElementType">

173

    		<xsd:attribute name="id" type="idType" use="required" />

174

    	</xsd:complexType>

175

176

    	<xsd:element name="abstractBridgeElement" type="abstractBridgeElementType"></xsd:element>

177

178

179

    	<xsd:complexType name="bridgesType">

180

    		<xsd:sequence>

181

    			<xsd:element ref="abstractBridgeElement" maxOccurs="unbounded"></xsd:element>

182

    		</xsd:sequence>

183

    	</xsd:complexType>

184

185

    	<xsd:complexType name="infrastructureType">

186

    		<xsd:all>

187

    			<xsd:element name="hosts" type="hostsType" minOccurs="0" />

188

    			<xsd:element name="groups" type="groupsType" minOccurs="0" />

189

    			<xsd:element name="bridges" type="bridgesType" minOccurs="0" />

190

    		</xsd:all>

191

    	</xsd:complexType>

192

193

    	<xsd:element name="GCMDeployment">

194

    		<xsd:complexType>

195

    			<xsd:sequence>

196

    				<xsd:element name="environment" type="environmentType" minOccurs="0" />

197

    				<xsd:element name="resources" type="resourceType" />

198

    				<xsd:element name="acquisition" type="acquisitionType" minOccurs="0" />

199

    				<xsd:element name="infrastructure" type="infrastructureType" />

200

    			</xsd:sequence>

201

    		</xsd:complexType>

202

203

    		<!-- Groups refid/id key correctness -->

204

    		<!--  -->

205

    		<xsd:key name="idKeyGroups">

206

    			<xsd:selector xpath="infrastructure/groups/*" />

207

    			<xsd:field xpath="@id" />

208

    		</xsd:key>

209

    		<xsd:keyref name="refIdKeyGroups" refer="idKeyGroups">

210

    			<xsd:selector xpath="resources/group"></xsd:selector>

211

    			<xsd:field xpath="@refid"></xsd:field>

212

    		</xsd:keyref>

213

214

    		<!-- Bridges refid/id key correctness -->

215

    		<!--  -->

216

    		<xsd:key name="idKeyBridges">

217

    			<xsd:selector xpath="infrastructure/bridges/*" />

218

    			<xsd:field xpath="@id" />

219

    		</xsd:key>

220

    		<xsd:keyref name="refIdKeyBridge" refer="idKeyBridges">

221

    			<xsd:selector xpath="resources/bridge"></xsd:selector>

222

    			<xsd:field xpath="@refid"></xsd:field>

223

    		</xsd:keyref>

224

225

    		<!-- Hosts refid/id key correctness -->

226

    		<!--  -->

227

    		<xsd:key name="idKeyHosts">

228

    			<xsd:selector xpath="infrastructure/hosts/*" />

229

    			<xsd:field xpath="@id" />

230

    		</xsd:key>

231

    		<xsd:keyref name="refIdKeyHost" refer="idKeyHosts">

232

    			<xsd:selector xpath="resources/host"></xsd:selector>

233

    			<xsd:field xpath="@refid"></xsd:field>

234

    		</xsd:keyref>

235

    		<xsd:keyref name="refIdKeyGroupHost" refer="idKeyHosts">

236

    			<xsd:selector xpath="resources/group/host"></xsd:selector>

237

    			<xsd:field xpath="@refid"></xsd:field>

238

    		</xsd:keyref>

239

240

    	</xsd:element>

241

242

    </xsd:schema>