serverless-log-forwarding icon indicating copy to clipboard operation
serverless-log-forwarding copied to clipboard

Invalid configuration encountered: unrecognized property 'logForwarding'

Open crunchie84 opened this issue 2 years ago • 2 comments

When running sls deploy I see the following warning:

❯ sls deploy --region eu-west-1 --stage tst --aws-profile my-app --verbose
Running "serverless" from node_modules

Warning: Invalid configuration encountered
  at 'functions.splunkApplicationLogging': unrecognized property 'logForwarding'

Learn more about configuration validation here: http://slss.io/configuration-validation

Expected behaviour

  • no warning for valid configuration properties of the plugin

Reproduction


functions:
  splunkApplicationLogging:
    handler: src/handlers/log-forwarding/logger.handler
    logForwarding:
      # avoid a loop because this lambda ships the logs, it should not recurse itself
      enabled: false

versions used

❯ serverless --version
Running "serverless" from node_modules
Framework Core: 3.11.0 (local) 3.19.0 (global)
Plugin: 6.2.1
SDK: 4.3.2

❯ cat package.json | grep log-forwarding
    "serverless-log-forwarding": "^3.0.1",

As far as the documentation of the plugin goes I have done the right things, its just the serverless framework complaining.

crunchie84 avatar Jun 10 '22 09:06 crunchie84

set configValidationMode: warn/off but anyway it is better to create PR to this plugin with defining schema for function properties as described here https://www.serverless.com/framework/docs/guides/plugins/custom-configuration#function-properties-via-definefunctionproperties

Leshck avatar Jun 30 '22 15:06 Leshck

caused by v2.7.0: https://github.com/serverless/serverless/issues/8422

crunchie84 avatar Jul 01 '22 14:07 crunchie84