Kaustubh1204 opened a new pull request, #382:
URL: https://github.com/apache/kvrocks-controller/pull/382

   This PR implements a strict mapping between Kvrocks Controller versions and 
the minimal supported Kvrocks versions. It ensures that any node added via the 
API meets the minimum version requirement, preventing incompatibility issues in 
the cluster.
   
   Changes included:
   Added MinKvrocksVersion and CheckKvrocksVersion logic in version/check.go.
   Updated ClusterNodeInfo and GetClusterNodeInfo to parse kvrocks_version (or 
fallback to redis_version).
   Fixed Node ID generation bug in util/string.go (RandString re-seeding issue).
   Corrected defer usage in loops in server/api/cluster.go to prevent resource 
leaks.
   Updated API handlers (server/api/node.go) to perform pre-flight version 
checks before adding nodes.
   Updated unit and integration tests:
   Added TestParseClusterNodeInfo and TestCheckKvrocksVersion.
   Integration tests updated to bypass version checks using 
X-Dont-Check-Kvrocks-Version header.
   Cleaned up resource management with ClusterNode.Close() to prevent memory 
leaks.
   Test Results:
   All unit tests pass successfully.
   Integration tests pass where environment allows; failures in local 
Kvrocks-dependent tests are expected.
   Linting reviewed and cleaned of debug prints and unnecessary imports.
   Impact:
   Nodes running unsupported Kvrocks versions are rejected with clear error 
messages.
   Ensures stable cluster operations and prevents accidental addition of 
incompatible node


-- 
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]

Reply via email to