Docs
This commit is contained in:
parent
80dd30b03d
commit
999db4cd0f
48
website/source/docs/http/periodic.html.md
Normal file
48
website/source/docs/http/periodic.html.md
Normal file
|
@ -0,0 +1,48 @@
|
|||
---
|
||||
layout: "http"
|
||||
page_title: "HTTP API: /v1/periodic"
|
||||
sidebar_current: "docs-http-periodic"
|
||||
description: >
|
||||
The '/v1/periodic' endpoint is used to interact with periodic jobs.
|
||||
---
|
||||
|
||||
# /v1/periodic
|
||||
|
||||
The `periodic` endpoint is used to interact with a single periodic job. By
|
||||
default, the agent's local region is used; another region can be specified using
|
||||
the `?region=` query parameter.
|
||||
|
||||
## PUT / POST
|
||||
|
||||
<dl>
|
||||
<dt>Description</dt>
|
||||
<dd>
|
||||
Forces a new instance of the periodic job. A new instance will be created
|
||||
even if it violates the job's
|
||||
[`prohibit_overlap`](/docs/jobspec/index.html#prohibit_overlap) settings. As
|
||||
such, this should be only used to immediately run a periodic job.
|
||||
</dd>
|
||||
|
||||
<dt>Method</dt>
|
||||
<dd>PUT or POST</dd>
|
||||
|
||||
<dt>URL</dt>
|
||||
<dd>`/v1/periodic/<ID>/force`</dd>
|
||||
|
||||
<dt>Parameters</dt>
|
||||
<dd>
|
||||
None
|
||||
</dd>
|
||||
|
||||
<dt>Returns</dt>
|
||||
<dd>
|
||||
|
||||
```javascript
|
||||
{
|
||||
"EvalCreateIndex": 7,
|
||||
"EvalID": "57983ddd-7fcf-3e3a-fd24-f699ccfb36f4"
|
||||
}
|
||||
```
|
||||
|
||||
</dd>
|
||||
</dl>
|
|
@ -184,9 +184,10 @@ The `job` object supports the following keys:
|
|||
[here](https://github.com/gorhill/cronexpr#implementation) for full
|
||||
documentation of supported cron specs and the predefined expressions.
|
||||
|
||||
* `prohibit_overlap` - `prohibit_overlap` can be set to true to enforce that
|
||||
the periodic job doesn't spawn a new instance of the job if any of the
|
||||
previous jobs are still running. It is defaulted to false.
|
||||
* <a id="prohibit_overlap">`prohibit_overlap`</a> - `prohibit_overlap` can
|
||||
be set to true to enforce that the periodic job doesn't spawn a new
|
||||
instance of the job if any of the previous jobs are still running. It is
|
||||
defaulted to false.
|
||||
|
||||
An example `periodic` block:
|
||||
|
||||
|
|
|
@ -97,6 +97,10 @@
|
|||
<a href="/docs/http/status.html">Status</a>
|
||||
</li>
|
||||
|
||||
<li<%= sidebar_current("docs-http-periodic") %>>
|
||||
<a href="/docs/http/periodic.html">Periodic Jobs</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<% end %>
|
||||
|
|
Loading…
Reference in a new issue