mochengqian opened a new issue, #940: URL: https://github.com/apache/dubbo-go-pixiu/issues/940
Every `ClusterStore.prepareClusterConfig` call clones the full endpoint slice through `assembleClusterEndpoints`, and every snapshot publish clones again in `newEndpointSnapshot`. The double clone exists for two legitimate boundaries: - `assembleClusterEndpoints` must not mutate operator-supplied `*Endpoint` values while assigning default IDs and names. - `EndpointSnapshot` must not share `*Endpoint` values with the mutable `Config.Endpoints` side. This can create allocation pressure for registries or LLM clusters with high endpoint churn. Proposed: - Add a membership-churn benchmark, for example 1000 endpoints plus repeated `SetEndpoint` calls. - Decide which boundary owns cloning based on behavior compatibility and measured allocation savings. - Keep any behavior-changing option documented in CHANGELOG before implementation. Reference: PR #932 keeps the double clone intentionally to avoid shifting review focus away from snapshot correctness. -- 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]
