当我在AWS api网关中使用Http代理集成时,抛出500个内部服务器错误且端点地址无效?

时间:2018-11-07 17:19:31

标签: amazon-web-services http swagger aws-api-gateway http-proxy

我在aws api网关中摇摇欲坠的方法是此身份验证工作正常,但无法与http后端集成

    "paths": {
        "/{eventtype}/{eventvalue}": {
          "put": {
            "summary": "Leap events Api",
            "description": "API to consume json payloads to further post on kafka topics",
            "consumes": [
              "application/json"
            ],
            "produces": [
              "application/json"
            ],
             "security":[{
                "sigv4": []
              }],
            "parameters": [

              {
                "in": "body",
                "name": "Payload",
                "description": "Payload",
                "required": true,
                "schema": {
                  "type": "object"
                }
              },
              {
                "in": "path",
                "name": "eventtype",
                "description": "",
                "type": "string",
                "required": true
              },
              {
                "in": "path",
                "name": "eventvalue",
                "description": "",
                "type": "string",
                "required": true
              },
              {
                "in": "query",
                "name": "program",
                "description": "",
                "type": "string",
                "required": true
              },
              {
                "in": "query",
                "name": "sequence",
                "description": "",
                "type": "integer",
                "required": true
              },
              {
                "in": "query",
                "name": "schemaVersion",
                "description": "",
                "type": "integer",
                "required": true
              },
                 {
                "in": "query",
                "name": "timestamp",
                "description": "",
                "type": "integer",
                "required": true
              }
            ],
              "x-amazon-apigateway-integration": {
              "requestParameters": {
                "integration.request.path.eventtype": "method.request.path.eventtype",
                "integration.request.path.eventvalue": "method.request.path.eventvalue",
                "integration.request.querystring.program": "method.request.querystring.program",
                "integration.request.querystring.timestamp": "method.request.querystring.timestamp",
                "integration.request.querystring.schemaVersion": "method.request.querystring.schemaVersion",
                "integration.request.querystring.sequence": "method.request.querystring.sequence"

              }, "responseParameters": {
                 "method.response.body": "integration.response.body"


              },
              "responses":{
              "default":{
                "statusCode": "200"}
                },
              "uri": "https://********/*****/{eventtype}/{eventvalue}",
              "responses": {
                "200": {
                  "statusCode": "200"
                },
                "202": {
                  "statusCode": "202"
                },
                "default": {
                  "statusCode": "400"
                }
              },


              "passthroughBehavior": "when_no_match",
              "httpMethod": "PUT",
              "type": "http_proxy"
            },
            "responses": {
              "200": {
                "description": "OK",
                "schema": {
                  "$ref": "#/definitions/ResponseUpdateputcall"
                }
              },
              "400": {
                "description": "Bad request."
              }
            }
          }
        }
      }

这是我的云监视日志     22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)扩展请求ID:P9kq_Eiso **** wg =                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)正在验证请求的使用计划:93d185c7-e216-11e8-b175-1b52888bceba。 API密钥:API阶段:d ***** 0 / dev                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)已授权API密钥,因为方法'PUT / { } / { }'不需要API密钥。请求不会影响限制或配额限制                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)API密钥和API阶段drjkf6qg20 / dev的使用计划检查成功                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)开始执行请求:93d185c7-e216-11e8-b175-1b52888bceba                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)HTTP方法:PUT,资源路径:/ **** / {****} / {}                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)方法请求路径:{eventvalue = ,eventtype = ***}                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)方法请求查询字符串:{program = workkeys,schemaVersion = 2.0,sequence = 1.0,timestamp = 1531851240}                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)方法请求标头:{X-Amz-Date = 20181106T225203Z,Accept = / ,User-Agent = PostmanRuntime / 7.2.0,X-Forwarded-Proto = https,X-Forwarded-For = 151.148.122.100,Host = api5-dev.act.org,Postman-Token = 8696c60a-bf2d-4edd-9bb4-e55287c3efae,cache-control = no-cache,X-Forwarded-Port = 443,accept-encoding = gzip,deflate,X-Amzn-Trace-Id = Root = 1-5be21b13-26a69774cca2073096ea                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)转换前的方法请求正文:{*****}         22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)由于配置错误,执行失败:无效的端点地址                  22:52:03         (93d185c7-e216-11e8-b175-1b52888bceba)方法完成,状态为:500

我想念什么吗?

0 个答案:

没有答案