workers txt reading and writing
Hello everyone.
Can I save some data to the txt file in the picture instead of kv storage or can I read the data in this txt file.
what problems can i cause by using this txt file instead of kv storage.
2 Replies
No problems at all. The only downside is that changing this file will only take effect when your entire worker is deployed/updated, since it'll be bundled/included with the worker.
With KV, you could update that in real time via something else, and have the worker read it
If that's not necessary for your use-case, then just bundling it into the worker is perfectly fine 🙂
KV would also let you store much larger things - 25MB per key, and no real limit on keys. Whereas with raw files you bundle directly into the worker, you're going to be limited by the total worker size (10MB now I believe).
thank you for the quick response.
I use KV storage to register ip address or read ip address
instantaneous recording
I will do all of these operations in a txt file 😄
10mb is a sufficient limit for me