Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve first load response time #369

Open
Livijn opened this issue May 4, 2022 · 5 comments
Open

Improve first load response time #369

Livijn opened this issue May 4, 2022 · 5 comments

Comments

@Livijn
Copy link

Livijn commented May 4, 2022

Whenever I load an image from a new region it takes about 2s to load. Is there a way to improve this somehow?

One idea I have is to just send a request to the URL from each region when a new image is uploaded. But then I need a proxy for each location. Or is there anyway to specify a header or smth to force a specific edge location in AWS?

@dougtoppin
Copy link
Member

This is a function of how CloudFront works. CloudFront caches on a per region basis. We are researching Origin Shield to improve cache hit ratio. We will update this issue once we make a determination.

@Livijn
Copy link
Author

Livijn commented Oct 31, 2022

Okay, sounds good. Thanks for your response :)

@github-actions
Copy link

This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.

@frankenbubble
Copy link

We use origin shield for over a year, does exactly what you ask for, caching in region

@simonkrol
Copy link
Member

Hi @Livijn,
As an update, we've decided to include this option as a Deployment Parameter, which will allow you to choose a region to enabled Origin Shield in (defaulting to disabled). We plan to have this released in the next minor/major version of SIH.

Thanks for your interest in the Serverless Image Handler :)
Simon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants