-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdevops.xsd
More file actions
190 lines (167 loc) · 6.6 KB
/
Copy pathdevops.xsd
File metadata and controls
190 lines (167 loc) · 6.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
<?xml version="1.0" encoding="UTF-8"?>
<s:schema
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:d="http://spacetimecat.com/xmlns/devops"
xmlns:n="http://spacetimecat.com/xmlns/devops/network"
targetNamespace="http://spacetimecat.com/xmlns/devops"
>
<s:import schemaLocation="network.xsd" namespace="http://spacetimecat.com/xmlns/devops/network"/>
<s:element name="devops">
<s:annotation>
<s:documentation>
<p>A model of the devops of an organization.</p>
<p>Top-level document root element.</p>
</s:documentation>
</s:annotation>
<s:complexType>
<s:choice minOccurs="0" maxOccurs="unbounded">
<s:element ref="d:application"/>
</s:choice>
<s:attributeGroup ref="d:version"/>
</s:complexType>
<s:unique name="name">
<s:selector xpath="d:application"/>
<s:field xpath="d:name"/>
</s:unique>
<s:unique name="url_base">
<s:selector xpath="d:application/d:network/n:forwarding/n:from"/>
<s:field xpath="n:url_base"/>
</s:unique>
</s:element>
<s:attributeGroup name="version">
<s:attribute name="version" type="s:string"/>
</s:attributeGroup>
<s:element name="application">
<s:annotation>
<s:documentation>
<p>An application is a formal system that a machine can execute.</p>
<p>We accomodate mostly-idle bursty applications.</p>
</s:documentation>
</s:annotation>
<s:complexType>
<s:all>
<s:element ref="d:name"/>
<s:element ref="d:description" minOccurs="0"/>
<s:element ref="d:language"/>
<s:element ref="d:resource_requirement" minOccurs="0"/>
<!-- abilities -->
<s:element ref="d:allow_horizontal_scaling" minOccurs="0"/>
<s:element ref="d:network" minOccurs="0"/>
<s:element ref="d:local_admin_port" minOccurs="0"/>
</s:all>
</s:complexType>
</s:element>
<s:element name="name" type="s:string">
<s:annotation>
<s:documentation>Must be unique among applications.</s:documentation>
</s:annotation>
</s:element>
<s:element name="resource_requirement">
<s:complexType>
<s:all>
<s:element ref="d:min_cpu" minOccurs="0"/>
<s:element ref="d:max_cpu" minOccurs="0"/>
<s:element ref="d:min_memory" minOccurs="0"/>
<s:element ref="d:max_memory" minOccurs="0"/>
</s:all>
</s:complexType>
</s:element>
<s:element name="network">
<s:complexType>
<s:choice minOccurs="0" maxOccurs="unbounded">
<s:element ref="n:forwarding"/>
</s:choice>
</s:complexType>
</s:element>
<s:element name="local_admin_port" type="s:nonNegativeInteger">
<s:annotation>
<s:documentation>
<p>Another TCP port the application is listening at for administrative commands.</p>
<p>The port should not be exposed to the public.</p>
</s:documentation>
</s:annotation>
</s:element>
<s:element name="language">
<s:annotation>
<s:documentation>This is about how to build the application.</s:documentation>
</s:annotation>
<s:complexType>
<s:choice>
<s:element ref="d:java"/>
</s:choice>
</s:complexType>
</s:element>
<s:element name="description" type="s:string"/>
<s:element name="java">
<s:annotation>
<s:documentation>
<p>A Java application.</p>
<p>We assume that the Java application uses Maven.</p>
</s:documentation>
</s:annotation>
<s:complexType>
<s:sequence>
<s:element ref="d:main_class"/>
</s:sequence>
</s:complexType>
</s:element>
<s:element name="allow_horizontal_scaling" type="s:boolean">
<s:annotation>
<s:documentation>
<p>The value "true" means that different requests from the same client can be routed to different server instances without confusing the client.</p>
</s:documentation>
</s:annotation>
</s:element>
<s:element name="main_class" type="s:string">
<s:annotation>
<s:documentation>Java application entry point.</s:documentation>
</s:annotation>
</s:element>
<s:element name="min_cpu" type="s:double"/>
<s:element name="max_cpu" type="s:double">
<s:annotation>
<s:documentation>
<p>Maximum CPU while bursting.</p>
<p>The absence of this element means that the application uses as many as possible CPU cores while bursting.</p>
</s:documentation>
</s:annotation>
</s:element>
<s:element name="min_memory" type="d:memory">
<s:annotation>
<s:documentation>
<p>Minimum amount of memory that should be allocated for the application to have acceptable garbage collection overhead.</p>
</s:documentation>
</s:annotation>
</s:element>
<s:element name="max_memory" type="d:memory">
<s:annotation>
<s:documentation>
<p>Maximum memory limit. If the application is near this limit, then allocation may fail or the application may be killed.</p>
<p>The absence of this element means that the system is free to limit the memory to any value above min_memory.</p>
</s:documentation>
</s:annotation>
</s:element>
<s:complexType name="memory">
<s:simpleContent>
<s:extension base="s:nonNegativeInteger">
<s:attributeGroup ref="d:memory"/>
</s:extension>
</s:simpleContent>
</s:complexType>
<s:element name="quantity" type="s:nonNegativeInteger"/>
<s:element name="memory_unit" type="d:memory_unit"/>
<s:attributeGroup name="memory">
<s:attribute name="unit" type="d:memory_unit"/>
</s:attributeGroup>
<s:simpleType name="memory_unit">
<s:annotation>
<s:documentation>Base-2.</s:documentation>
</s:annotation>
<s:restriction base="s:string">
<s:enumeration value="KB"/>
<s:enumeration value="MB"/>
<s:enumeration value="GB"/>
<s:enumeration value="TB"/>
</s:restriction>
</s:simpleType>
</s:schema>