[英]Pass dynamic values through GCP cloud scheduler
I need to trigger the Google dataflow jobs with the random/dynamic job_names from the cloud scheduler.我需要使用来自云调度程序的随机/动态 job_names 触发 Google 数据流作业。 I am able to pass the static job name and trigger the Dataflow by passing it in the scheduler body.
我能够传递 static 作业名称并通过将其传递到调度程序主体来触发数据流。 Is there a way to dynamically set this job name through the scheduler?
有没有办法通过调度程序动态设置这个作业名称?
If there is a way to set the current_timestamp or some random_numbers that would help.如果有办法设置 current_timestamp 或一些 random_numbers 会有帮助。
I am aware that we can trigger the dataflow through the cloud function as well.我知道我们也可以通过云 function 触发数据流。 But trying to avoid the no.of services here.
但尽量避免这里的服务数量。
what I have:我拥有的:
{ "job_name": "test-run-df-job" }
What I need:我需要的:
{ "job_name": "test-run-df-job" + CURRENT_TIME() }
Thank you for any help.感谢您的任何帮助。
You can't add dynamic value in Cloud Scheduler.您无法在 Cloud Scheduler 中添加动态值。 You can imagine other services, like Cloud Workflows to do that addition without any code to write (like with a Cloud Functions for instance) and then invoke your Dataflow
您可以想象其他服务,如 Cloud Workflows 无需编写任何代码(例如使用 Cloud Functions)即可完成该添加,然后调用您的数据流
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.