我可以通过正则表达式过滤 gcloud dataproc 集群列表吗?

Can I filter gcloud dataproc clusters list by regular expression?

我想通过正则表达式过滤从 gcloud dataproc clusters list 返回的集群列表,但我认为这不可能。 gcloud topic filters 建议 ~ 运算符允许通过正则表达式进行过滤,所以我尝试了这个:

gcloud dataproc clusters list --region europe-west1 --filter="status.state=RUNNING AND clusterName ~ ${predicate}"

失败:

ERROR: (gcloud.dataproc.clusters.list) INVALID_ARGUMENT: Could not parse the filter: ParserException:
errors {
line: 1
column: 38
message: "syntax error"
token: "~"
}

因此,除了将输出通过管道传输到 grep 之外,我似乎无法做到这一点。 grep 可以,但我宁愿在我的过滤器表达式中这样做。

谁能确认在使用gcloud dataproc clusters list时无法使用正则表达式进行过滤?

假设它不可能,是否值得我请求此功能?如果是,在哪里?

很遗憾,Dataproc 不支持集群过滤器中的正则表达式。