Instantiating MemoryCache takes ~ 40 seconds locally and leads to wrangler script timeouts
See original GitHub issueDescribe the bug
Instantiating the MemoryCache (lru-cache) in the loader config takes more than 40 seconds on my fast desktop. I also can’t publish with wrangler publish
as I am getting a script timeout due to the same reason. When I remove the cache property in the config object, everything works just fine. What could be the reason and how do I take advantage of the MemoryCache without timing out?
Thanks for this awesome repo and documentation, this is an outstanding project!
Steps to Reproduce the Bug or Issue
- npx create-remix remix-image --template cloudflare-workers
- cd remix-image; yarn add remix-image @next-boost/hybrid-disk-cache
- add
routes/api/image.ts
according to https://remix-image.mcfarl.in/docs/tutorial-extras/cloudflare#transformer withmaxSize: 5e7
- Add image component
Expected behavior
No timeouts, fast startups, working wrangler publish.
Platform
- OS: Linux localhost.localdomain 5.16.18-200.fc35.x86_64 SMP PREEMPT Mon Mar 28 14:10:07 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
- Browser: Chrome, Firefox
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:7 (2 by maintainers)
Top Results From Across the Web
Cache in-memory in ASP.NET Core - Microsoft Learn
In the preceding code, the cache entry is configured with a sliding expiration of three seconds. If the cache entry isn't accessed for...
Read more >metaflow_org/community - Gitter
Is there a way to specify a Docker image for a flow when running locally? ... around 23 seconds while on AWS (when...
Read more >wrangler/CHANGELOG.md at master · cloudflare ... - GitHub
wrangler tail Setting up log streaming from Worker script "test-project". Using ports 8080 and 8081. This may take a few seconds.
Read more >Xdo - River Thames Conditions - Environment Agency - GOV.UK
48 urban garden athinorama, Sajor bah, Idei de amenajare a dormitorului, 24 hour fitness redmond ridge, Hedwig smijers, Names for fish, A second...
Read more >Google Cloud release notes | Documentation
The following release notes cover the most recent changes over the last 60 days. For a comprehensive list of product-specific release notes, see...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Still work in progress, but you can find it here: https://github.com/styxlab/remix-image-cloudflare.
@styxlab @elliotlaws Today I released v1.0.0 of Remix Image and worked on MemoryCache. It appears to work correctly on Cloudflare environments in dev, but it would be great if you could try the updates and let me know if the issues persist. Thanks!