Changes

Jump to navigation Jump to search
241 bytes added ,  09:17, 14 June 2017
|-
| '''Summary'''
|Waits for the completion of a job with the specified {{Code|$id}}. If the function is called with the id of a queued job, or repeatedly executed job, it may stall and never terminate.
|-
| '''Errors'''
<pre class="brush:xquery">
jobs:eval("prof:sleep(1500)", (), map { 'interval': 'PT1S', 'end': 'PT10S' })
</pre>
* The following expression, if stored as a file, calls and evaluates itself every 5 seconds:
<pre class="brush:xquery">
jobs:eval(
file:read-text(static-base-uri()),
map { },
map { 'start': 'PT5S' }
)
</pre>
|}
jobs:result($query)
)
Please remember that this query will cause a deadlock if the asynchronously executed query will be queued. In practice. In practice, you should avoid this pattern and resort to [[XQuery Module#xquery:fork-join|xquery:fork-join]] if you want to do things in parallel.
</pre>
Please note that this query can easily cause a deadlock if the asynchronously executed query will be queued. In practice. In practice, you should avoid this pattern and resort to [[XQuery Module#xquery:fork-join|xquery:fork-join]] if you want to do things in parallel.
|}
Bureaucrats, editor, reviewer, Administrators
13,550

edits

Navigation menu