WO2019153488A1 - 服务配置管理方法、装置、存储介质和服务器 - Google Patents

服务配置管理方法、装置、存储介质和服务器 Download PDF

Info

Publication number
WO2019153488A1
WO2019153488A1 PCT/CN2018/082836 CN2018082836W WO2019153488A1 WO 2019153488 A1 WO2019153488 A1 WO 2019153488A1 CN 2018082836 W CN2018082836 W CN 2018082836W WO 2019153488 A1 WO2019153488 A1 WO 2019153488A1
Authority
WO
WIPO (PCT)
Prior art keywords
client
service
instruction
central server
management
Prior art date
Application number
PCT/CN2018/082836
Other languages
English (en)
French (fr)
Inventor
谭智文
洪宇明
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2019153488A1 publication Critical patent/WO2019153488A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/50Network service management, e.g. ensuring proper service fulfilment according to agreements
    • H04L41/5041Network service management, e.g. ensuring proper service fulfilment according to agreements characterised by the time relationship between creation and deployment of a service
    • H04L41/5054Automatic deployment of services triggered by the service manager, e.g. service implementation by automatic configuration of network components
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/04Network management architectures or arrangements
    • H04L41/046Network management architectures or arrangements comprising network management agents or mobile agents therefor
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/50Network service management, e.g. ensuring proper service fulfilment according to agreements
    • H04L41/5003Managing SLA; Interaction between SLA and QoS
    • H04L41/5009Determining service level performance parameters or violations of service level contracts, e.g. violations of agreed response time or mean time between failures [MTBF]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/50Network service management, e.g. ensuring proper service fulfilment according to agreements
    • H04L41/508Network service management, e.g. ensuring proper service fulfilment according to agreements based on type of value added network service under agreement
    • H04L41/5096Network service management, e.g. ensuring proper service fulfilment according to agreements based on type of value added network service under agreement wherein the managed service relates to distributed or central networked applications

Definitions

  • the present application relates to the field of information monitoring, and in particular, to a service configuration management method, apparatus, storage medium, and server.
  • Zookeeper is a distributed, open source distributed application coordination service. It is an open source implementation of Google's Chubby and an important component of Hadoop and Hbase.
  • Etcd is a highly available key-value storage system used primarily for shared configuration and service discovery. Etcd is a young project developed and maintained by CoreOS. It is a high-speed iteration and development project that is inspired by Zookeeper and Doozer.
  • distributed coordination systems such as zookeeper and etcd require applications to realize service discovery through the development of driver packages. For old applications that have not been put into development manpower maintenance, it is difficult to access the distributed coordination system to realize service discovery. higher cost.
  • the embodiment of the present application provides a service configuration management method, device, storage medium, and server, so as to solve the problem in the prior art, for an old application that has not been put into development manpower maintenance, accessing the distributed coordination system to implement the service Finding more difficult and costly problems.
  • a first aspect of the embodiment of the present application provides a service configuration management method, including:
  • the proxy server starts the daemon, and listens to the service management instruction sent by the central server and the request management instruction sent by the client;
  • a second aspect of the embodiments of the present application provides a service configuration management system, where the service configuration management system includes: a proxy server, a central server, and a client, where:
  • the central server is configured to send a service management instruction to the proxy server
  • the proxy server is configured to start a daemon process, and listen to the service management instruction sent by the central server; and when the daemon detects the service management instruction sent by the central server actively, the service management instruction is parsed; Sending the parsed service management instruction to the client;
  • the client is configured to receive the parsed service management instruction sent by the proxy server, and perform configuration management according to the parsed service management instruction degree of the service in the client;
  • the client is further configured to actively send a service request instruction to the proxy server;
  • the proxy server is further configured to parse the service request instruction when the daemon detects the service request instruction sent by the client actively during the listening process, and send the parsed service request instruction to the center a server to cause the central server to send a service management instruction that matches the service request instruction to the proxy server.
  • a third aspect of an embodiment of the present application provides a server including a memory and a processor, the memory storing computer readable instructions executable on the processor, the processor executing the computer readable instructions The following steps are implemented:
  • the proxy server starts the daemon, and listens to the service management instruction sent by the central server and the request management instruction sent by the client;
  • a fourth aspect of the embodiments of the present application provides a computer readable storage medium storing computer readable instructions that, when executed by a processor, implement the following steps:
  • the proxy server starts the daemon, and listens to the service management instruction sent by the central server and the request management instruction sent by the client;
  • a fifth aspect of the embodiments of the present application provides a service configuration management apparatus, including:
  • a first instruction intercepting unit configured to start a daemon by the proxy server, listen to a service management instruction sent by the central server, and a request management instruction sent by the client;
  • a first instruction parsing unit configured to parse the service management instruction when the daemon detects the service management instruction sent by the central server actively during the listening process
  • a configuration management unit configured to perform configuration management on the service of the client according to the parsed service management instruction
  • a second instruction parsing unit configured to parse the service request instruction when the daemon process detects a service request instruction sent by the client actively during the listening process
  • a first instruction sending unit configured to send the parsed service request instruction to the central server, so that the central server sends a service management instruction that matches the service request instruction to the proxy server.
  • the daemon is started by the proxy server, and the service management instruction sent by the central server and the request management instruction sent by the client are monitored, and the daemon detects the service management instruction sent by the central server actively during the monitoring process.
  • the service management instruction is parsed, and the service of the client is configured and managed according to the parsed service management instruction.
  • the daemon detects the service request instruction sent by the client actively during the listening process, Parsing the service request instruction, and transmitting the parsed service request instruction to the central server, so that the central server sends a service management instruction that matches the service request instruction to the proxy server.
  • the program monitors the instructions of the central server and the instructions of the client through the daemon of the proxy server, manages and maintains the service configuration of the client in time, and responds to the request sent by the client to the central server in time to effectively implement service discovery and reduce The cost of cluster maintenance in a distributed system.
  • FIG. 1 is a framework diagram of a service configuration management system provided by an embodiment of the present application.
  • FIG. 2 is a flowchart of an implementation of a service configuration management method provided by an embodiment of the present application
  • FIG. 3 is a specific implementation flowchart of a service configuration management method S203 provided by an embodiment of the present application.
  • FIG. 4 is a flowchart of a specific implementation of a service configuration management method S205 according to an embodiment of the present application
  • FIG. 5 is a flowchart of an implementation of a service configuration management method including receiving status information sent by a client according to another embodiment of the present application;
  • FIG. 6 is a structural block diagram of a service configuration management apparatus according to an embodiment of the present application.
  • FIG. 7 is a structural block diagram of a service configuration management apparatus according to another embodiment of the present application.
  • FIG. 8 is a schematic diagram of a server provided by an embodiment of the present application.
  • FIG. 1 is a system architecture diagram of a service configuration management system according to a first embodiment of the present application. The detailed description is as follows: For convenience of description, only parts related to the embodiments of the present application are shown.
  • the service configuration management system includes a central server 1, a proxy server 2, and a client 3, wherein:
  • the central server 1 is configured to send a service management command to the proxy server 2.
  • the service management instruction includes a number of the client 3 to be managed and a configuration file instruction
  • the configuration file instruction includes a configuration file modification instruction, a configuration file deletion instruction, or a configuration file addition instruction.
  • the service management instruction of the central server 1 includes a configuration parameter of a configuration file whose service name corresponds to the service name.
  • the proxy server 2 is configured to start a daemon process and listen to service management instructions sent by the central server 1.
  • the service management instruction is parsed when the daemon detects the service management instruction sent by the central server 1 actively during the listening process.
  • the parsed service management instruction is sent to the client 3.
  • the client 3 is configured to receive the parsed service management command sent by the proxy server 2, and perform configuration management according to the parsed service management command degree of the service in the client 3.
  • the client 3 is further configured to actively send a service request instruction to the proxy server 2.
  • the service request instruction includes the number of the client 3, and further includes a service name requested by the client 3.
  • the proxy server 2 is further configured to parse the service request instruction when the daemon process detects the service request instruction sent by the client 3 actively during the listening process.
  • the parsed service request instruction is sent to the central server 1 to cause the central server 1 to transmit a service management instruction matching the service request instruction to the proxy server 2.
  • the central server 1 and the client 3 are included in the distributed system environment.
  • the proxy server 2 is installed in the distributed system environment, and the instructions of the central server 1 and the instructions of the client 3 are monitored by a daemon process in the proxy server 2.
  • the above daemon is a process that runs in the background and is not controlled by any terminal. Multiple daemons run in the background at the same time, and perform different management tasks.
  • the client 3 is further configured to send a feedback instruction to the proxy server 2, where the feedback instruction includes information that the client 3 reloads the configuration file successfully, and the proxy server 2 sends the feedback instruction to the
  • the central server 1 is configured to notify the central server 1 that the client 3 has reloaded the configuration result.
  • the client 3 includes, but is not limited to, a client 3 with communication capabilities such as a desktop computer, a mobile phone, a notebook, and a tablet.
  • a client 3 with communication capabilities such as a desktop computer, a mobile phone, a notebook, and a tablet.
  • a plurality of clients 3 can be connected to the proxy server 2 by wire or wirelessly.
  • the service configuration management system may adopt Bluetooth technology, WIFI technology or
  • the 3G/4G/5G technology establishes a wireless connection between the proxy server 2 and the central server 1, and can also establish a wired connection between the proxy server 2 and the central server 1 by using serial port technology or USB interface technology.
  • the service configuration management system includes a proxy server, a central server, and a client, and the daemon is started by the proxy server, and the service management instruction sent by the central server and the request management command sent by the client are monitored.
  • the daemon detects the service management instruction sent by the central server, the service management instruction is parsed, and the service of the client is configured and managed according to the parsed service management instruction, and the daemon is monitored during the monitoring process.
  • the daemon detects the service management instruction sent by the central server, parsed, and sending the parsed service request instruction to the central server, so that the central server sends the service request instruction Matching service management instructions to the proxy server.
  • the program monitors the instructions of the central server and the instructions of the client through the daemon of the proxy server, manages and maintains the service configuration of the client in time, and responds to the request sent by the client to the central server in time to effectively implement service discovery and reduce The cost of cluster maintenance in a distributed system.
  • FIG. 2 shows an implementation flow of the service configuration management method provided by the embodiment of the present application.
  • the execution body of the process is the proxy server 2 shown in FIG. 1, and the method flow includes steps S201 to S205.
  • the specific implementation principles of each step are as follows:
  • the proxy server starts the daemon, and listens to the service management instruction sent by the central server and the request management instruction sent by the client.
  • an instruction of the central server and an instruction of the client are monitored by a daemon in the proxy server.
  • the daemon is a process that runs in the background and is not controlled by any terminal.
  • the service management instruction includes a number of a client to be managed and a configuration file instruction
  • the configuration file instruction includes a configuration file modification instruction, a configuration file deletion instruction, or a configuration file addition instruction.
  • the service request instruction includes a number of the client to be managed, and a service name requested by the client.
  • S202 Parse the service management instruction when the daemon detects the service management instruction sent by the central server actively during the monitoring process.
  • S203 Perform configuration management on the service of the client according to the parsed service management instruction.
  • the foregoing S203 specifically includes:
  • A1 Obtain the number of the client in the service management instruction. Specifically, the number of the client to be managed by the proxy server in the service management instruction is obtained. The number of the client is used to identify a client in a distributed system, and the clients in the distributed system respectively have and have only one corresponding number, and the number is unique.
  • A2 Search processing logic of the client current configuration file and the address of the client from the pre-established client registration information table according to the number of the client.
  • the information recorded in the client registration information table is information when the client registers to join the distributed system, including the number and address of the client, and the processing logic of the current configuration file of the client.
  • A3 modifying, according to the configuration file modification instruction, the processing logic of the current configuration file of the client, and the address of the client, the current configuration file of the client, so that the current is detected by the client Reload the configuration file when the configuration file is modified.
  • the processing logic is embodied by a function.
  • the processing logic is a function called when the configuration file is managed.
  • the client that needs to be monitored by the daemon of the proxy server is pre-registered on the proxy server, and the registration information includes the number, address, and processing logic (ie, processing function) of the client.
  • the proxy server establishes a client registration information table according to the registration information sent by the registration client that needs to be monitored.
  • the client registration information table includes the processing number of the client, the address, and the processing logic of the client's configuration file.
  • the processing logic of the current configuration file of the client and the address of the client modify the current configuration file of the client.
  • the configuration file is reloaded, so that the service configuration management of the client is performed in time to implement service discovery.
  • the client detects the configuration file of the service in real time, and determines whether the configuration file of the service is updated.
  • the client detects the configuration file of the service on a periodic basis. When it is detected that the current configuration file is different from the configuration file when the previous cycle is detected, the configuration file is reloaded, thereby automatically updating the service of the client.
  • the method further includes:
  • the daemon monitors a service feedback instruction sent by the client.
  • the proxy server performs configuration management on the service of the client according to the parsed service management instruction
  • the service of the client is updated.
  • the client sends a service feedback instruction to the server.
  • the proxy server notifies the proxy server that the configuration management of the service is successful.
  • S2032 If the service feedback instruction sent by the client is not detected within a specified time, send a reload configuration command to the client according to the preset first command line, so that the client configures according to the overload The instruction reloads the updated configuration file. Specifically, when the service feedback instruction sent by the client is not monitored within a specified time, it is determined that the client loads the updated configuration file and fails.
  • S204 Parse the service request instruction when the daemon detects the service request instruction sent by the client actively during the listening process.
  • the daemon process also listens for the service request instruction sent by the client.
  • the service request instruction includes a number of the client and a service name requested by the client.
  • S205 Send the parsed service request instruction to the central server, so that the central server sends a service management instruction that matches the service request instruction to the proxy server.
  • FIG. 4 shows a specific implementation process of the service configuration management method S205 provided by the embodiment of the present application, which is described in detail as follows:
  • the proxy server parses the service request instruction, and sends the number of the client and the service name in the parsed service request instruction to the central server, and the central server receives the After the number of the client and the service name, the latest configuration file of the service name is searched according to the service name, and sent to the proxy server.
  • the central server searches for the current configuration file of the client according to the number of the client, searches for the latest configuration file corresponding to the service name according to the service name, and searches for the current configuration file and the latest configuration. Comparing the files, generating a configuration file modification instruction according to the comparison result, generating a service management instruction according to the number of the client in the service request instruction and the generated configuration file modification instruction, and sending the service management instruction to the a proxy server, such that the proxy server performs configuration management of the client's services according to the generated service management instructions.
  • the program monitors the instructions of the central server and the instructions of the client through the daemon of the proxy server, manages and maintains the service configuration of the client in time, and responds to the request sent by the client to the central server in time to effectively implement service discovery and reduce The cost of cluster maintenance in a distributed system.
  • FIG. 5 illustrates a service configuration management method including receiving status information sent by a client according to an embodiment of the present application, which is described in detail as follows:
  • S501 The proxy server starts the daemon, and listens to the service management instruction sent by the central server and the request management instruction sent by the client.
  • S502 Parse the service management instruction when the daemon detects the service management instruction sent by the central server actively during the monitoring process.
  • S503 Perform configuration management on the service of the client according to the parsed service management instruction.
  • S504 Parse the service request instruction when the daemon detects the service request instruction sent by the client actively during the listening process.
  • S505 Send the parsed service request instruction to the central server, so that the central server sends a service management instruction that matches the service request instruction to the proxy server.
  • step S501 to step S505 in this embodiment refer to step S201 to step S205 of the foregoing embodiment, and details are not described herein again.
  • the proxy server receives the status information sent by the client, and sends the status information to the central server, so that the central server determines the status of the service of the client according to the status information, and A service management instruction for managing the service of the client is generated according to a status of the service of the client.
  • the status information sent by the client includes the currently available service name, and includes the running status of the client process.
  • the daemon process feeds back the status information of the client to the central server, and the central server may determine the availability status of the client service according to the status information of the client, and generate and the client according to the availability status of the client service.
  • the availability status of the end service corresponds to a service management instruction for managing the availability status of the client service, ie, for different states of the client service, the central server generates different service management instructions.
  • the availability status of the client includes but is not limited to the normal operation of the service, the service failure, and the service version is too low.
  • the proxy server receives status information sent by the client periodically. Specifically, the client may periodically send status information of the service to the daemon.
  • the daemon of the proxy server simultaneously monitors the instructions of the central server and the instructions of the client, manages and maintains the service configuration of the client in time, and responds to the request sent by the client to the central server in time to effectively implement Service discovery, reducing the cost of cluster maintenance in the distributed system.
  • the proxy server receives the status information sent by the client, and sends the status information to the central server, so that the central server is Determining the status of the service of the client, and generating a service management instruction for managing the service of the client according to the status of the service of the client, so as to timely grasp the status of the service in the client, and generate corresponding Service management instructions to enable efficient configuration management of services for the client.
  • FIG. 6 is a structural block diagram of the service configuration management apparatus provided by the embodiment of the present application. For the convenience of description, only parts related to the embodiment of the present application are shown.
  • the service configuration management apparatus includes: a first instruction listening unit 61, a first instruction parsing unit 62, a configuration management unit 63, a second instruction parsing unit 64, and a first instruction sending unit 65, wherein:
  • the first instruction intercepting unit 61 is configured to: the proxy server starts the daemon, listens to the service management instruction sent by the central server, and the request management instruction sent by the client;
  • the first instruction parsing unit 62 is configured to parse the service management instruction when the daemon process detects the service management instruction sent by the central server actively during the listening process;
  • the configuration management unit 63 is configured to perform configuration management on the service of the client according to the parsed service management instruction.
  • the second instruction parsing unit 64 is configured to parse the service request instruction when the daemon process detects the service request instruction sent by the client actively during the listening process;
  • the first instruction sending unit 65 is configured to send the parsed service request instruction to the central server, so that the central server sends a service management instruction that matches the service request instruction to the proxy server.
  • the configuration management unit 63 includes:
  • a number obtaining module configured to obtain a number of the client in the service management instruction
  • An information finding module configured to search, according to the number of the client, a processing logic of the current configuration file of the client and an address of the client from a pre-established client registration information table;
  • a configuration management module configured to modify, according to the configuration file modification instruction, the processing logic of the client current configuration file, and the address of the client, the current configuration file of the client, so that the client detects Reload the configuration file when the current configuration file is modified.
  • the first instruction sending unit 65 includes:
  • a first instruction parsing module configured to parse a service request instruction sent by the client, and obtain a service name that the client requests to update
  • a first data sending module configured to send, by the client, a service name that is updated by the client to the central server, so that the central server sends, according to the service name that the client requests to update, a message that includes the service name The latest configuration file for the service to the proxy server.
  • the service configuration management apparatus further includes:
  • a second instruction intercepting unit 71 configured to: the daemon process listens to a service feedback instruction sent by the client;
  • the second instruction sending unit 72 is configured to: if the service feedback instruction sent by the client is not monitored within a specified time, send a reload configuration command to the client according to the preset first command line, so that The client reloads the updated configuration file according to the overload configuration directive.
  • the service configuration management apparatus further includes:
  • An information processing unit configured to receive, by the proxy server, status information sent by the client, and send the status information to the central server, so that the central server determines the service of the client according to the status information. a state, and generating a service management instruction for managing the service of the client according to the state of the service of the client.
  • the daemon is started by the proxy server, and the service management instruction sent by the central server and the request management instruction sent by the client are monitored, and the daemon detects the service management instruction sent by the central server actively during the monitoring process.
  • the service management instruction is parsed, and the service of the client is configured and managed according to the parsed service management instruction.
  • the daemon detects the service request instruction sent by the client actively during the listening process, Parsing the service request instruction, and transmitting the parsed service request instruction to the central server, so that the central server sends a service management instruction that matches the service request instruction to the proxy server.
  • the program monitors the instructions of the central server and the instructions of the client through the daemon of the proxy server, manages and maintains the service configuration of the client in time, and responds to the request sent by the client to the central server in time to effectively implement service discovery and reduce The cost of cluster maintenance in a distributed system.
  • FIG. 8 is a schematic diagram of a server according to an embodiment of the present application.
  • the server 8 of this embodiment includes a processor 80, a memory 81, and computer readable instructions 82 stored in the memory 81 and executable on the processor 80, such as a service configuration manager. .
  • the processor 80 executes the computer readable instructions 82, the steps in the foregoing various service configuration management method embodiments are implemented, such as steps 201 to 205 shown in FIG. 2.
  • the processor 80 when executing the computer readable instructions 82, implements the functions of the various modules/units in the various apparatus embodiments described above, such as the functions of the modules 61-65 shown in FIG.
  • the computer readable instructions 82 may be partitioned into one or more modules/units that are stored in the memory 81 and executed by the processor 80, To complete this application.
  • the one or more modules/units may be a series of computer readable instruction instruction segments capable of performing a particular function for describing the execution of the computer readable instructions 82 in the server 8.
  • the server 8 can be a computing device such as a desktop computer, a notebook, a palmtop computer, and a cloud server.
  • the server may include, but is not limited to, a processor 80, a memory 81. It will be understood by those skilled in the art that FIG. 8 is merely an example of the server 8, does not constitute a limitation of the server 8, may include more or less components than those illustrated, or combine some components, or different components, such as
  • the server may also include an input and output device, a network access device, a bus, and the like.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Debugging And Monitoring (AREA)
  • Computer And Data Communications (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本申请提供了一种服务配置管理方法、装置、存储介质和服务器,包括:代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。本申请可有效实现服务发现,降低分布式***中集群维护的成本。

Description

服务配置管理方法、装置、存储介质和服务器
本申请要求于2018年02月07日提交中国专利局、申请号为CN 201810122209.3、发明名称为“服务配置管理方法、***、存储介质和服务器”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及信息监控领域,尤其涉及一种服务配置管理方法、装置、存储介质和服务器。
背景技术
Zookeeper是一个分布式的、开放源码的分布式应用程序协调服务,是Google的Chubby一个开源的实现,是Hadoop和Hbase的重要组件。etcd是一个高可用的键值存储***,主要用于共享配置和服务发现。etcd是一个年轻的项目,是由CoreOS开发并维护的,作为一个受到Zookeeper与doozer启发而催生的项目,正在高速迭代和开发中。目前zookeeper、etcd等分布式协调***均需要应用程序通过驱动包的开发实现服务发现,对于已经不投入开发人力维护的老应用程序来说,接入分布式协调***要实现服务发现较困难,且成本较高。
技术问题
本申请实施例提供了一种服务配置管理方法、装置、存储介质和服务器,以解决现有技术中,对于已经不投入开发人力维护的老应用程序来说,接入分布式协调***要实现服务发现较困难,且成本较高的问题。
技术解决方案
本申请实施例的第一方面提供了一种服务配置管理方法,包括:
代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
本申请实施例的第二方面提供了一种服务配置管理***,所述服务配置管理***包括:代理服务器、中心服务器以及客户端,其中:
所述中心服务器用于发送服务管理指令至所述代理服务器;
所述代理服务器用于启动守护进程,监听所述中心服务器发送的服务管理指令;当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;将解析后的服务管理指令发送至所述客户端;
所述客户端用于接收所述代理服务器发送的所述解析后的服务管理指令,并根据所述解析后的服务管理指令度所述客户端中的服务进行配置管理;
所述客户端还用于主动发送服务请求指令至所述代理服务器;
所述代理服务器还用于当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
本申请实施例的第三方面提供了一种服务器,包括存储器以及处理器,所述存储器存储有可在所述处理器上运行的计算机可读指令,所述处理器执行所述计算机可读指令时实现如下步骤:
代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
本申请实施例的第四方面提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如下步骤:
代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
本申请实施例的第五方面提供了一种服务配置管理装置,包括:
第一指令监听单元,用于代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
第一指令解析单元,用于当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
配置管理单元,用于根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
第二指令解析单元,用于当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
第一指令发送单元,用于将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
有益效果
本申请实施例中,通过代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令,当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令,根据解析后的所述服务管理指令对所述客户端的服务进行配置管理,当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令,将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。本方案通过代理服务器的守护进程同时对中心服务器的指令和客户端的指令进行监控,及时对客户端的服务配置进行管理和维护,及时响应客户端发送至中心服务器的请求,以便有效实现服务发现,降低分布式***中集群维护的成本。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1是本申请实施例提供的服务配置管理***的框架图;
图2是本申请实施例提供的服务配置管理方法的实现流程图;
图3是本申请实施例提供的服务配置管理方法S203的具体实现流程图;
图4是本申请实施例提供的服务配置管理方法S205的具体实现流程图;
图5是本申请另一实施例提供的包括接收客户端发送的状态信息的服务配置管理方法的实现流程图;
图6是本申请实施例提供的服务配置管理装置的结构框图;
图7是本申请另一实施例提供的服务配置管理装置的结构框图;
图8是本申请实施例提供的服务器的示意图。
本发明的实施方式
基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其它实施例,都属于本申请保护的范围。
图1示出了本申请第一实施例提供的一种服务配置管理***的***架构图,详述如下:为了便于说明,仅示出了与本申请实施例相关的部分。
参照图1,所述服务配置管理***包括中心服务器1、代理服务器2以及客户端3,其中:
所述中心服务器1用于发送服务管理指令至所述代理服务器2。其中,所述服务管理指令中包括待管理的客户端3的编号和配置文件指令,所述配置文件指令包括配置文件修改指令、配置文件删除指令或者配置文件添加指令等。具体地,上述中心服务器1的服务管理指令包括服务名称与所述服务名称对应的配置文件的配置参数。
所述代理服务器2用于启动守护进程,监听所述中心服务器1发送的服务管理指令。当监听过程中所述守护进程检测到所述中心服务器1主动发送的服务管理指令时,解析所述服务管理指令。将解析后的服务管理指令发送至所述客户端3。
所述客户端3用于接收所述代理服务器2发送的所述解析后的服务管理指令,并根据所述解析后的服务管理指令度所述客户端3中的服务进行配置管理。
所述客户端3还用于主动发送服务请求指令至所述代理服务器2。其中,所述服务请求指令中包括所述客户端3的编号,还包括所述客户端3请求的服务名称。
所述代理服务器2还用于当监听过程中所述守护进程检测到所述客户端3主动发送的服务请求指令时,解析所述服务请求指令。将解析后的所述服务请求指令发送至所述中心服务器1,以使得所述中心服务器1发送与所述服务请求指令匹配的服务管理指令至所述代理服务器2。
具体地,分布式***环境中包括中心服务器1和客户端3。在本申请实施例中,在所述分布式***环境中安装代理服务器2,通过所述代理服务器2中的守护进程对所述中心服务器1的指令和所述客户端3的指令进行监控。上述守护进程是一个在后台运行并且不受任何终端控制的进程,多个守护进程同时在后台运行,分别执行不同的管理任务。
进一步地,所述客户端3还用于发送反馈指令至上述代理服务器2,其中,所述反馈指令中包括客户端3重新加载配置文件成功的信息,上述代理服务器2将所述反馈指令发送至所述中心服务器1,以使得及时通知所述中心服务器1上述客户端3已重新加载配置的结果。
具体地,所述客户端3包括但不限于台式电脑、手机、笔记本和平板电脑等具有通信能力的客户端3。多个客户端3可通过有线方式或无线方式与代理服务器2连接。
可选地,所述服务配置管理***可以采用蓝牙技术、WIFI 技术或 3G/4G/5G技术等建立代理服务器2与中心服务器1之间的无线连接,也可以采用串口技术或者USB 接口技术等建立代理服务器2与中心服务器1之间的有线连接。
本申请实施例中,服务配置管理***包括代理服务器、中心服务器以及客户端,通过代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令,当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令,根据解析后的所述服务管理指令对所述客户端的服务进行配置管理,当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令,将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。本方案通过代理服务器的守护进程同时对中心服务器的指令和客户端的指令进行监控,及时对客户端的服务配置进行管理和维护,及时响应客户端发送至中心服务器的请求,以便有效实现服务发现,降低分布式***中集群维护的成本。
图2示出了本申请实施例提供的服务配置管理方法的实现流程,在本实施例中,该流程的执行主体为图1所示的代理服务器2,该方法流程包括步骤S201至S205。各步骤的具体实现原理如下:
S201:代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令。
具体地,在分布式***环境中,通过所述代理服务器中的守护进程对所述中心服务器的指令和所述客户端的指令进行监控。所述守护进程是一个在后台运行并且不受任何终端控制的进程。在分布式***环境中,存在不止一个客户端,因此,所述代理服务器中可建立多个守护进程同时在后台运行,多个守护进程分别执行不同的管理任务,从而可提高服务发现的效率。在本申请实施例中,所述服务管理指令中包括待管理的客户端的编号和配置文件指令,所述配置文件指令包括配置文件修改指令、配置文件删除指令或者配置文件添加指令等。所述服务请求指令中包括待管理的客户端的编号,还包括所述客户端请求的服务名称。
S202:当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令。
S203:根据解析后的所述服务管理指令对所述客户端的服务进行配置管理。
作为本申请的一个实施例,如图3所示,当所述服务管理指令中包括配置文件修改指令时,上述S203具体包括:
A1:获取所述服务管理指令中客户端的编号。具体地,获取所述服务管理指令中所述代理服务器待管理的客户端的编号。所述客户端的编号用于标识分布式***中的客户端,分布式***中的客户端分别具有且仅具有一个对应的编号,所述编号具有唯一性。
A2:根据所述客户端的编号,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址。具体地,上述客户端注册信息表中记录的是客户端注册加入分布式***时的信息,包括客户端的编号、地址以及所述客户端当前配置文件的处理逻辑。
A3:根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改,以使得在所述客户端检测到所述当前配置文件被修改时,重新加载配置文件。其中,处理逻辑通过函数体现。所述处理逻辑为对配置文件进行管理时所调用的函数。
在本申请实施例中,创建分布式***环境时,需要代理服务器的守护进程监听的客户端,预先在代理服务器上进行注册,注册信息包括客户端的编号、地址以及处理逻辑(即处理函数),代理服务器根据需监听的注册客户端发送的注册信息建立客户端注册信息表,所述客户端注册信息表中包括客户端的编号、地址以及客户端的配置文件的处理逻辑。当所述服务管理指令中包配置文件修改指令时,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址,根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改。所述客户端检测到所述当前配置文件被修改时,重新加载配置文件,从而及时对客户端的服务配置管理,实现服务发现。
进一步地,所述客户端实时对服务的配置文件进行检测,判断所述服务的配置文件是否更新。可选地,所述客户端按周期对服务的配置文件进行检测。当检测当前配置文件与前一周期检测时的配置文件不一样时,重新加载配置文件,从而自动更新所述客户端的服务。
可选地,作为本申请的一个实施例,在所述步骤S203之后还包括:
S2031:所述守护进程监听所述客户端发送的服务反馈指令。在本申请实施例中,当代理服务器根据解析后的所述服务管理指令对所述客户端的服务进行配置管理之后,所述客户端的服务更新,此时,所述客户端发送服务反馈指令至所述代理服务器,通知所述代理服务器此次服务的配置管理成功。
S2032:若在指定的时间内未监听到所述客户端发送的服务反馈指令,则根据预设的第一命令行,发送重载配置指令至客户端,以使得客户端根据所述重载配置指令重新载入更新的配置文件。具体地,当指定的时间内未监听到所述客户端发送的服务反馈指令时,判定所述客户端加载更新的配置文件出现故障。
进一步地,若发送所述重载配置的指令至同一客户端的次数超过预设次数,则根据预设的第二命令行,发送服务重启指令至所述客户端,以使得客户端根据所述服务重启指令重启服务,从而重新载入更新的配置文件。
S204:当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令。
在本申请实施例中,守护进程还同时监听客户端主动发送的服务请求指令。所述服务请求指令中包括所述客户端的编号以及所述客户端请求的服务名称。
S205:将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
作为本申请的一个实施例,图4示出了本申请实施例提供的服务配置管理方法S205的具体实现流程,详述如下:
B1:解析所述客户端主动发送的服务请求指令,获取所述客户端请求更新的服务名称。
B2:将所述客户端请求更新的服务名称发送至所述中心服务器,以使得所述中心服务器根据所述客户端请求更新的服务名称,发送包括所述服务名称对应的服务的最新配置文件至所述代理服务器。
在本申请实施例中,所述代理服务器解析所述服务请求指令,将解析后服务请求指令中的所述客户端的编号以及服务名称等发送至所述中心服务器,所述中心服务器接收到所述客户端的编号以及服务名称之后,根据所述服务名称查找所述服务名称最新的配置文件,并发送至所述代理服务器。
进一步地,所述中心服务器根据所述客户端的编号查找所述客户端的当前配置文件,根据所述服务名称查找所述服务名称对应的最新的配置文件,将查找到的当前配置文件与最新的配置文件进行比较,根据比较结果生成配置文件修改指令,根据所述服务请求指令中的所述客户端的编号以及生成的配置文件修改指令,生成服务管理指令,并将所述服务管理指令发送至所述代理服务器,以使得所述代理服务器根据生成的服务管理指令对所述客户端的服务进行配置管理。
本方案通过代理服务器的守护进程同时对中心服务器的指令和客户端的指令进行监控,及时对客户端的服务配置进行管理和维护,及时响应客户端发送至中心服务器的请求,以便有效实现服务发现,降低分布式***中集群维护的成本。
进一步地,基于上述图2实施例中所提供的服务配置管理方法,提出本申请的另一实施例。在本申请实施例中,图5示出了本申请实施例提供的一种包括接收客户端发送的状态信息的服务配置管理方法,详述如下:
S501:代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令。
S502:当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令。
S503:根据解析后的所述服务管理指令对所述客户端的服务进行配置管理。
S504:当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令。
S505:将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
本实施例中,步骤S501至步骤S505的具体步骤参见上述实施例步骤S201至步骤S205,在此不再赘述。
S506:所述代理服务器接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令。
具体地,上述客户端发送的状态信息包括当前可用的服务名称,还包括客户端进程的运行状态等。在本申请实施例中,守护进程将客户端的状态信息反馈至中心服务器,中心服务器可根据客户端的状态信息判断客户端服务的可用性状态,根据所述客户端服务的可用性状态,生成与所述客户端服务的可用性状态相应的服务管理指令,所述服务管理指令用于针对所述客户端服务的可用性状态进行管理,即对于客户端服务的不同状态,中心服务器生成不同的服务管理指令。其中,客户端的可用性状态包括但不限于服务正常运行、服务故障、服务版本过低。进一步地,所述代理服务器接收所述客户端周期发送的状态信息。具体地,所述客户端可周期性的发送服务的状态信息至守护进程。
本申请实施例中,通过代理服务器的守护进程同时对中心服务器的指令和客户端的指令进行监控,及时对客户端的服务配置进行管理和维护,及时响应客户端发送至中心服务器的请求,以便有效实现服务发现,降低分布式***中集群维护的成本,进一步地,代理服务器通过接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令,从而及时掌握客户端中服务的状态,生成相应的服务管理指令以使得对所述客户端的服务进行有效配置管理。
对应于上文实施例所述的服务配置管理方法,图6示出了本申请实施例提供的服务配置管理装置的结构框图,为了便于说明,仅示出了与本申请实施例相关的部分。
参照图6,该服务配置管理装置包括:第一指令监听单元61,第一指令解析单元62,配置管理单元63,第二指令解析单元64,第一指令发送单元65,其中:
第一指令监听单元61,用于代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
第一指令解析单元62,用于当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
配置管理单元63,用于根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
第二指令解析单元64,用于当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
第一指令发送单元65,用于将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
可选地,所述服务管理指令中包括配置文件修改指令时,所述配置管理单元63包括:
编号获取模块,用于获取所述服务管理指令中客户端的编号;
信息查找模块,用于根据所述客户端的编号,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址;
配置管理模块,用于根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改,以使得在所述客户端检测到所述当前配置文件被修改时,重新加载配置文件。
可选地,当所述服务请求指令中包括更新服务时,所述第一指令发送单元65包括:
第一指令解析模块,用于解析所述客户端主动发送的服务请求指令,获取所述客户端请求更新的服务名称;
第一数据发送模块,用于将所述客户端请求更新的服务名称发送至所述中心服务器,以使得所述中心服务器根据所述客户端请求更新的服务名称,发送包括所述服务名称对应的服务的最新配置文件至所述代理服务器。
可选地,如图7所示,可选地,所述服务配置管理装置还包括:
第二指令监听单元71,用于所述守护进程监听所述客户端发送的服务反馈指令;
第二指令发送单元72,用于若在指定的时间内未监听到所述客户端发送的服务反馈指令,则根据预设的第一命令行,发送重载配置的指令至客户端,以使得客户端根据重载配置指令重新载入更新的配置文件。
可选地,所述服务配置管理装置还包括:
信息处理单元,用于所述代理服务器接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令。
本申请实施例中,通过代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令,当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令,根据解析后的所述服务管理指令对所述客户端的服务进行配置管理,当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令,将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。本方案通过代理服务器的守护进程同时对中心服务器的指令和客户端的指令进行监控,及时对客户端的服务配置进行管理和维护,及时响应客户端发送至中心服务器的请求,以便有效实现服务发现,降低分布式***中集群维护的成本。
图8是本申请一实施例提供的服务器的示意图。如图8所示,该实施例的服务器8包括:处理器80、存储器81以及存储在所述存储器81中并可在所述处理器80上运行的计算机可读指令82,例如服务配置管理程序。所述处理器80执行所述计算机可读指令82时实现上述各个服务配置管理方法实施例中的步骤,例如图2所示的步骤201至205。或者,所述处理器80执行所述计算机可读指令82时实现上述各装置实施例中各模块/单元的功能,例如图6所示模块61至65的功能。
示例性的,所述计算机可读指令82可以被分割成一个或多个模块/单元,所述一个或者多个模块/单元被存储在所述存储器81中,并由所述处理器80执行,以完成本申请。所述一个或多个模块/单元可以是能够完成特定功能的一系列计算机可读指令指令段,该指令段用于描述所述计算机可读指令82在所述服务器8中的执行过程。
所述服务器8可以是桌上型计算机、笔记本、掌上电脑及云端服务器等计算设备。所述服务器可包括,但不仅限于,处理器80、存储器81。本领域技术人员可以理解,图8仅仅是服务器8的示例,并不构成对服务器8的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述服务器还可以包括输入输出设备、网络接入设备、总线等。

Claims (20)

  1. 一种服务配置管理方法,其特征在于,包括:
    代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
    当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
    根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
    当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
    将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
  2. 根据权利要求1所述的方法,其特征在于,当所述服务管理指令中包括配置文件修改指令时,所述根据解析后的所述服务管理指令对所述客户端的服务进行配置管理的步骤,包括:
    获取所述服务管理指令中客户端的编号;
    根据所述客户端的编号,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址;
    根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改,以使得在所述客户端检测到所述当前配置文件被修改时,重新加载配置文件。
  3. 根据权利要求1所述的方法,其特征在于,当所述服务请求指令中包括更新服务时,所述将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器的步骤,包括:
    解析所述客户端主动发送的服务请求指令,获取所述客户端请求更新的服务名称;
    将所述客户端请求更新的服务名称发送至所述中心服务器,以使得所述中心服务器根据所述客户端请求更新的服务名称,发送包括所述服务名称对应的服务的最新配置文件至所述代理服务器。
  4. 根据权利要求1至3任一项所述的方法,其特征在于,在所述根据解析后的所述服务管理指令对所述客户端的服务进行配置管理的步骤之后,还包括:
    所述守护进程监听所述客户端发送的服务反馈指令;
    若在指定的时间内未监听到所述客户端发送的服务反馈指令,则根据预设的第一命令行,发送重载配置的指令至客户端,以使得客户端根据重载配置指令重新载入更新的配置文件。
  5. 根据权利要求1至3任一项所述的方法,其特征在于,所述服务配置管理方法还包括:
    所述代理服务器接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令。
  6. 一种服务配置管理装置,其特征在于,包括:
    第一指令监听单元,用于代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
    第一指令解析单元,用于当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
    配置管理单元,用于根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
    第二指令解析单元,用于当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
    第一指令发送单元,用于将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
  7. 根据权利要求6所述的装置,其特征在于,所述配置管理单元包括:
    编号获取模块,用于获取所述服务管理指令中客户端的编号;
    信息查找模块,用于根据所述客户端的编号,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址;
    配置管理模块,用于根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改,以使得在所述客户端检测到所述当前配置文件被修改时,重新加载配置文件。
  8. 根据权利要求6所述的装置,其特征在于,所述第一指令发送单元包括:
    第一指令解析模块,用于解析所述客户端主动发送的服务请求指令,获取所述客户端请求更新的服务名称;
    第一数据发送模块,用于将所述客户端请求更新的服务名称发送至所述中心服务器,以使得所述中心服务器根据所述客户端请求更新的服务名称,发送包括所述服务名称对应的服务的最新配置文件至所述代理服务器。
  9. 根据权利要求6至8任一项所述的装置,其特征在于,所述服务配置管理装置还包括:
    第二指令监听单元,用于所述守护进程监听所述客户端发送的服务反馈指令;
    第二指令发送单元,用于若在指定的时间内未监听到所述客户端发送的服务反馈指令,则根据预设的第一命令行,发送重载配置的指令至客户端,以使得客户端根据重载配置指令重新载入更新的配置文件。
  10. 根据权利要求6至9任一项所述的装置,其特征在于,所述服务配置管理装置还包括:
    信息处理单元,用于所述代理服务器接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令。
  11. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机可读指令,其特征在于,所述计算机可读指令被处理器执行时实现如下步骤:
    代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
    当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
    根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
    当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
    将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
  12. 根据权利要求11所述的计算机可读存储介质,其特征在于,当所述服务管理指令中包括配置文件修改指令时,所述根据解析后的所述服务管理指令对所述客户端的服务进行配置管理的步骤,包括:
    获取所述服务管理指令中客户端的编号;
    根据所述客户端的编号,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址;
    根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改,以使得在所述客户端检测到所述当前配置文件被修改时,重新加载配置文件。
  13. 根据权利要求11所述的计算机可读存储介质,其特征在于,当所述服务请求指令中包括更新服务时,所述将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器的步骤,包括:
    解析所述客户端主动发送的服务请求指令,获取所述客户端请求更新的服务名称;
    将所述客户端请求更新的服务名称发送至所述中心服务器,以使得所述中心服务器根据所述客户端请求更新的服务名称,发送包括所述服务名称对应的服务的最新配置文件至所述代理服务器。
  14. 根据权利要求11至13任一项所述的计算机可读存储介质,其特征在于,在所述根据解析后的所述服务管理指令对所述客户端的服务进行配置管理的步骤之后,还包括:
    所述守护进程监听所述客户端发送的服务反馈指令;
    若在指定的时间内未监听到所述客户端发送的服务反馈指令,则根据预设的第一命令行,发送重载配置的指令至客户端,以使得客户端根据重载配置指令重新载入更新的配置文件。
  15. 根据权利要求11至13任一项所述的计算机可读存储介质,其特征在于,所述处理器执行所述计算机可读指令时还实现如下步骤:
    所述代理服务器接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令。
  16. 一种服务器,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,其特征在于,所述处理器执行所述计算机可读指令时实现如下步骤:
    代理服务器启动守护进程,监听中心服务器发送的服务管理指令以及客户端发送的请求管理指令;
    当监听过程中所述守护进程检测到所述中心服务器主动发送的服务管理指令时,解析所述服务管理指令;
    根据解析后的所述服务管理指令对所述客户端的服务进行配置管理;
    当监听过程中所述守护进程检测到所述客户端主动发送的服务请求指令时,解析所述服务请求指令;
    将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器。
  17. 根据权利要求16所述的服务器,其特征在于,当所述服务管理指令中包括配置文件修改指令时,所述根据解析后的所述服务管理指令对所述客户端的服务进行配置管理的步骤,包括:
    获取所述服务管理指令中客户端的编号;
    根据所述客户端的编号,从预先建立的客户端注册信息表中查找所述客户端当前配置文件的处理逻辑以及所述客户端的地址;
    根据所述配置文件修改指令、所述客户端当前配置文件的处理逻辑以及所述客户端的地址,对所述客户端的当前配置文件进行修改,以使得在所述客户端检测到所述当前配置文件被修改时,重新加载配置文件。
  18. 根据权利要求16所述的服务器,其特征在于,当所述服务请求指令中包括更新服务时,所述将解析后的所述服务请求指令发送至所述中心服务器,以使得所述中心服务器发送与所述服务请求指令匹配的服务管理指令至所述代理服务器的步骤,包括:
    解析所述客户端主动发送的服务请求指令,获取所述客户端请求更新的服务名称;
    将所述客户端请求更新的服务名称发送至所述中心服务器,以使得所述中心服务器根据所述客户端请求更新的服务名称,发送包括所述服务名称对应的服务的最新配置文件至所述代理服务器。
  19. 根据权利要求16至18任一项所述的服务器,其特征在于,在所述根据解析后的所述服务管理指令对所述客户端的服务进行配置管理的步骤之后,所述处理器执行所述计算机可读指令时还实现如下步骤:
    所述守护进程监听所述客户端发送的服务反馈指令;
    若在指定的时间内未监听到所述客户端发送的服务反馈指令,则根据预设的第一命令行,发送重载配置的指令至客户端,以使得客户端根据重载配置指令重新载入更新的配置文件。
  20. 根据权利要求16至18任一项所述的服务器,其特征在于,所述处理器执行所述计算机可读指令时还实现如下步骤:
    所述代理服务器接收所述客户端发送的状态信息,并将所述状态信息发送至所述中心服务器,以使得所述中心服务器根据所述状态信息判断所述客户端的服务的状态,并根据所述客户端的服务的状态生成用于对所述客户端的服务进行管理的服务管理指令。
PCT/CN2018/082836 2018-02-07 2018-04-12 服务配置管理方法、装置、存储介质和服务器 WO2019153488A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810122209.3 2018-02-07
CN201810122209.3A CN108566290B (zh) 2018-02-07 2018-02-07 服务配置管理方法、***、存储介质和服务器

Publications (1)

Publication Number Publication Date
WO2019153488A1 true WO2019153488A1 (zh) 2019-08-15

Family

ID=63531211

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/082836 WO2019153488A1 (zh) 2018-02-07 2018-04-12 服务配置管理方法、装置、存储介质和服务器

Country Status (2)

Country Link
CN (1) CN108566290B (zh)
WO (1) WO2019153488A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113590331A (zh) * 2021-08-05 2021-11-02 山东派盟网络科技有限公司 一种任务处理方法、控制装置及存储介质

Families Citing this family (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109462646B (zh) * 2018-11-12 2021-11-19 平安科技(深圳)有限公司 一种异常响应的方法及设备
CN109445927B (zh) * 2018-11-12 2021-09-17 郑州云海信息技术有限公司 一种存储集群的任务管理方法及装置
CN109543133A (zh) * 2018-11-29 2019-03-29 杭州涂鸦信息技术有限公司 一种自动化发布方法、装置、***、设备及可读存储介质
CN110474983A (zh) * 2019-08-15 2019-11-19 上海易点时空网络有限公司 基于代理服务的云配置方法及***
CN110572277A (zh) * 2019-08-15 2019-12-13 上海易点时空网络有限公司 机器管理方法及***
CN110519088A (zh) * 2019-08-15 2019-11-29 上海易点时空网络有限公司 配置服务容灾方法及***
CN110572442A (zh) * 2019-08-15 2019-12-13 上海易点时空网络有限公司 配置文件路径的方法及***
CN110569085A (zh) * 2019-08-15 2019-12-13 上海易点时空网络有限公司 配置文件加载方法及***
CN110543335A (zh) * 2019-08-15 2019-12-06 上海易点时空网络有限公司 应用程序配置管理方法及***
CN110535695A (zh) * 2019-08-15 2019-12-03 上海易点时空网络有限公司 配置信息勘误方法及***
CN111193717A (zh) * 2019-12-06 2020-05-22 上海上讯信息技术股份有限公司 Ftp黑白名单控制方法、装置及电子设备
CN111736874A (zh) * 2020-06-28 2020-10-02 深圳前海微众银行股份有限公司 一种应用更新方法及装置
CN112507267B (zh) * 2020-12-03 2023-01-20 上海哔哩哔哩科技有限公司 用户偏好设置同步方法、***、设备及可读存储介质
CN114301777A (zh) * 2021-12-29 2022-04-08 山石网科通信技术股份有限公司 配置数据更新方法、装置、***及非易失性存储介质
CN114328130B (zh) * 2022-03-03 2022-08-12 深圳市明源云科技有限公司 服务器监控方法、***、设备及计算机可读存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050015429A1 (en) * 2003-07-17 2005-01-20 International Business Machines Corporation Method and system for providing user control over receipt of cookies from e-commerce applications
CN103023857A (zh) * 2011-09-20 2013-04-03 腾讯科技(深圳)有限公司 一种信息资源远程部署的方法及***
US20130311593A1 (en) * 2012-05-17 2013-11-21 Matthew Browning Prince Incorporating web applications into web pages at the network level
CN106302596A (zh) * 2015-06-03 2017-01-04 北京京东尚科信息技术有限公司 一种服务发现的方法和装置

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102123056B (zh) * 2010-11-29 2013-07-24 东北大学 端到端Web服务质量监测方法
CN103812900A (zh) * 2012-11-13 2014-05-21 ***通信集团公司 一种数据同步方法、装置及***
EP2897326A1 (en) * 2014-01-21 2015-07-22 Thomson Licensing System comprising an access gateway and a wide-area-network modem device, and respective access gateway and wide-area-network modem device
US9960977B2 (en) * 2015-03-02 2018-05-01 Facebook, Inc. Techniques to identify application foreground / background state based on network traffic

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050015429A1 (en) * 2003-07-17 2005-01-20 International Business Machines Corporation Method and system for providing user control over receipt of cookies from e-commerce applications
CN103023857A (zh) * 2011-09-20 2013-04-03 腾讯科技(深圳)有限公司 一种信息资源远程部署的方法及***
US20130311593A1 (en) * 2012-05-17 2013-11-21 Matthew Browning Prince Incorporating web applications into web pages at the network level
CN106302596A (zh) * 2015-06-03 2017-01-04 北京京东尚科信息技术有限公司 一种服务发现的方法和装置

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113590331A (zh) * 2021-08-05 2021-11-02 山东派盟网络科技有限公司 一种任务处理方法、控制装置及存储介质

Also Published As

Publication number Publication date
CN108566290B (zh) 2020-05-08
CN108566290A (zh) 2018-09-21

Similar Documents

Publication Publication Date Title
WO2019153488A1 (zh) 服务配置管理方法、装置、存储介质和服务器
CN108737270B (zh) 一种服务器集群的资源管理方法和装置
CN107590001B (zh) 负载均衡方法及装置、存储介质、电子设备
WO2019061720A1 (zh) 一种数据同步的方法和***
WO2017041398A1 (zh) 数据传输方法和装置
WO2018040722A1 (zh) 表数据查询方法及装置
US9367261B2 (en) Computer system, data management method and data management program
WO2019007010A1 (zh) 分布式搜索及索引更新方法、***、服务器及计算机设备
CN111258627A (zh) 一种接口文档生成方法和装置
TW201246103A (en) Category information transmission method, system and apparatus
US9104488B2 (en) Support server for redirecting task results to a wake-up server
US20230275976A1 (en) Data processing method and apparatus, and computer-readable storage medium
CN112751847A (zh) 接口调用请求的处理方法、装置、电子设备及存储介质
US20160026663A1 (en) Distributing and processing streams over one or more networks for on-the-fly schema evolution
WO2024016624A1 (zh) 多集群访问方法和***
CN112463290A (zh) 动态调整计算容器的数量的方法、***、装置和存储介质
CN111352716A (zh) 一种基于大数据的任务请求方法、装置、***及存储介质
US8793710B2 (en) Distributed multi-system management
US8832255B2 (en) Using status inquiry and status response messages to exchange management information
WO2024037629A1 (zh) 区块链的数据整合方法、装置、计算机设备及存储介质
WO2018188607A1 (zh) 流处理方法及装置
WO2024045646A1 (zh) 管理集群访问权限的方法、装置和***
WO2019062156A1 (zh) 存储过程的执行方法、装置及存储介质
CN111831503B (zh) 一种基于监控代理的监控方法和监控代理装置
US20190324817A1 (en) Method, apparatus, and computer program product for optimization in distributed system

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18905107

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 03.11.2020)

122 Ep: pct application non-entry in european phase

Ref document number: 18905107

Country of ref document: EP

Kind code of ref document: A1