Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

340 lines
12 KiB

  1. <Schema name="VssTestWriterConfig"
  2. xmlns="urn:schemas-microsoft-com:xml-data"
  3. xmlns:dt="urn:schemas-microsoft-com:datatypes">
  4. <!-- Here we define all attributes that may be used across different elements of the document -->
  5. <AttributeType name="filespec" dt:type="string">
  6. <description>
  7. File specification. Can include wildcard characters ? and *
  8. </description>
  9. </AttributeType>
  10. <AttributeType name="path" dt:type="string">
  11. <description>
  12. Path to a file. The path can include environment variables or
  13. values extracted from registry keys.
  14. </description>
  15. </AttributeType>
  16. <AttributeType name="recursive" dt:type="enumeration"
  17. dt:values="yes no">
  18. <description>
  19. Is path specified recursive or limited to the directory that is specified.
  20. </description>
  21. </AttributeType>
  22. <AttributeType name="alternatePath" dt:type="string">
  23. <description>
  24. Alternate path in which to find the file. Files in a file group may
  25. have been copied to an alternative location by the writer. Backup should
  26. pick up the files from the alternative location instead of the original
  27. location but should restore the files to their original location
  28. </description>
  29. </AttributeType>
  30. <AttributeType name="logicalPath" dt:type="string">
  31. <description>
  32. Logical path for a Writer component. This logical name uses backslash
  33. as separators to form a logical namespace hierarchy
  34. </description>
  35. </AttributeType>
  36. <AttributeType name="componentName" dt:type="string">
  37. <description>
  38. Name used to identify a Writer component. May be qualified by a
  39. logical path.
  40. </description>
  41. </AttributeType>
  42. <!-- Here we define all of the possible elements of the document -->
  43. <ElementType name="TestWriter" content="eltOnly" model="closed">
  44. <description>
  45. Configuration information for the VSS Test Writer.
  46. </description>
  47. <AttributeType name="usage" dt:type="enumeration"
  48. dt:values="USER_DATA
  49. BOOTABLE_SYSTEM_STATE
  50. SYSTEM_SERVICE
  51. OTHER">
  52. <description>
  53. How the data associated with the writer is used.
  54. </description>
  55. </AttributeType>
  56. <AttributeType name="verbosity" dt:type="enumeration"
  57. dt:values="low medium high">
  58. <description>
  59. Whether verbose output is enabled.
  60. low: Messages are not printed if files are not properly restored
  61. medium: Most general messages are printed, including warnings if files are not restored
  62. high: Extremely verbose output is enabled.
  63. </description>
  64. </AttributeType>
  65. <AttributeType name="checkExcludes" dt:type="enumeration"
  66. dt:values="yes no">
  67. <description>
  68. Whether to check that excluded files are not restored at restore time.
  69. If restoring to a location that may contain files matching the exclude list,
  70. set this to false to prevent spurious warnings.
  71. </description>
  72. </AttributeType>
  73. <AttributeType name="checkIncludes" dt:type="enumeration"
  74. dt:values="yes no">
  75. <description>
  76. Whether to check that included files are restored at restore time.
  77. </description>
  78. </AttributeType>
  79. <attribute type="usage" default="OTHER" />
  80. <attribute type="verbosity" default="medium" />
  81. <attribute type="checkExcludes" default="yes" />
  82. <attribute type="checkIncludes" default="yes" />
  83. <element type="RestoreMethod" />
  84. <group order="many">
  85. <element type="ExcludeFile" minOccurs="0" maxOccurs="*" />
  86. <element type="Component" minOccurs="0" maxOccurs="*" />
  87. <element type="FailEvent" minOccurs="0" maxOccurs="*" />
  88. </group>
  89. </ElementType>
  90. <ElementType name="RestoreMethod" content="eltOnly" model="closed">
  91. <description>
  92. How restore should be performed. Includes specification of how files
  93. should be restored as well as special steps that should occur in order
  94. to complete the restore.
  95. </description>
  96. <AttributeType name="method" dt:type="enumeration"
  97. dt:values="RESTORE_IF_NONE_THERE
  98. RESTORE_IF_CAN_BE_REPLACED
  99. STOP_RESTART_SERVICE
  100. REPLACE_AT_REBOOT
  101. REPLACE_AT_REBOOT_IF_CANNOT_REPLACE
  102. RESTORE_TO_ALTERNATE_LOCATION
  103. CUSTOM">
  104. <description>
  105. RESTORE_IF_NONE_THERE: i.e., can restore data if it is not at the
  106. location where it was backed up from. This essentially allows
  107. data to be restored to a clean system
  108. RESTORE_IF_CAN_BE_REPLACED: Restore data if all of the files can
  109. be replaced in the orgiginal backup location. Fails if any of
  110. the files are open. If an alternate location is provided, files
  111. will be placed there if they cannot be restored to their original
  112. location.
  113. STOP_RESTART_SERVICE: stop service (service attribute must be
  114. specified). Restore files to original backup location.
  115. Restart service. Fails if any of the files are open after the
  116. service is stopped.
  117. REPLACE_AT_REBOOT: Restore files to a temporary location. Use
  118. MoveFileEx to replace the files at reboot.
  119. REPLACE_AT_REBOOT_IF_CANNOT_REPLACE: Similiar to REPLACE_AT_REBOOT
  120. however files may be restored in place in they are not busy. All files
  121. within a component must be either completely replaced in place or
  122. completely replaced at reboot, so if one component file is busy, all files
  123. in that component must be replaced at reboot.
  124. RESTORE_TO_ALTERNATIVE_LOCATION: Restore files to an alternate
  125. location. Typically writerRestore will indicate that the writer
  126. will participate in the restore process
  127. CUSTOM: Custom restore method. Requestor's should not handle this
  128. case at all for this writer.
  129. </description>
  130. </AttributeType>
  131. <AttributeType name="service" dt:type="string">
  132. <description>
  133. Must be specified if method="STOP_RESTART_SERVICE", indicates
  134. service to be stopped before restoring files.
  135. </description>
  136. </AttributeType>
  137. <AttributeType name="writerRestore" dt:type="enumeration"
  138. dt:values="always never ifReplaceFails">
  139. <description>
  140. Whether writer should be invoked after files are restored to
  141. disk. Options are always, never, and ifReplaceFails. The latter means
  142. that the files will be restored to their original location. If one
  143. or more of the files cannot be replaced, then the files will be
  144. restored to an alternate location (must be specified via
  145. ALTERNATE_LOCATION_MAPPING. After the files are restored, the writer
  146. is invoked.
  147. </description>
  148. </AttributeType>
  149. <AttributeType name="rebootRequired" dt:type="enumeration"
  150. dt:values="yes no">
  151. <description>
  152. Should a reboot be performed after restoring the data for this
  153. writer
  154. </description>
  155. </AttributeType>
  156. <attribute type="method" required="yes" />
  157. <attribute type="service" required="no" />
  158. <attribute type="writerRestore" default="never" />
  159. <attribute type="rebootRequired" default="no" />
  160. <element type="AlternateLocationMapping" minOccurs="0" maxOccurs="*" />
  161. </ElementType>
  162. <ElementType name="Dependency" content="empty" model="closed">
  163. <description>
  164. A dependency from one component to another component in another writer.
  165. </description>
  166. <AttributeType name="writerId" dt:type="uuid" required="yes">
  167. <description>
  168. Id of writer that this component is dependent on.
  169. </description>
  170. </AttributeType>
  171. <attribute type="writerId" required="yes" />
  172. <attribute type="logicalPath" required="no" />
  173. <attribute type="componentName" required="yes" />
  174. </ElementType>
  175. <ElementType name="ComponentFile" content="empty" model="closed">
  176. <description>
  177. Location of a file in a component. For database components, the alternatePath
  178. attribute is ignored.
  179. </description>
  180. <attribute type ="path" required="yes" />
  181. <attribute type="filespec" required="yes" />
  182. <attribute type="recursive" required="yes" />
  183. <attribute type="alternatePath" required="no" />
  184. </ElementType>
  185. <ElementType name="ExcludeFile" content="empty" model="closed">
  186. <description>
  187. Location of a file that the writer should mark as excluded from backup.
  188. </description>
  189. <attribute type ="path" required="yes" />
  190. <attribute type="filespec" required="yes" />
  191. <attribute type="recursive" required="yes" />
  192. </ElementType>
  193. <ElementType name="Component" content="eltOnly" model="closed">
  194. <description>
  195. Description of a Writer component. Currently this can describe either a file-group
  196. component or a database component.
  197. </description>
  198. <AttributeType name="componentType" dt:type="enumeration"
  199. dt:values="database filegroup">
  200. <description>
  201. specified the type of a Writer component
  202. </description>
  203. </AttributeType>
  204. <AttributeType name="selectable" dt:type="enumeration"
  205. dt:values="yes no">
  206. <description>
  207. Is this component selectable for backup or is it always backed up.
  208. If no, then the component is always backed up if any other components of
  209. the application/service are backed up. If yes, then the
  210. component may be selectively backed up.
  211. </description>
  212. </AttributeType>
  213. <AttributeType name="selectableForRestore" dt:type="enumeration"
  214. dt:values="yes no" >
  215. <description>
  216. Is this component selectable for restore
  217. </description>
  218. </AttributeType>
  219. <AttributeType name="restoreTarget" dt:type="enumeration"
  220. dt:values="VSS_RT_ORIGINAL
  221. VSS_RT_ALTERNATE">
  222. <description>
  223. Allows the writer to override the restore method for this component in the PreRestore event.
  224. VSS_RT_ORIGINAL: all files in this component should be restored to their original locations.
  225. VSS_RT_ALTERNATE: all files in this component should be restored to the previously specified alternate location
  226. </description>
  227. </AttributeType>
  228. <attribute type="componentType" required="yes" />
  229. <attribute type="logicalPath" required="no" />
  230. <attribute type="componentName" required="yes" />
  231. <attribute type="selectable" default="yes" />
  232. <attribute type="selectableForRestore" default="no" />
  233. <attribute type="restoreTarget" required="no" />
  234. <group order="many">
  235. <element type="ComponentFile" minOccurs="0" maxOccurs="*" />
  236. <element type="Dependency" minOccurs="0" maxOccurs="*" />
  237. </group>
  238. </ElementType>
  239. <ElementType name="FailEvent" content="empty" model="closed">
  240. <description>
  241. Specifies an event that the Test Writer will fail.
  242. </description>
  243. <AttributeType name="writerEvent" dt:type="enumeration"
  244. dt:values="Identify
  245. PrepareForBackup
  246. PrepareForSnapshot
  247. Freeze
  248. Thaw
  249. PostSnapshot
  250. Abort
  251. BackupComplete
  252. BackupShutdown
  253. PreRestore
  254. PostRestore">
  255. <description>
  256. Defines the list of events that a Writer can fail.
  257. </description>
  258. </AttributeType>
  259. <AttributeType name="retryable" dt:type="enumeration"
  260. dt:values="yes no">
  261. <description>
  262. Whether the failure should be retryable or not
  263. </description>
  264. </AttributeType>
  265. <AttributeType name="numFailures" dt:type="number">
  266. <description>
  267. If the failure is retryable, then this parameter indicates the number of times the writer should
  268. fail the event.
  269. </description>
  270. </AttributeType>
  271. <attribute type="writerEvent" required="yes" />
  272. <attribute type="retryable" default="yes" />
  273. <attribute type="numFailures" default="1" />
  274. </ElementType>
  275. <ElementType name="AlternateLocationMapping" content="empty" model="closed">
  276. <description>
  277. Mapping from a location that was backed up to a location to restore to.
  278. </description>
  279. <attribute type="path" required="yes" />
  280. <attribute type="filespec" required="yes" />
  281. <attribute type="recursive" default="no" />
  282. <attribute type="alternatePath" required="yes" />
  283. </ElementType>
  284. <ElementType name="NewTarget" content="empty" model="closed">
  285. <description>
  286. A new target path for a file that the Writer specifies at restore time.
  287. </description>
  288. <attribute type="path" required="yes" />
  289. <attribute type="filespec" required="yes" />
  290. <attribute type="recursive" required="yes" />
  291. <attribute type="alternatePath" required="no" />
  292. </ElementType>
  293. </Schema>