[ 
https://issues.apache.org/jira/browse/FLINK-29125?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17676486#comment-17676486
 ] 

Wencong Liu edited comment on FLINK-29125 at 1/13/23 6:36 AM:
--------------------------------------------------------------

I think there are several options to represent the cluster identification tag:

*Option1: Use IP & Port of rest server to identify the cluster.*

We can show the tag like this:
{code:java}
Apache Flink Web Dashboard(47.100.234.179:8081){code}
*Option2: Use a ID to identify the cluster:*

Currently, the cluster can be identified by the DispatcherID owned by 
Dispatcher. But I think it's not suitable to use DispatcherID directly, there 
are two reasons:
 # The DispatcherID is generated by leaderSessionID, and leaderSessionID is 
randomly generated during leader selection. If the cluster is standalone, 
DispatcherID will use a default value and cause misunderstanding. In this case 
all clusters will have a same DispatcherID.
 # The length of DispatcherID.toString() is too long, like this 
"00000000-0000-0000-0000-000000000000". It's not pretty to show it on browser 
location bar.

Using a randomly generated fixed-length string to identify the cluster maybe a 
better choice. We can show the tag like this:
{code:java}
Apache Flink Web Dashboard(ID: yy787u){code}
*Option3: Enable the user to set a custom name to cluster in flink-conf.yaml*

Maybe user can add a configuration item like this:
{code:java}
flink.cluster-id: "cluster 1"{code}
Then we can show the tag like this:
{code:java}
Apache Flink Web Dashboard(ID: cluster 1){code}
If the user doesn't specify this item,  the cluster id will not be shown, or we 
can fallback to either *Option1* and {*}Option2{*}.

WDYT? [~dkrovi] [~junhan] [~xtsong] [~ziyang] 


was (Author: JIRAUSER281639):
I think there are several options to represent the cluster identification tag:

*Option1: Use IP & Port of rest server to identify the cluster.*

We can show the tag like this:
{code:java}
Apache Flink Web Dashboard(47.100.234.179:8081){code}
*Option2: Use a ID to identify the cluster:*

Currently, the cluster can be identified by the DispatcherID owned by 
Dispatcher. But I think it's not suitable to use DispatcherID directly, there 
are two reasons:
 # The DispatcherID is generated by leaderSessionID, and leaderSessionID is 
randomly generated during leader selection. If the cluster is standalone, 
DispatcherID will use a default value and cause misunderstanding. In this case 
all clusters will have a same DispatcherID.
 # The length of DispatcherID.toString() is too long, like this 
"00000000-0000-0000-0000-000000000000". It's not pretty to show it on browser 
location bar.

Using a randomly generated fixed-length string to identify the cluster maybe a 
better choice. We can show the tag like this:
{code:java}
Apache Flink Web Dashboard(ID: yy787u){code}
*Option3: Enable the user to set a custom name to cluster in flink-conf.yaml*

Maybe user can add a configuration item like this:
{code:java}
flink.cluster-id: "cluster 1"{code}
Then we can show the tag like this:
{code:java}
Apache Flink Web Dashboard(ID: cluster 1){code}
If the user doesn't specify this item,  the cluster id will not be shown, or we 
can fallback to either *Option1* and {*}Option2{*}.

WDYT? [~dkrovi] [~junhan] [~xtsong] 

> Placeholder in Apache Flink Web Frontend to display some "tags" to 
> distinguish between frontends of different clusters
> ----------------------------------------------------------------------------------------------------------------------
>
>                 Key: FLINK-29125
>                 URL: https://issues.apache.org/jira/browse/FLINK-29125
>             Project: Flink
>          Issue Type: Improvement
>          Components: Runtime / Web Frontend
>            Reporter: Durga Krovi
>            Priority: Major
>              Labels: pull-request-available
>
> When there are several Apache Flink clusters running and the corresponding 
> Web Frontend is opened in browser tabs, it would be great if these UIs can be 
> distinguished in a visible way. Port number in the browser location bar might 
> be useful.
> In our use case, we switch among multiple clusters, connect to only one 
> cluster at a time and use the same port for forwarding. In such a case, there 
> is no visible cue to identify the cluster of the UI being accessed on the 
> browser.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to