Search

CN-121984855-A - Multi-cluster service parameter updating method, device, equipment and storage medium

CN121984855ACN 121984855 ACN121984855 ACN 121984855ACN-121984855-A

Abstract

The application relates to a service parameter updating method, device, equipment and storage medium of a plurality of clusters. The method comprises the steps of obtaining cache configuration information of target services from a cache area of an area cluster, generating a configuration parameter obtaining request of the target services based on the cache configuration information, obtaining updated configuration parameters corresponding to the target services from an area database of the area cluster based on the configuration parameter obtaining request, generating and synchronizing the updated configuration parameters to the area database of each area cluster corresponding to the main cluster and deploying the target services by a main cluster corresponding to the area cluster, carrying out parameter updating on the target services in the area cluster based on the updated configuration parameters, and updating the configuration parameters to be used for target tasks of the target services in the area cluster. The method can improve the updating efficiency of the multi-cluster service parameters.

Inventors

  • LI GUOBIN

Assignees

  • 金蝶软件(中国)有限公司

Dates

Publication Date
20260505
Application Date
20260228

Claims (11)

  1. 1. A method for updating service parameters of a plurality of clusters, the method comprising: Obtaining cache configuration information of a target service from a cache area of an area cluster; generating a configuration parameter acquisition request of the target service based on the cache configuration information; Based on the configuration parameter acquisition request, acquiring an update configuration parameter corresponding to the target service from a regional database of the regional cluster, wherein the update configuration parameter is generated by a main cluster corresponding to the regional cluster and is synchronized to the regional database of each regional cluster corresponding to the main cluster for deploying the target service; and updating parameters of the target services in the regional cluster based on the updated configuration parameters, wherein the updated configuration parameters are used for executing target tasks of the target services by the target services in the regional cluster.
  2. 2. The method of claim 1, wherein generating a configuration parameter acquisition request for the target service based on the cache configuration information comprises: And generating a configuration parameter acquisition request of the target service based on the target service identifier of the target service under the condition that the cache configuration parameters of the target service do not exist in the cache configuration information.
  3. 3. The method of claim 1, wherein generating a configuration parameter acquisition request for the target service based on the cache configuration information comprises: Under the condition that the cache configuration information comprises the cache configuration parameters of the target service and the cache time corresponding to the cache configuration parameters, determining the cache time based on the cache time; comparing the buffer time length with a time length threshold; And generating a configuration parameter acquisition request of the target service based on the target service identifier of the target service under the condition that the caching time length is larger than the time length threshold.
  4. 4. The method according to claim 1, wherein the obtaining, based on the configuration parameter obtaining request, the updated configuration parameter corresponding to the target service from the regional database of the regional cluster includes: based on the target service identifier in the configuration parameter acquisition request, acquiring a synchronous configuration parameter corresponding to the target service identifier and a synchronous parameter version identifier corresponding to the synchronous configuration parameter from a regional database of the regional cluster; comparing the buffer parameter version identifier with the synchronous parameter version identifier under the condition that the configuration parameter acquisition request comprises the buffer parameter version identifier corresponding to the buffer configuration parameter of the target service; And under the condition that the synchronous parameter version identifier is different from the cache parameter version identifier, determining the synchronous configuration parameter corresponding to the target service identifier as the updated configuration parameter corresponding to the target service.
  5. 5. The method of claim 4, wherein after said comparing said cached parameter version identification to said synchronization parameter version identification, said method further comprises: and under the condition that the synchronous parameter version identifier is the same as the cache parameter version identifier, updating the cache moment corresponding to the cache configuration parameter of the target service in the cache region of the region cluster to the current moment.
  6. 6. The method according to claim 4, wherein after the obtaining, based on the target service identifier in the configuration parameter obtaining request, the synchronization configuration parameter corresponding to the target service identifier and the synchronization parameter version identifier corresponding to the synchronization configuration parameter from the regional database of the regional cluster, the method further comprises: And under the condition that the configuration parameter acquisition request does not comprise the buffer parameter version identifier corresponding to the buffer configuration parameter of the target service, determining the synchronous configuration parameter corresponding to the target service identifier as the update configuration parameter corresponding to the target service.
  7. 7. The method of claim 1, wherein after the parameter updating of the target service in the regional cluster based on the updated configuration parameters, the method further comprises: based on the updated configuration parameters, executing a target task of the target service through the target service to obtain task execution information of the target task; The task execution information comprises a target task identifier and a target object identifier, wherein the target object identifier is used for determining a target cluster identifier corresponding to the target object identifier based on a corresponding relation between the object identifier and an area cluster identifier, calling a target cluster corresponding to the target cluster identifier, and processing an operation to be executed for the target task identifier, which is acquired through the target cluster.
  8. 8. A service parameter updating apparatus for a plurality of clusters, the apparatus being applied to a public network, comprising: The acquisition module is used for acquiring the cache configuration information of the target service from the cache area of the area cluster; The generation module is used for generating a configuration parameter acquisition request of the target service based on the cache configuration information; the request module is used for acquiring the updated configuration parameters corresponding to the target service from the regional database of the regional cluster based on the configuration parameter acquisition request, wherein the updated configuration parameters are generated by a main cluster corresponding to the regional cluster and are synchronized to the regional database of each regional cluster corresponding to the main cluster for deploying the target service; The updating module is used for updating parameters of the target service in the regional cluster based on the updating configuration parameters; the updated configuration parameters are used for the target service in the regional cluster to execute the target task of the target service.
  9. 9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 7 when the computer program is executed.
  10. 10. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 7.
  11. 11. A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 7.

Description

Multi-cluster service parameter updating method, device, equipment and storage medium Technical Field The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, a computer device, a storage medium, and a computer program product for updating service parameters of multiple clusters. Background With the development of computer technology, an enterprise business system gradually evolves from a single architecture to a multi-cluster distributed deployment mode, and the multi-cluster technology is widely used for improving the availability, expansibility and disaster recovery capability of the system, so that the same type of business service can be deployed in different regions, different cloud environments or different resource pools for parallel operation respectively, and cross-region access, load sharing and high-availability requirements are met. In the conventional technology, each service cluster is usually managed as an independent operation unit, each cluster maintains configuration parameters and task data of its own service, and the configuration parameters are usually configured and modified by operation and maintenance personnel or research personnel logging into a management system of each cluster, so that the service parameter update efficiency of multiple clusters is low. Disclosure of Invention In view of the foregoing, it is desirable to provide a multi-cluster service parameter updating method, apparatus, computer device, computer readable storage medium, and computer program product that can improve the efficiency of multi-cluster service parameter updating. In a first aspect, the present application provides a method for updating service parameters of multiple clusters. The method comprises the following steps: Obtaining cache configuration information of a target service from a cache area of an area cluster; generating a configuration parameter acquisition request of the target service based on the cache configuration information; Based on the configuration parameter acquisition request, acquiring an update configuration parameter corresponding to the target service from a regional database of the regional cluster, wherein the update configuration parameter is generated by a main cluster corresponding to the regional cluster and is synchronized to the regional database of each regional cluster corresponding to the main cluster for deploying the target service; and updating parameters of the target services in the regional cluster based on the updated configuration parameters, wherein the updated configuration parameters are used for executing target tasks of the target services by the target services in the regional cluster. In a second aspect, the application further provides a service parameter updating device for the multiple clusters. The device comprises: The acquisition module is used for acquiring the cache configuration information of the target service from the cache area of the area cluster; The generation module is used for generating a configuration parameter acquisition request of the target service based on the cache configuration information; the request module is used for acquiring the updated configuration parameters corresponding to the target service from the regional database of the regional cluster based on the configuration parameter acquisition request, wherein the updated configuration parameters are generated by a main cluster corresponding to the regional cluster and are synchronized to the regional database of each regional cluster corresponding to the main cluster for deploying the target service; The updating module is used for updating parameters of the target service in the regional cluster based on the updating configuration parameters; the updated configuration parameters are used for the target service in the regional cluster to execute the target task of the target service. In a third aspect, the present application also provides a computer device comprising a memory storing a computer program and a processor implementing the steps of the method of any one of the first aspects when the computer program is executed by the processor. In a fourth aspect, the present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the method of any of the first aspects. In a fifth aspect, the application also provides a computer program product comprising a computer program which, when executed by a processor, implements the steps of the method of any of the first aspects. The service parameter updating method, device, computer equipment, storage medium and computer program product for the multiple clusters acquire cache configuration information of target services from cache areas of the area clusters, generate a configuration parameter acquiring request of the target services based on the cache configura