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

Feature/cluster id hex #2893

Merged
merged 2 commits into from
Apr 24, 2019
Merged

Feature/cluster id hex #2893

merged 2 commits into from
Apr 24, 2019

Conversation

nikkictl
Copy link

@nikkictl nikkictl commented Apr 23, 2019

What is this change?

Surfaces the hexadecimal cluster id in sensuctl cluster health and sensuctl cluster member-list. Adds the cluster response header to the /health data type and response.

Why is this change necessary?

Closes #2870.

Does your change need a Changelog entry?

Yas.

Do you need clarification on anything?

Nah.

Were there any complications while making this change?

Nah.

Have you reviewed and updated the documentation for this change? Is new documentation required?

sensu/sensu-docs#1390

How did you verify this change?

Updated the following test cases

Before:

(release-5.5.1)$ curl http://127.0.0.1:8080/health | jq .
{
  "Alarms": null,
  "ClusterHealth": [
    {
      "MemberID": 9882886658148555000,
      "Name": "default",
      "Err": "",
      "Healthy": true
    }
  ]
}
(release-5.5.1)$ sensuctl cluster health
         ID            Name     Error   Healthy  
 ────────────────── ────────── ─────── ───────── 
  ac6007e1e32e2d19   backend3           true     
  d39305853d0fb740   backend1           true     
  e01784ae8c57bedb   backend2           true     
(release-5.5.1)$ sensuctl cluster member-list
         ID            Name          Peer URLs             Client URLs       
 ────────────────── ────────── ────────────────────── ────────────────────── 
  ac6007e1e32e2d19   backend3   http://backend3:2380   http://backend3:2379  
  d39305853d0fb740   backend1   http://backend1:2380   http://backend1:2379  
  e01784ae8c57bedb   backend2   http://backend2:2380   http://backend2:2379

After:

(release-5.6.0)$ curl http://127.0.0.1:8080/health | jq .
{
  "Alarms": null,
  "ClusterHealth": [
    {
      "MemberID": 9882886658148555000,
      "Name": "default",
      "Err": "",
      "Healthy": true
    }
  ],
  "Header": {
    "cluster_id": 4255616304056077000,
    "member_id": 9882886658148555000,
    "raft_term": 26
  }
}
(release-5.6.0)$ sensuctl cluster health
=== Cluster ID: 11605770c9b38c21
         ID            Name     Error   Healthy  
 ────────────────── ────────── ─────── ───────── 
  ac6007e1e32e2d19   backend3           true     
  d39305853d0fb740   backend1           true     
  e01784ae8c57bedb   backend2           true     
(release-5.6.0)$ sensuctl cluster member-list
=== Cluster ID: 11605770c9b38c21
         ID            Name          Peer URLs             Client URLs       
 ────────────────── ────────── ────────────────────── ────────────────────── 
  ac6007e1e32e2d19   backend3   http://backend3:2380   http://backend3:2379  
  d39305853d0fb740   backend1   http://backend1:2380   http://backend1:2379  
  e01784ae8c57bedb   backend2   http://backend2:2380   http://backend2:2379  

Nikki Attea added 2 commits April 23, 2019 15:39
Signed-off-by: Nikki Attea <nikki@sensu.io>
Signed-off-by: Nikki Attea <nikki@sensu.io>
@nikkictl nikkictl self-assigned this Apr 23, 2019
@nikkictl nikkictl mentioned this pull request Apr 23, 2019
5 tasks
Copy link
Contributor

@echlebek echlebek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

Copy link
Contributor

@palourde palourde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nikkictl nikkictl merged commit 92156ff into release-5.6.0 Apr 24, 2019
@nikkictl nikkictl deleted the feature/cluster-id-hex branch April 24, 2019 23:24
echlebek added a commit that referenced this pull request Apr 25, 2019
* Create 5.6.0 release branch

Signed-off-by: Eric Chlebek <eric@sensu.io>

* Bugfix for annotations & labels flags (#2881)

Signed-off-by: Simon Plourde <simon@sensu.io>

* Move dashboard source code into its own repository (#2869)

As our project has grown, build targets increased, and time has passed, the ideal of a monorepo housing both the web and backend has simply caused more friction than it has reduced. Today we are moving Sensu Go Web into it's own repository: sensu/web.

Signed-off-by: James Phillips <jamesdphillips@gmail.com>

* [GraphQL] Ensures that all types are registered (#2875)

Types that are not directly referenced by the root Schema type or any of
their children are not immediately registered with the schema. As such to
ensure that ALL types are available we append any that are missing.

Signed-off-by: James Phillips <jamesdphillips@gmail.com>

* Add message bus to tessend (#2886)

Signed-off-by: Nikki Attea <nikki@sensu.io>

* Feature/cluster id hex (#2893)

Signed-off-by: Nikki Attea <nikki@sensu.io>

* Add support for field selectors (#2892)

Signed-off-by: Simon Plourde <simon@sensu.io>

* Proxy api from dashboard daemon (#2885)

Signed-off-by: James Phillips <jamesdphillips@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants