Cloudfront TTL not working as expected

0

I'm redeploying a react spa (Single Page Application) through amplify and am catching some friction. I'm using the cli and have had success using a workflow that allows me to add a custom s3 bucket and auth through identity pools unauthenticated users with a s3 getobject policy added to the role. Then hosting and publishing.

When accessing the Cloudfront ditribution and setting the TTL of objects to 0-60 seconds as well as the max and average I'm still not able to refresh the Cloudfront cache. I've tried to create new behaviors and edit the default behaviors. I also don't have access to the custom s3 bucket when starting the spa from my workstation so I can't develop with the data to populate the spa. These are all new behaviors encounterd on this deployment. The workflow to deploy was identical to previous versions.

1 Answer
0
Accepted Answer

Thank you for the details.

Given the context of a re-deployment, please allow me to assume that edge caches might be already established. It's important to note that adjusting or establishing new behaviors with different TTL values won't automatically purge the cache. If you wish for certain files to reflect updates immediately, you'll need to manually invalidate them in the cache. For step-by-step guidance on this process, please refer to the instructions detailed on this page.

If the issue persists please feel free to provide additional information for further discussion, thank you.

AWS
weidi
answered 9 months ago
profile picture
EXPERT
reviewed a month ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions