Hi ziont,
For user support and questions, please send e-mails to u...@flink.apache.org
.

For your question, to my best knowledge, the deployment mode(k8s/yarn) has
nothing to do with timezone. So there is no such timezone K8S configuration.
SQL has such a config as it needs it to decide how to process your
timestamp data. But as you are using datastream API, you have complete
control over how to interpret/store the timestamp. To debug the issue with
your timestamp data, you can consider creating a simple datastream job to
reproduce the problem. And add codes in each operator to display the
timestamp data and the effective time zone before sinking the record to
Pulsar.

Best,
Biao Geng


ziont <screamingout...@163.com> 于2024年5月24日周五 17:56写道:

> Hi everyone!
> Our team deployed flink:1.18.0 using native_kubernetes application
> mode.The version of k8s is 1.28.2.The startup command used is as follows
> ```
> ./flink run-application \
>     --target kubernetes-application \
>     -Dkubernetes.cluster-id=dba-tms-prod-application-saikov2  \
>  -Dkubernetes.container.image=
> docker.io/library/flink-tms-prod-jhid-v2:latest \
>  -Dkubernetes.jobmanager.replicas=1 \
>  -Dtaskmanager.memory.process.size=4096m \
>  -Dtaskmanager.numberOfTaskSlots=3 \
>  -Dkubernetes.namespace=flink18 \
>  -Dkubernetes.jobmanager.service-account=flink \
>  -Dexternal-resource.limits.kubernetes.cpu=2000m \
>  -Dexternal-resource.limits.kubernetes.memory=2Gi \
>  -Dexternal-resource.requests.kubernetes.cpu=1000m \
>  -Dexternal-resource.requests.kubernetes.memory=1Gi \
>  -Dkubernetes.rest-service.exposed.type=NodePort \
>  -Dkubernetes.container.image.pull-policy=Never \
>  -c com.test.tatuke \
>
>  local:///opt/flink/usrlib/flink-tms-1.2.1-SNAPSHOT-jar-with-dependencies.jar
> ```
> This ran successfully. But the timezone is not correct. My project
> architecture is mysql binlog as data source data to pulsar for downstream
> applications to consume.' mysql--flink_user.jar--pulsar'.
> I looked up the official website
> https://nightlies.apache.org/flink/flink-docs-release-1.18/docs/deployment/resource-providers/native_kubernetes/
> but I couldn't find the timezone K8S configuration.
> Our user-jar is using datastream API.
> The kubectl exec into the pod is also in the correct current timezone.
> My database timezone is correct.But the pulsar output msg is wrong.
> I would like to know how to set the timezone somewhere.
> Like when using tableAPI.
> Flink SQL> SET 'table.local-time-zone' = 'America/Los_Angeles';
>
> When I look at the container logs, I don't find the associated output
> WARNING either.
> If there is a suggestion about k8s deployment. You are welcome to give me
> suggestions.
> Thanks a lot.
> ziont
>

Reply via email to