Closed varas closed 4 years ago
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
@varas If I remember correctly, it was implemented this way because the SDK would fail if username and password were empty, but in most cases JMX wouldn't complain if user/pass were set if auth wasn't enabled. Have you tested this against an instance with no auth?
Yes I tested this against a JMX server without authentication. Also, sdk args package enforces default value when there's an empty value. Therefore without args package update there's no way to provide no username/pass if default values aren't empty :(
I tested running nri-jmx agains an endpoint with no auth and it fails because of this admin/admin enforcement. And it works just fine with this update.
Description of the changes
Default values for username & password should be empty.
Args do not distinguish between empty and no value, so when values are not provided default values are used. Sane default values should be no username, nor password. Otherwise connection might fail.
PR Review Checklist
Author
Reviewer