我正在尝试将我的 graphql 架构上传到 aws appsync。我的 graphql 模式有近 5000 行长。我尝试使用 cli 和 gui 上传。
(1.) 使用 cli 时,我不断收到错误“无法解析架构文档 - 确保它是有效的 SDL 格式文档。”
(2.) 使用 gui 时,我的 graphql 模式中所有联合中的管道(例如 union UnionType = Type1 | Type2 | Type3 )都被替换为空格,导致语法错误。通过手动替换空格解决此问题后,选项卡变得无响应,需要被终止。
我尝试从 cli 上传一个带有联合的小型 graphql 模式,并且成功运行。然而,从 gui 中,它导致了在联合中用空格替换管道的相同错误。
我需要帮助使用 aws cli 和 aws console 来理解这种行为。
我正在尝试将自定义警报路由配置添加到我的警报管理器中,作为 kube-prometheus-stack 的一部分部署。但是 prometheus-operator pod 在尝试生成alertmanager configmap 时,由于以下错误而失败:
level=error ts=2021-05-31T06:29:38.883470881Z caller=klog.go:96 component=k8s_client_runtime func=ErrorDepth msg="Sync \"infra-services/prometheus-operator-kube-p-alertmanager\" failed: provision alertmanager configuration: base config from Secret could not be parsed: yaml: unmarshal errors:\n line 19: field matchers not found in type config.plain"
Run Code Online (Sandbox Code Playgroud)
我还在alertmanager容器内使用amtool验证了相同的内容,这给出了相同的错误。这是我的alertmanager.yml 文件:
global:
resolve_timeout: 5m
slack_api_url: https://hooks.slack.com/services/xxxxxx/yyyyy/zzzzzzzzzzz
receivers:
- name: slack-notifications
slack_configs:
- channel: '#alerts'
send_resolved: true
text: '{{ template "slack.myorg.text" . }}'
- name: blackhole-receiver
route:
group_by:
- alertname
group_interval: 5m
group_wait: 30s
receiver: blackhole-receiver
repeat_interval: 12h
routes:
- matchers: …Run Code Online (Sandbox Code Playgroud) 我正在尝试使用aws appsync api(StartSchemaCreation)创建一个新的graphql api的模式,其中包含现有graphql api的模式,我使用aws appsync的GetIntrospectionSchema api进行了转储.但是StartSchemaCreation的--definition参数要求我提供一个graphb模式blob来在新的api中创建.我在.json和.graphql文件中有我的graphql架构,但我不能直接使用它们,因为它给出错误"无法解析架构文档 - 确保它是一个有效的SDL格式的文档."
我需要帮助了解如何通过启动模式创建的--definition参数传递我的graphql模式.
我正在使用aws-cli StartSchemaCreation.