A typical configuration of config. JSON: <Ignore_js_op> The configuration mainly includes four parts: Master, servers, DB, and memcached. The master is used to define the master port, the servers is used to define the configuration of each server, and the expansion of service processes. DB defines the connection configuration information of the database, and memcached configures the connection configuration information of the memcached service.
Master Configuration
The Management port of the rootport master service; the external http port of the webport master Service, which manages various service processes through web interfaces.
Servers Configuration
No key configured under server is the name of the defined new service process. Add new items to expand the service process. The configuration rules for each service process are as follows: Netport [Optional] provides the port for TCP connection between the client and the user. Rootport [Optional] provides ports connected to other service processes to implement RPC calls between processes. Remoteport [Optional] specifies the list of service processes to be connected to, including the name of the service process to be connected by the rootname and the port of the service process to be connected by the rootport. Name [Optional] Name of the Service Process APP [Optional] specifies the entry module name of the process Log [Optional] specifies the log file storage information of the process. Database [Optional] whether database services are required Mem [Optional] whether memcached cache service is required CPU [Optional] processes are bound to the specified CPU Core for operation, reducing CPU Switching Performance consumption
DB configuration [Optional]
Host database service address User database username Passwd database password Port Database Connection Port Database Name Charset Database Connection Client Encoding
Memcached configuration [Optional] URL memcache connection Configuration Hostname memcached cache allocation name.
|