Commit graph

14807 commits

Author SHA1 Message Date
Preetha Appan b063fc81a4
Remove unnecessary locking and serverlist syncing in heartbeats
This removes an unnecessary shared lock between discovery and heartbeating
which was causing heartbeats to be missed upon retries when a single server
fails. Also made a drive by fix to call the periodic server shuffler goroutine.
2019-05-06 14:44:55 -05:00
Lang Martin 9f3f11df97
Merge pull request #5601 from hashicorp/b-config-parse-direct-hcl
config parse direct hcl
2019-05-06 12:05:19 -04:00
Lang Martin 2cae46bf31
Merge pull request #5631 from hashicorp/b-system-sched-constraint-errors
fix system sched constraint errors
2019-05-06 11:53:40 -04:00
Mahmood Ali 12208a8cd8
Merge pull request #5653 from hashicorp/b-s3-virtualbucket-style
docs: update s3 urls to use virtual bucket style
2019-05-06 11:40:48 -04:00
Mahmood Ali 835827ebcd
Merge pull request #5651 from hashicorp/f-peers-json-info
Update peers info with new raft config details
2019-05-06 11:40:35 -04:00
Mahmood Ali bfc907827c docs: update s3 urls to use virtual bucket style
In response to https://forums.aws.amazon.com/ann.jspa?annID=6776
2019-05-06 10:39:51 -04:00
Charlie Voiselle 175656ad46
Merge pull request #5652 from jweissig/patch-6
Fix Typo
2019-05-05 15:15:31 -04:00
Justin Weissig e2ea24a0de
Fix Typo
Fixed Typo: Behing/Behind.
2019-05-05 05:42:40 -07:00
Preetha Appan a4b9f53d43
update changelog 2019-05-03 17:07:27 -05:00
Preetha 116b7d0a61
Merge pull request #5645 from hashicorp/b-deploy-health
Update deployment health on failed allocations only if health is unset
2019-05-03 17:04:18 -05:00
Mahmood Ali 92c133b905 Update peers info with new raft config details 2019-05-03 16:55:53 -04:00
Mahmood Ali 9325723e5e
Merge pull request #5629 from hbasappa/peersjon
Add support in nomad for supporting raft 3 protocol peers.json
2019-05-03 15:19:54 -04:00
Michael Schurter 8c7b3ff45a
Fix comment
Co-Authored-By: preetapan <preetha@hashicorp.com>
2019-05-03 10:01:30 -05:00
Michael Schurter e19fa33f9c
Remove unnecessary boolean clause
Co-Authored-By: preetapan <preetha@hashicorp.com>
2019-05-03 10:00:17 -05:00
Preetha Appan b99a204582
Update deployment health on failed allocations only if health is unset
This fixes a confusing UX where a previously successful deployment's
healthy/unhealthy count would get updated if any allocations failed after
the deployment was already marked as successful.
2019-05-02 22:59:56 -05:00
Mahmood Ali 85760a13ae
Merge pull request #5641 from hashicorp/b-task-networks-ports
client: handle 0.8 server network resources
2019-05-02 13:45:07 -04:00
Mahmood Ali 5c498112ff
Merge pull request #5640 from hashicorp/b-fix-omitempty
Update hashicorp/go-msgpack/codec
2019-05-02 12:12:56 -04:00
Hemanth Basappa 3fef02aa93 Add support in nomad for supporting raft 3 protocol peers.json 2019-05-02 09:11:23 -07:00
Mahmood Ali 7a32d3f3aa client: handle 0.8 server network resources
Fixes https://github.com/hashicorp/nomad/issues/5587

When a nomad 0.9 client is handling an alloc generated by a nomad 0.8
server, we should check the alloc.TaskResources for networking details
rather than task.Resources.

We check alloc.TaskResources for networking for other tasks in the task
group [1], so it's a bit odd that we used the task.Resources struct
here.  TaskRunner also uses `alloc.TaskResources`[2].

The task.Resources struct in 0.8 was sparsly populated, resulting to
storing of 0 in port mapping env vars:

```
vagrant@nomad-server-01:~$ nomad version
Nomad v0.8.7 (21a2d93eecf018ad2209a5eab6aae6c359267933+CHANGES)
vagrant@nomad-server-01:~$ nomad server members
Name                    Address      Port  Status  Leader  Protocol  Build  Datacenter  Region
nomad-server-01.global  10.199.0.11  4648  alive   true    2         0.8.7  dc1         global
vagrant@nomad-server-01:~$ nomad alloc status -json 5b34649b | jq '.Job.TaskGroups[0].Tasks[0].Resources.Networks'
[
  {
    "CIDR": "",
    "Device": "",
    "DynamicPorts": [
      {
        "Label": "db",
        "Value": 0
      }
    ],
    "IP": "",
    "MBits": 10,
    "ReservedPorts": null
  }
]
vagrant@nomad-server-01:~$ nomad alloc status -json 5b34649b | jq '.TaskResources'
{
  "redis": {
    "CPU": 500,
    "DiskMB": 0,
    "IOPS": 0,
    "MemoryMB": 256,
    "Networks": [
      {
        "CIDR": "",
        "Device": "eth1",
        "DynamicPorts": [
          {
            "Label": "db",
            "Value": 21722
          }
        ],
        "IP": "10.199.0.21",
        "MBits": 10,
        "ReservedPorts": null
      }
    ]
  }
}
```

Also, updated the test values to mimic how Nomad 0.8 structs are
represented, and made its result match the non compact values in
`TestEnvironment_AsList`.

[1] 24e9040b18/client/taskenv/env.go (L624-L639)
[2] https://github.com/hashicorp/nomad/blob/master/client/allocrunner/taskrunner/task_runner.go#L287-L303
2019-05-02 12:08:38 -04:00
Mahmood Ali a560f4aefc fix HashiStack eBay resource link 2019-05-02 11:19:44 -04:00
Mahmood Ali 7b72105802 Update hashicorp/go-msgpack/codec
To pick up the fix in https://github.com/hashicorp/go-msgpack/pull/8 .
2019-05-02 10:59:09 -04:00
Yishan Lin 575814d4bb
Merge pull request #5636 from hashicorp/yishan/website-revised-resources-page
Yishan/website revised resources page
2019-05-01 18:45:47 -07:00
Yishan Lin 57302910be Cleaned spacing for syntax consistency. 2019-05-01 18:37:34 -07:00
Yishan Lin 53affa67b1 Fixed broken link to Nomad website in README 2019-05-01 11:46:03 -07:00
Yishan Lin 44f8e35586 Moved "Webinars" section below "Who Uses Nomad" 2019-05-01 11:29:22 -07:00
Lang Martin 29ea112586 system_sched & test cleanup comments 2019-05-01 12:25:26 -04:00
Lang Martin c490dacf76 system_sched_test extend the test to check ineligible nodes 2019-05-01 12:25:26 -04:00
Lang Martin c43bcbd35e system_sched when a node is filtered, don't mark failure 2019-05-01 12:25:26 -04:00
Lang Martin aecec5df1b system_sched_test create partially constrained job 2019-05-01 12:25:26 -04:00
Lang Martin 85dae46b51 dev/cluster meta tagged clients, raw_exec 2019-05-01 12:25:26 -04:00
Yishan Lin 0d326be223 Updated Resources Page
- Rewrote overview description
- Reformatted "Community" scetion for consistency with GitHub
- Removed IRC (redundant with Gitter)
- Added "Community Calls" section with links to prior sessions
- Added "Webinar" section with links to prior sessions
- Revised Bug Tracker copy
- Renamed "Tools for Provisioning & Experimentation" to "How to Install Nomad" section
- Bumped up the "How to Install Nomad" section right below to second on the list "Community"
- Removed "Videos" & "Blog Posts" section in favor of accurate segmentation between user talks, webinars, blog posts
- Added "Who Uses Nomad" section in consistency with new GitHub ReadME
- Removed the "Trusted By" section and disclaimer at bottom
2019-04-30 20:55:22 -07:00
Yishan Lin 15a175585e Update main tagline & boilerplate for Nomad 2019-04-30 20:51:18 -07:00
Yishan Lin 30bde7b25d
Merge pull request #5635 from hashicorp/yishan/revised-readme
Added Gitter to Resources + revised Overview in for ReadME.
2019-04-30 20:26:19 -07:00
Yishan Lin 76b4ca9c8c Added CircleCI post, Nic's two guides, and imgix Medium post into README 2019-04-30 18:42:51 -07:00
Yishan Lin 7c8b609a2b Corrected installation link via Omar's input + corrected typo 2019-04-30 13:56:13 -07:00
Yishan Lin 3e42c4067c Fixed link for Installing Nomad for Production 2019-04-30 13:39:32 -07:00
Lang Martin 9cf1c5a74d
Merge pull request #5581 from hashicorp/dev-make-boostrap-git-hooks
Dev make boostrap git hooks
2019-04-30 16:36:10 -04:00
Yishan Lin 9dcbeebbe1 Added Gitter to Resources + revised Overview for consistency. 2019-04-30 12:01:53 -07:00
Mahmood Ali c5150f81dd
Merge pull request #5621 from hashicorp/r-release-preflight
Update release/dist script with preflight
2019-04-30 14:52:03 -04:00
Chris Baker a40477a7b8
test case for 5540 (#5590)
* client/metrics: modified metrics to use (updated) client copy of allocation instead of (unupdated) server copy

* updated armon/go-metrics to address race condition in DisplayMetrics
2019-04-30 10:31:35 -04:00
Lang Martin 2e643d26a2 config_parse leave the *HCL strings in place after converting times 2019-04-30 10:30:53 -04:00
Lang Martin 3ba6095fe3 config_parse_test additional config confirmation w/ sample json 2019-04-30 10:30:53 -04:00
Lang Martin fe9b31dcf9 config comment for future changes 2019-04-30 10:30:53 -04:00
Lang Martin 7e0e9b1ec1 govendor fetch github.com/hashicorp/hcl@99e2f22 2019-04-30 10:30:12 -04:00
Lang Martin 598112a1cc tag HCL bookkeeping keys with json:"-" to keep them out of the api 2019-04-30 10:29:14 -04:00
Lang Martin 43407cffe3 config_parse_test remove redundant parse direct test 2019-04-30 10:29:14 -04:00
Lang Martin b8e9c35cd0 config_parse remove unused multi-stage parsing via mapstructure 2019-04-30 10:29:14 -04:00
Lang Martin 1f86770456 config_parse_test test direct hcl parsing 2019-04-30 10:29:14 -04:00
Lang Martin 5ebae65d1a agent/config, config/* mapstructure tags -> hcl tags 2019-04-30 10:29:14 -04:00
Lang Martin 92fd988c9f config_parse add new ParseConfigFileDirectHCL
- parse by using hcl.Decode directly
- handle time.Duration strings in a second pass
- report unexpected keys in a third pass
2019-04-30 10:29:14 -04:00