Extend Serverless validation schema with the plugin options
See original GitHub issueI am using the follow plugins;
plugins:
- serverless-pseudo-parameters
- serverless-offline
- serverless-dynamodb-local
- serverless-plugin-warmup
And have warm
on my function.
functions:
RestAPI:
name: "${self:custom.myServiceName}"
handler: lambda.handler
memorySize: 128
timeout: 30
description: REST API
events:
- http:
method: ANY
path: /
- http:
method: ANY
path: /{proxy+}
warmup:
enabled: true
environment:
NODE_ENV: ${self:custom.myStage}
Any ideas why this isn’t working? It worked before. But now I get this warning in the console everytime I deploy.
Serverless: Configuration warning at 'functions.RestAPI': unrecognized property 'warmup'
Serverless:
Serverless: Learn more about configuration validation here: http://slss.io/configuration-validation
Serverless:
Serverless: WarmUp: setting 1 lambdas to be warm
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (5 by maintainers)
Top Results From Across the Web
Plugins - Extending the configuration - Serverless Framework
Serverless Framework uses JSON schema validation backed by the AJV library. You can extend the base schema in plugins via:.
Read more >Working with serverless applications - AWS Toolkit for VS Code
Learn how to create and use an AWS Serverless Application by using the AWS Toolkit for Visual Studio Code.
Read more >JSON Schema Store
In supported JSON editors like Visual Studio and Visual Studio Code, schema files can offer auto-completion and validation to make sure your JSON...
Read more >Validation-and-Serialization - Fastify
Fastify uses a schema-based approach, and even if it is not mandatory we recommend using JSON Schema to ... Refer to ajv options...
Read more >Datadog Serverless Framework Plugin
Installing the Datadog Lambda Extension to your Lambda functions as a Lambda layer ( addExtension ) or subscribing the Datadog Forwarder to your...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi @gruckionvit
Reading the link in that warning, it seems that serverless has started to apply schema validation. So now plugins should provide a JSON-schema of their params. No idea of when did that happened… I’ve been going through their release notes but couldn’t find anything. Anyway, it’s not harmful. It’s just a warning meaning that the plugin should provide its schema so it can be properly validated.
I’ll try to add the schema asap.
Thanks for reporting!
Ok. It seems that at some point they changed the schema so properties can be added back to the
custom
properties (see https://github.com/serverless/serverless/commit/51a10aa262af51c5df76e43a804b74c65bba010c).I think that this whole schema validation thing is poorly documented and not very stable, so I wouldn’t rely on it.