What do you mean by a 'simple JSON cache'? How would you implement it? What makes it simple vs. a "complex" JSON cache?
Based on the very limited description you gave, sure, storing the results of the API request in JSON and serving that cached data to your clients sounds like a reasonable solution.
How’s it going, I'm a Adam, a Full-Stack Engineer, actively searching for work. I'm all about JavaScript. And Frontend but don't let that fool you - I've also got some serious Backend skills.
Location
City of Bath, UK 🇬🇧
Education
10 plus years* active enterprise development experience and a Fine art degree 🎨
I could say it's complex or simple or intermediate, that doesn't matter, nor does what language or platform in all honesty. Perhaps I'm asking about JSON to disk vs redis or equivalent. What are the implications around perf and security. Assuming the file will be stored on a web server.
There isn't enough information to make a decision. I don't know how big the file is, how many users will access it, what the security requirements are, etc. Do the simplest thing you can based on your specific requirements. When it doesn't work anymore due to increased traffic or some other new requirement, you cross that bridge when you get there. Premature optimization is just going to make things harder for you to debug and maintain: en.wikipedia.org/wiki/Program_opti...
How’s it going, I'm a Adam, a Full-Stack Engineer, actively searching for work. I'm all about JavaScript. And Frontend but don't let that fool you - I've also got some serious Backend skills.
Location
City of Bath, UK 🇬🇧
Education
10 plus years* active enterprise development experience and a Fine art degree 🎨
Your question does answer my question though.. I trickled my question and requirements because people take a lot for granted and read the requirements as they want. If I give you less information gradually, you have actually helped, think of it like counciling for developers.
How big are the files? this was unlimited until you mentioned it.
Do I need to cache at all? Yes probably, I need to get around the rate limit of 10 per minute
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
What do you mean by a 'simple JSON cache'? How would you implement it? What makes it simple vs. a "complex" JSON cache?
Based on the very limited description you gave, sure, storing the results of the API request in JSON and serving that cached data to your clients sounds like a reasonable solution.
I could say it's complex or simple or intermediate, that doesn't matter, nor does what language or platform in all honesty. Perhaps I'm asking about JSON to disk vs redis or equivalent. What are the implications around perf and security. Assuming the file will be stored on a web server.
There isn't enough information to make a decision. I don't know how big the file is, how many users will access it, what the security requirements are, etc. Do the simplest thing you can based on your specific requirements. When it doesn't work anymore due to increased traffic or some other new requirement, you cross that bridge when you get there. Premature optimization is just going to make things harder for you to debug and maintain: en.wikipedia.org/wiki/Program_opti...
Your question does answer my question though.. I trickled my question and requirements because people take a lot for granted and read the requirements as they want. If I give you less information gradually, you have actually helped, think of it like counciling for developers.
How big are the files? this was unlimited until you mentioned it.
Do I need to cache at all? Yes probably, I need to get around the rate limit of 10 per minute