Unable to get variable values loaded when resources details are defined in different files

Any inputs to resolve the issue i am facing would be appreciated. I have serverless.yml and directory resource in my workspace where i have defined all the different aws resources details in different files and placed them in resource directory. I am trying to variblize the Buffer intervalinseconds and sizeinmbs properties of kinesis, but the value is not loading and it’s throwing error.

Structure of workspace.

my workspace

  • resources/s3-bucket.yml
  • resources/kinesis.yml
  • resources/sns-topic.yml
    serverless.yml

my serverless file looks like below
service: my-service

custom:
BufferingHints:
IntervalInSeconds: ${param:BUFFER_INTERVAL,‘60’}
SizeInMBs: ${param:BUFFER_SIZE,‘5’}

provider:
name: aws
runtime: nodejs18.x
stage: qa
region: us-east-1

resources:

  • ${file(resources/sns-topic.yml)}
  • ${file(resources/s3-bucket.yml)}
  • ${file(resources/kinesis.yml)}

image