1 | <!--
|
---|
2 | Licensed to the Apache Software Foundation (ASF) under one or more
|
---|
3 | contributor license agreements. See the NOTICE file distributed with
|
---|
4 | this work for additional information regarding copyright ownership.
|
---|
5 | The ASF licenses this file to You under the Apache License, Version 2.0
|
---|
6 | (the "License"); you may not use this file except in compliance with
|
---|
7 | 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, software
|
---|
12 | distributed under the License is distributed on an "AS IS" BASIS,
|
---|
13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
---|
14 | See the License for the specific language governing permissions and
|
---|
15 | limitations under the License.
|
---|
16 | -->
|
---|
17 | <html>
|
---|
18 |
|
---|
19 | <head>
|
---|
20 | <link rel="stylesheet" type="text/css" href="../stylesheets/style.css">
|
---|
21 | <title>Sleep Task</title>
|
---|
22 | </head>
|
---|
23 |
|
---|
24 | <body>
|
---|
25 |
|
---|
26 | <h2><a name="sleep">Sleep</a></h2>
|
---|
27 | <h3>Description</h3>
|
---|
28 | <p> A task for sleeping a short period of time, useful when a build or deployment
|
---|
29 | process requires an interval between tasks.</p>
|
---|
30 |
|
---|
31 | <h3>Parameters</h3>
|
---|
32 | <table border="1" cellpadding="2" cellspacing="0">
|
---|
33 | <tr>
|
---|
34 | <td valign="top"><b>Attribute</b></td>
|
---|
35 | <td valign="top"><b>Description</b></td>
|
---|
36 | <td align="center" valign="top"><b>Required</b></td>
|
---|
37 | </tr>
|
---|
38 | <tr>
|
---|
39 | <td valign="top">hours</td>
|
---|
40 | <td valign="top">hours to to add to the sleep time</td>
|
---|
41 | <td valign="top" align="center">No</td>
|
---|
42 | </tr>
|
---|
43 | <tr>
|
---|
44 | <td valign="top">minutes</td>
|
---|
45 | <td valign="top"> minutes to add to the sleep time</td>
|
---|
46 | <td valign="top" align="center">No</td>
|
---|
47 | </tr>
|
---|
48 | <tr>
|
---|
49 | <td valign="top">seconds</td>
|
---|
50 | <td valign="top">seconds to add to the sleep time</td>
|
---|
51 | <td align="center" valign="top">No</td>
|
---|
52 | </tr>
|
---|
53 | <tr>
|
---|
54 | <td valign="top">milliseconds</td>
|
---|
55 | <td valign="top">milliseconds to add to the sleep time</td>
|
---|
56 | <td align="center" valign="top">No</td>
|
---|
57 | </tr>
|
---|
58 | <tr>
|
---|
59 | <td valign="top">failonerror</td>
|
---|
60 | <td valign="top">flag controlling whether to break the build on an error.
|
---|
61 | </td>
|
---|
62 | <td align="center" valign="top">No</td>
|
---|
63 | </tr>
|
---|
64 | </table>
|
---|
65 | <p>The sleep time is the sum of specified values, hours, minutes seconds and milliseconds.
|
---|
66 | A negative value can be supplied to any of them provided the total sleep time
|
---|
67 | is positive</p>
|
---|
68 | <p>Note that sleep times are always hints to be interpred by the OS how it feels
|
---|
69 | - small times may either be ignored or rounded up to a minimum timeslice. Note
|
---|
70 | also that the system clocks often have a fairly low granularity too, which complicates
|
---|
71 | measuring how long a sleep actually took.</p>
|
---|
72 | <h3>Examples</h3>
|
---|
73 | <pre> <sleep milliseconds="10"/></pre>
|
---|
74 | Sleep for about 10 mS.
|
---|
75 | <pre> <sleep seconds="2"/></pre>
|
---|
76 | Sleep for about 2 seconds.
|
---|
77 | <pre> <sleep hours="1" minutes="-59" seconds="-58"/></pre>
|
---|
78 | <p>Sleep for one hour less 59:58, or two seconds again </p>
|
---|
79 | <pre> <sleep/></pre>
|
---|
80 | Sleep for no time at all. This may yield the CPU time to another thread or process.
|
---|
81 |
|
---|
82 |
|
---|
83 | </body>
|
---|
84 | </html>
|
---|
85 |
|
---|