dengliming opened a new pull request, #4403:
URL: https://github.com/apache/hertzbeat/pull/4403

   ## What's changed?
   
   The Redis collector passes the configured username to `withClientName()`, 
leaving the authentication username unset. Connections therefore authenticate 
as `default`, which fails when only the configured ACL user's credentials are 
valid.
   
   Use `withAuthentication(username, password)` when a username is provided, 
while preserving password-only and unauthenticated connections. The fix applies 
to both standalone and cluster clients.
   
   Add regression coverage to the existing `RedisSingleCollectImplTest` for ACL 
credentials, empty passwords, password-only authentication, and unauthenticated 
connections.
   
   ### Validation
   
   - All 12 tests in `RedisSingleCollectImplTest` and 
`RedisClusterCollectImplTest` passed on JDK 25.
   - Checkstyle passed.
   - Mockito was loaded explicitly as a Java agent for the local test run.
   
   ## Checklist
   
   - [x] I have read the [Contributing 
Guide](https://hertzbeat.apache.org/docs/community/code_style_and_quality_guide).
   - [ ] I have written the necessary doc or comment. (Not applicable.)
   - [x] I have added the necessary unit tests and all cases have passed.
   
   ## Add or update API
   
   Not applicable; no API changes.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to