后端MySQL数据库服务器
我正在编写一个 Web 应用程序,其中通过在单个单独的 MySQL 数据库服务器上的数据库表上执行 CRUD 请求,将负载分布在处理请求的多个服务器上。我的应用程序的要求之一是我们希望能够动态地将新服务器添加到请求处理服务器的网络中。为此,我是否需要让数据库服务器知道新服务器,或者只需为新服务器提供 IP 地址和端口号就足够了?
我目前正在使用 java servlet,并且有一个属性文件,其中包含连接到本地 mysql 数据库所需的信息(ip、端口、用户名、pass、dbname)。我是否只需将它们更改为指向远程数据库服务器?
I'm writing a web application where the load is distributed across multiple servers that handle requests, by doing CRUD requests on database tables on a single seperate MySQL database server. One of the requirements of my application is that we want to be able to add a new server dynamically to the network of request handling server. To do this, do I need to make the database server aware of the new server or is simply giving the new server the ip address and port number sufficient?
I'm working with java servlets at the moment and I have a properties file containing the necessary information (ip, port, username, pass, dbname) to connect to a local mysql database. Do I simply change those to point to the remote db server?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

您可以对服务器进行负载平衡。当发送一个请求时,服务器会进行负载平衡。尝试在网上搜索它们。
You can do a load balancing to servers. When one request is sent, the server is load balanced. Try to search for them online.