[
https://issues.apache.org/jira/browse/FLINK-30518?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17675907#comment-17675907
]
Yang Wang commented on FLINK-30518:
-----------------------------------
Really sorry for the late response. For native K8s implementation with HA
enabled, we always override the jobmanager.rpc.address to pod IP. So for
standalone mode with HA, we also need to do this in the operator.
You could find the similar logic in the example yaml for standalone mode.
{code:java}
env:
- name: POD_IP
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: status.podIP
# The following args overwrite the value of jobmanager.rpc.address
configured in the configuration config map to POD_IP.
args: ["jobmanager", "$(POD_IP)"] {code}
> [flink-operator] Kubernetes HA Service not working with standalone mode
> -----------------------------------------------------------------------
>
> Key: FLINK-30518
> URL: https://issues.apache.org/jira/browse/FLINK-30518
> Project: Flink
> Issue Type: Bug
> Components: Kubernetes Operator
> Affects Versions: kubernetes-operator-1.3.0
> Reporter: Binh-Nguyen Tran
> Priority: Major
> Attachments: flink-configmap.png, screenshot-1.png
>
>
> -Since flink-conf.yaml is mounted as read-only configmap, the
> /docker-entrypoint.sh script is not able to inject correct Pod IP to
> `jobmanager.rpc.address`. This leads to same address (e.g flink.ns-ext) being
> set for all Job Manager pods. This causes:-
> Setting up FlinkDeployment in Standalone mode with Kubernetes HA Service.
> Problems:
> (1) flink-cluster-config-map always contains wrong address for all 3
> component leaders (see screenshot, should be pod IP instead of clusterIP
> service name)
> (2) Accessing Web UI when jobmanager.replicas > 1 is not possible with error
> {code:java}
> {"errors":["Service temporarily unavailable due to an ongoing leader
> election. Please refresh."]} {code}
>
> ~ flinkdeployment.yaml ~
> {code:java}
> spec:
> mode: standalone
> flinkConfiguration:
> high-availability: kubernetes
> high-availability.storageDir: "file:///opt/flink/storage"
> ...
> jobManager:
> replicas: 3
> ... {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)