Skip to content

[Bug]: RabbitMQ whoami response may have a single string for tags #21048

@ralphm

Description

@ralphm

Bug description

In some older versions of RabbitMQ (e.g. v3.8.2) the response from /api/whoami API call has a single string instead of a list of strings. E.g.:

{"name": "myuser", "tags": "administrator"}

This causes the unmarshalling to the Go struct apiWhoamiResp to fail.

It appears that newer versions, including 3.9.16, don't have this problem.

Expected behavior

Also accept single strings.

Steps to reproduce

  1. Run an old enough version of RabbitMQ
  2. Attempt to configure the RabbitMQ collector
  3. See it fail to parse the response

Installation method

kickstart.sh

System info

n/a

Netdata build info

n/a

Additional info

No response

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions