In a python/google app engine app, I’ve got a choice between storing some static data (couple KB in size) in a local json/xml file or putting it into the datastore and querying it from there. The data is created by me, so there’s no issues with badly formed data. In specific terms such as saving quota, less resource usage and app speed, which is the better method for this case?
I’d guess using simplyjson to read from a json file would be better since this method doesn’t require a datastore query, whilst still being reasonably quick.
Taking this further, the app doesn’t require a large data store (currently ~400KB), so would it be worthwhile moving all the data to a json file to get around the quota restrictions?
If your data is small, static and infrequently changed, you’ll get the best performance by just writing your data as a
dictin it’s own module and justimportit where you need it. This would take advantage of the fact that Python will cache your modules on import.