Serverless Debug日记

项目场景:

在跑一个sklearn部署在serverless的样例遇到了如下问题


问题描述:

serverless.yml配置文件修改为:
functions:
  predict-price:
    handler: handler.predict
    memorySize: 512
    timeout: 30
    events:
      - http:
          path: get-price
          method: get
          request:
            parameters:
              queryStrings:
                medInc: true
                houseAge: true
                aveRooms: true
                aveBedrms: true
                population: true
                aveOccup: true
                latitute: true
                longtitute: true

出现报错

Serverless: Configuration warning at 'functions['predict-price'].events[0].http.request.parameters': unrecognized property 'queryStrings'
Serverless:  
Serverless: Learn more about configuration validation here: http://slss.io/configuration-validation
Serverless:  
Serverless: Deprecation warning: Starting with next major version, API Gateway naming will be changed from "{stage}-{service}" to "{service}-{stage}".
            Set "provider.apiGateway.shouldStartNameWithService" to "true" to adapt to the new behavior now.
            More Info: https://www.serverless.com/framework/docs/deprecations/#AWS_API_GATEWAY_NAME_STARTING_WITH_SERVICE
Serverless: Setting up AWS...

 Serverless Error ---------------------------------------
 
  The security token included in the request is invalid.
 
  Get Support --------------------------------------------
     Docs:          docs.serverless.com
     Bugs:          github.com/serverless/serverless/issues
     Issues:        forum.serverless.com

解决方案:

将region改为us-east-1
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值