简体   繁体   中英

Invoke AWS Lambda across regions using step functions

ers,

I have a Step Function pipeline which links several Lambda's. The Step Function is started using a AWS API Gateway. All aforementioned items are in the same region. However, based on the clients IP origin, I would like to use one lambda of the step function in a different region. I did some research but it seems there is no way of invoking a lambda in a different region as compared to the step function region.

So basically this would mean that I would have to make different API Gateway entrypoints and different Step Function pipelines, different Lambdas for every region I would like to employ to right? Are there some consequences for the S3 storage I use?

If Step Functions don't support cross-region Lambda's (and it appears they don't) my idea would be to use a 'proxy-lambda' in the same region as the Step Function and within the proxy-lambda invoke the cross-region lambda. It's not ideal, you will have to handle pass-through and you will pay twice for the duration of the lambda (1x proxy 1x actual lambda) but it seems a lot easier than having all the elements in all regions.

I know I'm too late to this, but proposing my idea anyway. Maybe use SQS? Put an event into an SQS in the other region and add a lambda trigger.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM