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

[NFG] Fix for newer Varnish versions #63

Closed
wants to merge 1 commit into from

Conversation

jangrewe
Copy link
Contributor

Varnishstat's JSON output now has a counters object that contains all the metrics (and a version field to indicate this).
Unfortunately my GoFu is not that good to quickly fix it, but maybe i'll figure it out later.

I guess you should be able to get this to compile in no time. ;-)

{
  "version": 1,
  "timestamp": "2020-09-22T11:55:40",
  "counters": {
    "MGT.uptime": {
      "description": "Management process uptime",
      "flag": "c",
      "format": "d",
      "value": 4725
    },
    ...

…ers" object

```
{
  "version": 1,
  "timestamp": "2020-09-22T11:55:40",
  "counters": {
    "MGT.uptime": {
      "description": "Management process uptime",
      "flag": "c",
      "format": "d",
      "value": 4725
    },
    ...
```
@johanneswuerbach
Copy link
Contributor

Fixed the code and added a test here #64

@jangrewe
Copy link
Contributor Author

jangrewe commented Oct 4, 2020

Thanks @johanneswuerbach for helping out, i can get your version to compile, but i still get no metrics and this warning:

[WARN] Found unexpected data from json: version: "1"

@johanneswuerbach
Copy link
Contributor

Sorry @jangrewe I relied only on the passing tests, but they actually didn't ensure something is scraped. Pushed another commit, which should ensure that something is scraped and fixes the scraping.

@jonnenauha
Copy link
Owner

Merged #64

I'm closing this, @jangrewe I suppose you got the PR branch working after all?

@jonnenauha jonnenauha closed this Dec 18, 2020
@jangrewe
Copy link
Contributor Author

jangrewe commented Jan 8, 2021

Yes, thank you, everything's working fine again! 👍

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.

3 participants