数据库与JSON与嵌入式数据库 [英] Database Vs JSON Vs Embedded Databases

查看:107
本文介绍了数据库与JSON与嵌入式数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个Web应用程序,拥有大量的用户群。该应用程序当前使用MySQL存储所有数据,无论是静态数据还是用户数据。问题是我已经识别出一些永远不会在数据库中频繁更改的数据,但是有可能会改变!

I have a web application which has a fair amount of user base. The application currently uses MySQL for storing all the data, be it static or user data. The problem is that I have recognized some data which is never going to change frequently in the database but there is a probability that it might!

我正在使用REST调用进行提取来自数据库的数据(以JSON形式),我想到的问题是:

I am using REST calls for fetching the data from the database which is in the form of a JSON, the questions in my mind are:


  • 我们应该存储不变的数据吗?作为静态JSON文件?我知道它会破坏我本可以与该数据建立的关系。 ?

推荐答案

关于性能,没有任何假设是安全的。您应该总是测量事物,以便得出结论。因此,在您的位置上,我会做一些负载测试,然后开始进行更改。我会拒绝基于文件的解决方案,并建议下一个优化/更改进行检查:

Regarding performance, no assumptions are safe. You should always measure things, in order to come up with a conclusion. Therefore, in your position I would do some load testing and then start changing things. I would reject the file based solutions and suggest the next optimizations/changes to check:


  • MySQL 提供了一些在内存缓冲区中存储信息以提高性能的功能

  • MySQL provides some capabilities of "storing information in memory buffers to increase performance"

我会考虑使用像 MongoDB 这样的NoSQL数据库针对访问 JSON数据进行了优化。

I would consider using a NoSQL database like MongoDB which is optimized for accessing JSON data.

如果以上条件都不足够,我会考虑使用与内存相关的数据库,例如 VoltDB 具有社区版

If none of the above were adequate, I would consider using a memory related database like VoltDB which has a community edition.

希望我帮助了!

这篇关于数据库与JSON与嵌入式数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆