用例是我们考虑通过带有 PubSub 的 Argo 事件触发 Argo 工作流。PubSub 不保证一条消息只传递一次。是否有一种简单的方法可以防止工作流在已经运行时再次被触发?
类似于 CronWorkflows的concurrencyPolicy
设置。
有一些东西要看 - 让我们假设whalesay工作流程:
apiVersion: argoproj.io/v1alpha1
kind: Workflow # new type of k8s spec
metadata:
name: hello-world # name of the workflow spec
namespace: argo
spec:
entrypoint: whalesay # invoke the whalesay template
templates:
- name: whalesay # name of the template
container:
image: docker/whalesay
command: [cowsay]
args: ["hello world"]
resources: # limit the resources
limits:
memory: 32Mi
cpu: 100m
我发现了以下两个有希望的问题 - 但我未能提取此问题的解决方案。