serverless / serverless-google-cloudfunctions

Serverless Google Cloud Functions Plugin – Adds Google Cloud Functions support to the Serverless Framework
https://www.serverless.com
MIT License
272 stars 127 forks source link

feat: Support retry failure policy for event based functions #247

Closed flaviomp closed 2 years ago

flaviomp commented 3 years ago

Resolves #131

functions:
  pubsub-function:
    handler: processPubSub
    events:
      - event:
          eventType: providers/cloud.pubsub/eventTypes/topic.publish
          resource: projects/${self:provider.project}/topics/my-topic
          failurePolicy:
            retry: {}
frederikvanhevel commented 3 years ago

Whats the status of this? I need to be able to set this flag. I would also like to specify the max instances like what is documented here: https://cloud.google.com/functions/docs/max-instances

flaviomp commented 2 years ago

@pgrzesik, based on the latest releases, I think you are the only maintainer for this project. Would you mind to take a look at this? Thanks.

pgrzesik commented 2 years ago

Thanks for pining me @flaviomp - I'm trying to unblock the PRs and push releases if possible, but honestly I'm no expert on Google Cloud itself. The proposed PR looks good though :+1:

oakesja commented 2 years ago

@pgrzesik anyway we can get a new release for this change?

pgrzesik commented 2 years ago

Hey @oakesja :wave: It was just released with 4.3.0

engineforce commented 2 years ago

Sorry, how do I pass backoff properties to the retry object? I cannot find any documentation about what are the properties in this retry object?