Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: multiregion deployment feature #8185

Merged
merged 5 commits into from
Jun 18, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion website/data/docs-navigation.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export default [

{
category: 'deployment',
content: ['fail', 'list', 'pause', 'promote', 'resume', 'status']
content: ['fail', 'list', 'pause', 'promote', 'resume', 'status', 'unblock']
},
'eval-status',
{
Expand Down Expand Up @@ -167,6 +167,7 @@ export default [
'logs',
'meta',
'migrate',
'multiregion',
'network',
'parameterized',
'periodic',
Expand Down
46 changes: 46 additions & 0 deletions website/pages/api-docs/deployments.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -491,3 +491,49 @@ $ curl \
"Index": 20
}
```

## Unblock Deployment

This endpoint is used to manually mark a blocked multiregion deployment as
successful. A blocked deployment is a multiregion deployment within a region
that has completed within a region but is waiting on the other federated
regions. The endpoint can be used in cases where a failed peer region is
unable to communicate its failed deployment status to other regions to force a
deployment to complete.

| Method | Path | Produces |
| ------ | ------------------------------------ | ------------------ |
| `POST` | `/v1/deployment/unblock/:deployment_id` | `application/json` |

The table below shows this endpoint's support for
[blocking queries](/api-docs#blocking-queries) and
[required ACLs](/api-docs#acls).

| Blocking Queries | ACL Required |
| ---------------- | ---------------------- |
| `NO` | `namespace:submit-job` |

### Parameters

- `:deployment_id` `(string: <required>)`- Specifies the UUID of the deployment.
This must be the full UUID, not the short 8-character one. This is specified
as part of the path.

### Sample Request

```shell-session
$ curl \
--request POST \
https://localhost:4646/v1/deployment/unblock/5456bd7a-9fc0-c0dd-6131-cbee77f57577
```

### Sample Response

```json
{
"EvalID": "0d834913-58a0-81ac-6e33-e452d83a0c66",
"EvalCreateIndex": 20,
"DeploymentModifyIndex": 20,
"Index": 20
}
```
73 changes: 73 additions & 0 deletions website/pages/docs/commands/deployment/unblock.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
---
layout: docs
page_title: 'Commands: deployment unblock'
sidebar_title: unblock
description: |
The deployment unblock command is used to manually unblock a deployment.
---

# Command: deployment unblock

The `deployment unblock` command is used to manually mark a blocked
multiregion deployment as successful. A blocked deployment is a multiregion
deployment within a region that has completed within a region but is waiting
on the other [federated regions]. The `deployment unblock` command can be used
in cases where a failed peer region is unable to communicate its failed
deployment status to other regions to force a deployment to complete.

## Usage

```plaintext
nomad deployment unblock [options] <deployment id>
```

The `deployment unblock` command requires a single argument, a deployment ID or
prefix.

## General Options

@include 'general_options.mdx'

## Unblock Options

- `-detach`: Return immediately instead of monitoring. A new evaluation ID
will be output, which can be used to examine the evaluation using the
[eval status] command.

- `-verbose`: Show full information.

## Examples

Manually mark an ongoing deployment as unblocked. The deployment status shows
an error on the unreachable "east" region.

```shell-session
$ nomad deployment unblock 8990cfbc
Deployment "8990cfbc-28c0-cb28-ca31-856cf691b987" unblocked

==> Monitoring evaluation "a2d97ad5"
Evaluation triggered by job "example"
Evaluation within deployment: "8990cfbc"
Evaluation status changed: "pending" -> "complete"
==> Evaluation "a2d97ad5" finished with status "complete"

$ nomad deployment status 8990cfbc
ID = 8990cfbc
Job ID = example
Job Version = 2
Status = successful
Description = Deployment successful

Multi-region Deployment
Region ID Status
west 8990cfbc successful
south 085787e3 blocked
east (error) <none> <none>

Deployed
Task Group Desired Placed Healthy Unhealthy
cache 3 2 1 0
```

[eval status]: /docs/commands/eval-status
[federated regions]: https://learn.hashicorp.com/nomad/operating-nomad/federation
14 changes: 14 additions & 0 deletions website/pages/docs/enterprise/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,21 @@ When a Nomad cluster is at capacity for a given set of placement constraints, an

Preemption enables Nomad's scheduler to automatically evict lower priority allocations of service and batch jobs so that allocations from higher priority jobs can be placed. This behavior ensures that critical workloads can run when resources are limited or when partial outages require workloads to be rescheduled across a smaller set of client nodes.

## Multi-Cluster & Efficiency

Multi-Cluster & Efficiency features are part of an add-on module that enables
an organization to operate Nomad at scale across multiple clusters through
features such as Multiregion Deployments.

### Multiregion Deployments

[Multiregion Deployments] enable an operator to deploy a single job to multiple
federated regions. This includes the ability to control the order of rollouts
and how each region will behave in the event of a deployment failure.

## Try Nomad Enterprise

Click [here](https://www.hashicorp.com/go/nomad-enterprise) to set up a demo or request a trial
of Nomad Enterprise.

[Multiregion Deployments]: /docs/job-specification/multiregion
Loading