Skip to content

Conversation

@qiujian16
Copy link
Member

No description provided.

@openshift-ci openshift-ci bot requested a review from deads2k August 13, 2025 09:40
@openshift-ci
Copy link

openshift-ci bot commented Aug 13, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: qiujian16

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@qiujian16 qiujian16 changed the title Merge cluster-proxy into core [WIP] Merge cluster-proxy into core Aug 13, 2025
registration process begins after the cluster registration process and will not impact normal cluster
registration.

#### Proxy API
Copy link
Member

@xuezhaojun xuezhaojun Aug 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder whether we should use term "proxy", I got some cases that users get confused about cluster-proxy with other "proxy" settings like addonproxyconfig.proxyconfig.

Could we use another term like "tunnel"?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tunnel may not be clearly state the functions. Tunnel would mean that agent and hub is establishing the tunnel, but proxy is more accurate which mean user is proxying the request.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some naming suggestion from chatgpt.

grpxy (grpc proxy, short, sysadmin vibe)

tunnx (tunnel nginx-style)

relayx (captures the agent relay role)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe the complete description of this functionality can be "proxy requests between hub and agent," but it can also be "establish a tunnel between hub and agent that can be used to proxy requests."

For users of this functionality, they indeed only need to know about an endpoint that can proxy requests - they don't need to know about the existence of a "tunnel." However, for developers and maintainers, the term "tunnel" helps distinguish this functionality from other proxy-related features.

If "tunnel" doesn't work, could we adopt other terms such as: gateway, bridge, relay, etc.?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

relay seems ok to me, but since cluster-proxy has been known to many, I am not quite sure how strong the desire to rename.

@jnpacker thought?


#### Installation

To enable the feature, the user needs to enable the feature gate in `ClusterManager` and `Klusterlet` API.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In hub side, except for grpc server, we will also need endpoint and certificates for the http server.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, it is specified in the following.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don‘t we also need cert and endpoint configuration of this http server also set in cluster-manager?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cluster manager will generate the cert. and we only need to configure endpoint I think?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if user want to use their customzied cert as the proxy endpoint maybe exposed in their domain?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

grpc connection is internal used by proxy, but http proxy is facing to user or maybe user's user.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got your point, yes we need at least endpoint of http server. I am not sure we need ca bundle. Do we support setting this in cluster-proxy today?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fix looks good to me

#### Installation

To enable the feature, the user needs to enable the feature gate in `ClusterManager` and `Klusterlet` API.
In addition, A new proxyConfig field should be added in `ClusterManager` API:
Copy link
Member

@skeeey skeeey Aug 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how about introduce a config for grpcserver instead of proxyConifg

type GRPCServerConfiguration struct {
    ImagePullSpec string `json:"imagePullSpec,omitempty"`
    FeatureGates []FeatureGate `json:"featureGates,omitempty"`
    EndpointExposure *GRPCEndpointExposure `json:"endpointExposure,omitempty"` 
}

use featureGates to control proxy or transport hub resources with grpc

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when we use grpc registration driver, does it mean we need to set both in registrationConfig and gRPCconfig?

Copy link
Member

@skeeey skeeey Aug 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, for registrationConfig, we need to set authType with grpc to enable the grpc registration

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

Signed-off-by: Jian Qiu <[email protected]>
endpoint: grpc://<external grpc address>
```

Example of grpc registration with proxy disabled:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Example of grpc registration with proxy disabled:
Example of grpc registration with proxy enabled:

endpoint: grpc://<external grpc address>
```

Example of grpc registraion with proxy enabled:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Example of grpc registraion with proxy enabled:
Example of grpc registraion with proxy disabled:

@qiujian16
Copy link
Member Author

@skeeey @xuezhaojun are your fine with the API change on the clusterManager, if so we will need to update clustermanager API sooner.

@skeeey
Copy link
Member

skeeey commented Aug 26, 2025

@skeeey @xuezhaojun are your fine with the API change on the clusterManager, if so we will need to update clustermanager API sooner.

I'm fine with it

@xuezhaojun
Copy link
Member

/lgtm

@xuezhaojun
Copy link
Member

@skeeey @xuezhaojun are your fine with the API change on the clusterManager, if so we will need to update clustermanager API sooner.

Yes, the PR looks good to me.

Signed-off-by: Jian Qiu <[email protected]>
@openshift-ci
Copy link

openshift-ci bot commented Sep 2, 2025

New changes are detected. LGTM label has been removed.

@qiujian16
Copy link
Member Author

we finally decide we will still follow with addon pattern for cluster-proxy.

/close

@openshift-ci openshift-ci bot closed this Nov 5, 2025
@openshift-ci
Copy link

openshift-ci bot commented Nov 5, 2025

@qiujian16: Closed this PR.

In response to this:

we finally decide we will still follow with addon pattern for cluster-proxy.

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants