CN114610530A - Disaster tolerance switching method and device for business system, electronic equipment and storage medium - Google Patents

Disaster tolerance switching method and device for business system, electronic equipment and storage medium Download PDF

Info

Publication number
CN114610530A
CN114610530A CN202111656700.2A CN202111656700A CN114610530A CN 114610530 A CN114610530 A CN 114610530A CN 202111656700 A CN202111656700 A CN 202111656700A CN 114610530 A CN114610530 A CN 114610530A
Authority
CN
China
Prior art keywords
disaster tolerance
disaster
workflow
switching
execution
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202111656700.2A
Other languages
Chinese (zh)
Inventor
王晓君
张海英
彭迈
詹竣尹
张好涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Asiainfo Technology Nanjing Co ltd
Original Assignee
Asiainfo Technology Nanjing Co ltd
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 Asiainfo Technology Nanjing Co ltd filed Critical Asiainfo Technology Nanjing Co ltd
Priority to CN202111656700.2A priority Critical patent/CN114610530A/en
Publication of CN114610530A publication Critical patent/CN114610530A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1415Saving, restoring, recovering or retrying at system level

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the application provides a disaster recovery switching method and device of a business system, electronic equipment and a storage medium, and relates to the technical field of disaster recovery switching. The method comprises the following steps: responding to the triggering of disaster tolerance switching of a service system, and determining a target disaster tolerance switching scene; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster tolerance flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.

Description

Disaster tolerance switching method and device for business system, electronic equipment and storage medium
Technical Field
The present application relates to the field of disaster recovery switching technologies, and in particular, to a method and an apparatus for disaster recovery switching of a service system, an electronic device, and a storage medium.
Background
When an information system of a production environment fails, a service needs to be switched from the production environment to a disaster-tolerant environment, so that the system can normally operate, namely, disaster-tolerant switching is performed. The main operation contents of disaster recovery switching comprise: the method comprises a series of operation steps of invalidation and restarting of timing tasks, call ticket cleaning inspection, starting and stopping and switching of a roaming uploading process, transaction consistency inspection and starting and stopping of a memory database, database switching, high-performance cache refreshing, ZooKeeper cluster configuration expansion capacity, error list recovery and the like. The switching modes comprise main capacity forward switching, reverse back switching, customized step switching and the like, and the operation contents and the sequence executed by different switching modes are different, so that the method can be applied to different disaster recovery switching scenes.
In the current disaster recovery switching process, the operation steps are executed mainly by means of manual scripts, the number of service processes needing to be started and stopped is large, switching requirements are diversified, the problems of complex configuration operation, large maintenance workload and the like exist, after one switching step is completed, the execution result of the step needs to be confirmed manually, the next step is executed, the operation steps have the modes of parallel, serial, abnormal retry and the like, and due to the fact that the disaster recovery switching time is short, the current operation method consumes much manpower, the switching efficiency requirement cannot be well met, and the switching operation is prone to errors and switching failure, so that charging service processing abnormity is influenced.
Disclosure of Invention
The embodiment of the application provides a disaster recovery switching method and device of a service system, an electronic device, a computer readable storage medium and a computer program product, which are used for solving the technical problem of complex disaster recovery switching in the prior art.
According to an aspect of an embodiment of the present application, a method for disaster recovery switching of a service system is provided, where the method includes:
responding to the triggering of disaster tolerance switching of a service system, and determining a target disaster tolerance switching scene;
determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library;
starting a target business disaster tolerance flow;
the process library comprises a plurality of service disaster tolerance processes which are configured in advance, each service disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the service disaster tolerance processes are used for executing workflows which are configured in advance and switched in a disaster tolerance mode.
In one possible implementation manner, in response to triggering the disaster recovery handover by the service system, the method further includes:
configuring corresponding workflow for each disaster tolerance scene;
and configuring corresponding executable codes, execution categories and execution state information for each step in the workflow, and specifying execution sequence information among the steps to generate a business disaster tolerance flow corresponding to the workflow.
In one possible implementation, the starting of the target service disaster recovery process includes:
determining a current step performed in the workflow;
judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step;
if the executable code is determined to be executed, a next step is determined from the workflow after the executable code is executed.
In one possible implementation, the execution state information includes information indicating whether the corresponding step was abnormally retried, breakpoint suspended, or skipped;
judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step, wherein the judging comprises the following steps:
if the execution state information is used for indicating the abnormal retry of the corresponding step, executing the corresponding executable code, and if the execution is abnormal, re-executing the corresponding executable code according to the abnormal times;
if the execution state information is used for indicating that the corresponding step is breakpoint pause, pausing to execute the corresponding executable code;
and if the execution state information is used for indicating that the corresponding step is skipped, skipping to execute the corresponding executable code and determining the next step from the workflow.
In a possible implementation manner, generating a service disaster tolerance flow corresponding to a workflow further includes:
defining and implementing executable code execution logic, defining identification information of each execution state of the executable code.
In one possible implementation, determining the next step from the workflow further includes:
and updating the execution result of the current step according to the result identification information output by the executable code.
In one possible implementation, determining a current step performed in the workflow includes:
and determining all upstream steps of the current step from the workflow, and if the execution results of all the upstream steps are determined to be preset execution results, determining to execute the current step.
According to another aspect of the embodiments of the present application, there is provided a disaster recovery switching device of a service system, the device including:
the target disaster recovery switching scene determining module is used for responding to the triggering of disaster recovery switching by the service system and determining a target disaster recovery switching scene;
the target service disaster tolerance flow determining module is used for determining a target service disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library;
the starting module is used for starting a target business disaster tolerance process;
the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance.
In one possible implementation, the apparatus further includes:
the workflow configuration module is used for configuring corresponding workflows for each disaster tolerance scene;
and the business disaster tolerance flow generation module is used for configuring corresponding executable codes, execution categories and execution state information for each step in the workflow, and appointing execution sequence information among the steps so as to generate the business disaster tolerance flow corresponding to the workflow.
In one possible implementation, the starting module further includes:
a current step determination submodule for determining a current step to be executed in the workflow;
the judging submodule is used for judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step;
and the next step determining submodule is used for determining the next step from the workflow after the executable code is executed if the executable code is determined to be executed.
In one possible implementation, the execution state information includes information indicating whether the corresponding step was abnormally retried, breakpoint suspended, or skipped;
a judgment submodule comprising:
the first execution unit is used for executing the corresponding executable code if the execution state information is used for indicating the abnormal retry of the corresponding step, and re-executing the corresponding executable code according to the abnormal times if the execution is abnormal;
the second execution unit is used for pausing the execution of the corresponding executable code if the execution state information is used for indicating that the corresponding step is breakpoint pausing;
and the third execution unit is used for skipping to execute the corresponding executable code and determining the next step from the workflow if the execution state information is used for indicating that the corresponding step is skipped.
In a possible implementation manner, the service disaster tolerance process generating module further includes:
and the definition submodule is used for defining and realizing the execution logic of the executable code and defining the identification information of each execution state of the executable code.
In one possible implementation manner, the next step determining sub-module is further configured to update the execution result of the current step according to result identification information output by the executable code.
In a possible implementation manner, the current-step determining submodule is specifically configured to determine all upstream steps of the current step from the workflow, and if it is determined that the execution results of all the upstream steps are the preset execution results, determine to execute the current step.
According to another aspect of embodiments of the present application, there is provided an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method as provided in the first aspect when executing the program.
According to a further aspect of embodiments of the present application, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method as provided by the first aspect.
According to yet another aspect of embodiments of the present application, there is provided a computer program product comprising computer instructions stored in a computer-readable storage medium, which, when read by a processor of a computer device from the computer-readable storage medium, cause the processor to execute the computer instructions, so that the computer device performs the steps of implementing the method as provided by the first aspect.
The technical scheme provided by the embodiment of the application has the following beneficial effects:
the embodiment of the application determines a target disaster recovery switching scene by responding to the triggering of the disaster recovery switching of the service system; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster tolerance flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings used in the description of the embodiments of the present application will be briefly described below.
Fig. 1 is a schematic flowchart of a disaster recovery switching method of a service system according to an embodiment of the present application;
fig. 2 is a schematic flowchart of a process of starting a target service disaster recovery flow according to an embodiment of the present application;
fig. 3 is a schematic structural diagram of a disaster recovery device of a service system according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
Embodiments of the present application are described below in conjunction with the drawings in the present application. It should be understood that the embodiments set forth below in connection with the drawings are exemplary descriptions for explaining technical solutions of the embodiments of the present application, and do not limit the technical solutions of the embodiments of the present application.
As used herein, the singular forms "a", "an", "the" and "the" include plural referents unless the content clearly dictates otherwise. It should be further understood that the terms "comprises" and/or "comprising," when used in this specification in connection with embodiments of the present application, specify the presence of stated features, information, data, steps, operations, elements, and/or components, but do not preclude the presence or addition of other features, information, data, steps, operations, elements, components, and/or groups thereof, as embodied in the art. It will be understood that when an element is referred to as being "connected" or "coupled" to another element, it can be directly connected or coupled to the other element or intervening elements may be present. Further, "connected" or "coupled" as used herein may include wirelessly connected or wirelessly coupled. The term "and/or" as used herein indicates at least one of the items defined by the term, e.g., "a and/or B" may be implemented as "a", or as "B", or as "a and B".
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
The terms referred to in this application will first be introduced and explained:
the disaster recovery system is characterized in that two or more sets of IT systems with the same function are established in remote places, health status monitoring and function switching can be carried out among the IT systems, and when one system stops working due to accidents (such as fire, earthquake and the like), the whole application system can be switched to the other system, so that the system can continue to work normally. The disaster recovery technology is a component of the high-availability technology of the system, and the disaster recovery system emphasizes the processing of the influence of the external environment on the system, particularly the influence of a catastrophic event on the whole IT node, and provides a node-level system recovery function.
The disaster recovery system can be divided into data level disaster recovery, application level disaster recovery and service level disaster recovery according to the protection degree of the system.
The data-level disaster recovery refers to remote backup of data by establishing a remote disaster recovery center, and after a disaster occurs, it is ensured that original data is not lost or damaged, but at the level of the data-level disaster recovery, application is interrupted when the disaster occurs.
In a data-level disaster recovery mode, the established remote disaster recovery center can simply understand it as a remote data backup center.
The application level disaster recovery is that a set of same application system is constructed on a backup site on the basis of data level disaster recovery, and by a synchronous or asynchronous replication technology, the key application can be guaranteed to recover operation within an allowed time range, the loss caused by a disaster is reduced as much as possible, a user basically cannot feel the disaster, and thus, the service provided by the system is complete, reliable and safe.
Service level disaster recovery is full service disaster recovery, and requires all infrastructure in addition to necessary IT related technologies. Most contents of the system are non-IT systems (such as telephones, office places and the like), when a disaster occurs, the original office places are damaged, and except the recovery of data and applications, a backup work place is needed to normally develop services.
The present application provides a disaster recovery switching method and apparatus for a business system, an electronic device, a computer-readable storage medium, and a computer program product, which are intended to solve the above technical problems in the prior art.
The technical solutions of the embodiments of the present application and the technical effects produced by the technical solutions of the present application will be described below through descriptions of several exemplary embodiments. It should be noted that the following embodiments may be referred to, referred to or combined with each other, and the description of the same terms, similar features, similar implementation steps, etc. in different embodiments is not repeated.
An embodiment of the present application provides a disaster recovery switching method for a service system, and as shown in fig. 1, the method includes:
step S101, responding to the service system triggering disaster tolerance switching, and determining a target disaster tolerance switching scene.
The embodiment of the application provides a one-key disaster recovery switching method for a business system from a visualization angle, and particularly, the embodiment of the application can provide a visualization interface, and the one-key disaster recovery switching is performed on the visualization interface.
The disaster recovery switching scene in the embodiment of the application is a scene for switching the service from the production environment to the disaster recovery environment when the service system fails.
According to the embodiment of the application, when disaster recovery switching triggered by a service system is detected, a target disaster recovery switching scene is determined in response to the disaster recovery switching triggered by the service system.
Specifically, the disaster recovery switching may be triggered by a service system due to an operation performed by a user on a visual interface, or may be automatically triggered when a failure is detected by the service system.
Step S102, determining a target business disaster tolerance flow corresponding to the target disaster tolerance switching scene from a preset flow library.
The process library comprises a plurality of service disaster tolerance processes which are configured in advance, each service disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the service disaster tolerance processes are used for executing workflows which are configured in advance and switched in a disaster tolerance mode.
WorkFlow (WorkFlow) is a computational model of a WorkFlow, i.e., the logic and rules of how the work in the WorkFlow is organized one after the other are represented in a computer in an appropriate model and computed.
The embodiment of the application provides a process library, which may be a database, wherein a plurality of service disaster recovery processes are configured in the process library, each service disaster recovery process is used for executing workflows which are configured in advance and switched over in a disaster recovery manner, each workflow comprises an execution logic of the corresponding service disaster recovery process, different service units are configured into a task step to be combined into a complete disaster recovery switching process, such as a logic for realizing start and stop of service application, cache refreshing time setting, database switching, script cleaning and the like.
Each business disaster tolerance flow corresponds to at least one disaster tolerance switching scene, and a target business disaster tolerance flow corresponding to the disaster tolerance switching scene can be searched from the flow library according to the corresponding relation between the disaster tolerance flow and the disaster tolerance scene, so that the target business disaster tolerance flow corresponding to the target disaster tolerance scene can be determined from the preset flow library.
The preset flow library in the embodiment of the application includes a service disaster recovery flow corresponding to a disaster recovery cut scene, and also includes an execution flow corresponding to a common service scene, for example, the execution flow corresponding to an automatic billing scene includes definition and implementation of dialog list landing, bill inspection, online account guide, bill inspection, bill splitting and the like, and an automatic billing flow can be formed.
Step S103, starting a target business disaster tolerance process.
After the target disaster recovery switching scene is determined, the business disaster recovery flow corresponding to the target disaster recovery switching scene is directly started to perform disaster recovery switching.
The embodiment of the application determines a target disaster recovery switching scene by responding to the triggering of the disaster recovery switching of the service system; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster recovery flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.
The embodiment of the present application provides a possible implementation manner, where in response to a service system triggering disaster recovery switching, the method further includes:
configuring corresponding workflow for each disaster tolerance scene;
and configuring corresponding executable codes, execution categories and execution state information for each step in the workflow, and specifying execution sequence information among the steps to generate a business disaster tolerance flow corresponding to the workflow.
The steps S101 to S103 are to perform disaster recovery switching from a visualization angle, and in an actual process, many backend processes are involved, before a response service system triggers disaster recovery switching, corresponding workload needs to be configured for each disaster recovery scene, and corresponding executable codes, execution categories and execution state information are configured for each workflow, wherein the execution categories comprise starting, stopping, detecting, refreshing and the like, the execution state information comprises information such as execution estimated time, abnormal retry, breakpoint pause, skipping and the like of tasks, besides the corresponding executable codes, the execution categories and the execution state information are configured for each step, execution sequence information among the steps needs to be specified, parallel and serial execution modes among a plurality of task steps are specified, execution sequence among different steps is specified, execution conditions of subsequent task branches are set, and the like, so that a service disaster recovery flow corresponding to the workflow is generated.
The embodiment of the present application provides a possible implementation manner, and the starting of the target service disaster recovery process includes:
determining a current step performed in the workflow;
judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step;
if the executable code is determined to be executed, a next step is determined from the workflow after the executable code is executed.
The method includes the steps that a business disaster tolerance process is started, a current execution step of a workflow is determined, the step is in a ready state before the current step is executed, a front step of the step is completed, the step is in the ready state, and if the current step has a plurality of front steps of refrigerators, the current step is executed after all potential steps are executed.
After the current step is determined, whether the corresponding executable code is executed or not is judged according to the execution state information of the current step, the execution state information is used for indicating whether the corresponding step is abnormally retried, and the breakpoint is paused or skipped, if the execution state information is used for indicating the corresponding step is abnormally retried, the corresponding executable code is executed, and if the execution state information is used for indicating that the corresponding step is the breakpoint paused, the corresponding executable code is paused; and if the execution state information is used for indicating that the corresponding step is skipped, the corresponding executable code is skipped to be executed, and the next step is determined from the workflow.
The embodiment of the application provides a possible implementation manner, and the execution state information includes information used for indicating whether corresponding steps are abnormally retried or not, and breakpoint is suspended or skipped;
judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step, wherein the judging comprises the following steps:
if the execution state information is used for indicating the abnormal retry of the corresponding step, executing the corresponding executable code, and if the execution is abnormal, re-executing the corresponding executable code according to the abnormal times;
if the execution state information is used for indicating that the corresponding step is breakpoint pause, pausing to execute the corresponding executable code;
and if the execution state information is used for indicating that the corresponding step is skipped, skipping to execute the corresponding executable code and determining the next step from the workflow.
As shown in fig. 2, an exemplary schematic flow chart of starting a target service disaster tolerance process includes: step S201, determining the current step executed in the workflow, wherein the current step is in a ready state; step S202, according to the execution state information corresponding to the current step; step S203, if the status indication information is used for indicating the corresponding step to retry abnormally, executing the corresponding executable code, and if the execution is abnormal, re-executing the corresponding executable code according to the abnormal times; step S203', if the execution state information is used to indicate that the corresponding step is breakpoint pause, the corresponding executable code is paused to be executed, and the task operation is started to be continuously executed in the target business disaster tolerance process; step S203 ″, if the execution status information indicates that the corresponding step is skipped, the corresponding executable code is skipped, and the next step is determined from the workflow.
The embodiment of the present application provides a possible implementation manner, and generates a service disaster recovery flow corresponding to a workflow, which previously includes:
defining and implementing executable code execution logic, defining identification information of each execution state of the executable code.
In the embodiment of the application, before generating the service disaster recovery flow corresponding to the workflow, the execution logic of the executable code and the identification information of the executable state of the executable code need to be defined and implemented, where the identification information includes a completion identification, a success identification, a failure identification, exception information, execution progress, and the like.
In particular, the definition of the execution logic of the executable code includes the definition of switch objects, trigger conditions, scene features, and the like.
The embodiment of the present application provides a possible implementation manner, where the next step is determined from a workflow, and the method further includes:
and updating the execution result of the current step according to the result identification information output by the executable code.
The identification information of the embodiment of the application comprises a completion identification, a success identification, a failure identification, abnormal information and an execution progress, and after the execution result of the current step is obtained, the execution result is updated to the identification information.
After the execution result of the current step is updated according to the identification information, the execution result can be pushed to a page to be monitored and displayed, and the effect of transparency of the switching process is achieved.
The embodiment of the present application provides a possible implementation manner, and the determining of the current step executed in the workflow includes:
and determining all upstream steps of the current step from the workflow, and if the execution results of all the upstream steps are determined to be preset execution results, determining to execute the current step.
According to the embodiment of the application, after the current step is executed, the execution result of the current step is updated according to the result identification information output by the executable code, and the current step can be determined to enter and be executed after all steps before the current step are executed to obtain the execution result, namely after all parallel and serial steps before the current step are executed to obtain the preset execution result, the current step is determined to be executed.
In addition, after the target business disaster recovery process is executed, the execution of the key steps is generated, wherein the execution comprises the starting time, the ending time, the execution result and the execution information of each step, and the steps are used for analyzing and improving.
An embodiment of the present application provides a disaster recovery switching device of a service system, as shown in fig. 3, a disaster recovery switching device 30 of the service system may include:
a target disaster recovery switching scenario determination module 310, configured to determine a target disaster recovery switching scenario in response to a service system triggering disaster recovery switching;
a target service disaster tolerance process determining module 320, configured to determine, from a preset process library, a target service disaster tolerance process corresponding to a target disaster tolerance switching scenario;
a starting module 330, configured to start a target service disaster recovery process;
the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance.
The embodiment of the application determines a target disaster recovery switching scene by responding to the triggering of the disaster recovery switching of the service system; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster tolerance flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.
The embodiment of the present application provides a possible implementation manner, and the apparatus further includes:
the workflow configuration module is used for configuring corresponding workflows for each disaster tolerance scene;
and the business disaster tolerance flow generation module is used for configuring corresponding executable codes, execution categories and execution state information for each step in the workflow, and appointing execution sequence information among the steps so as to generate the business disaster tolerance flow corresponding to the workflow.
The embodiment of the present application provides a possible implementation manner, and the starting module further includes:
a current step determination submodule for determining a current step to be executed in the workflow;
the judging submodule is used for judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step;
and the next step determining submodule is used for determining the next step from the workflow after the executable code is executed if the executable code is determined to be executed.
The embodiment of the application provides a possible implementation manner, and the execution state information includes information used for indicating whether corresponding steps are abnormally retried or not, and breakpoint is suspended or skipped;
a judgment submodule comprising:
the first execution unit is used for executing the corresponding executable code if the execution state information is used for indicating the abnormal retry of the corresponding step, and re-executing the corresponding executable code according to the abnormal times if the execution is abnormal;
the second execution unit is used for pausing the execution of the corresponding executable code if the execution state information is used for indicating that the corresponding step is breakpoint pausing;
and the third execution unit is used for skipping to execute the corresponding executable code and determining the next step from the workflow if the execution state information is used for indicating that the corresponding step is skipped.
The embodiment of the present application provides a possible implementation manner, and the service disaster tolerance process generation module further includes:
and the definition submodule is used for defining and realizing the execution logic of the executable code and defining the identification information of each execution state of the executable code.
The embodiment of the application provides a possible implementation manner, and the determining sub-module in the next step is further configured to update the execution result of the current step according to result identification information output by the executable code.
The embodiment of the application provides a possible implementation manner, and the current step determining submodule is specifically configured to determine all upstream steps of the current step from the workflow, and if it is determined that execution results of all the upstream steps are preset execution results, determine to execute the current step.
The apparatus of the embodiment of the present application may execute the method provided by the embodiment of the present application, and the implementation principle is similar, the actions executed by the modules in the apparatus of the embodiments of the present application correspond to the steps in the method of the embodiments of the present application, and for the detailed functional description of the modules of the apparatus, reference may be specifically made to the description in the corresponding method shown in the foregoing, and details are not repeated here.
The embodiment of the present application provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory, where the processor executes the computer program to implement the steps of the disaster recovery switching method of a service system, and as compared with the related art, the method can implement: the embodiment of the application determines a target disaster recovery switching scene by responding to the triggering of the disaster recovery switching of the service system; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster tolerance flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.
In an alternative embodiment, an electronic device is provided, as shown in fig. 4, the electronic device 4000 shown in fig. 4 comprising: a processor 4001 and a memory 4003. Processor 4001 is coupled to memory 4003, such as via bus 4002. Optionally, the electronic device 4000 may further include a transceiver 4004, and the transceiver 4004 may be used for data interaction between the electronic device and other electronic devices, such as transmission of data and/or reception of data. It should be noted that the transceiver 4004 is not limited to one in practical applications, and the structure of the electronic device 4000 is not limited to the embodiment of the present application.
The Processor 4001 may be a CPU (Central Processing Unit), a general-purpose Processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other Programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. The processor 4001 may also be a combination that performs a computational function, including, for example, a combination of one or more microprocessors, a combination of a DSP and a microprocessor, or the like.
Bus 4002 may include a path that carries information between the aforementioned components. The bus 4002 may be a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. The bus 4002 may be divided into an address bus, a data bus, a control bus, and the like. For ease of illustration, only one thick line is shown in FIG. 4, but this does not indicate only one bus or one type of bus.
The Memory 4003 may be a ROM (Read Only Memory) or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory) or other types of dynamic storage devices that can store information and instructions, an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory) or other optical Disc storage, optical Disc storage (including Compact Disc, laser Disc, optical Disc, digital versatile Disc, blu-ray Disc, etc.), a magnetic Disc storage medium, other magnetic storage devices, or any other medium that can be used to carry or store a computer program and that can be Read by a computer, without limitation.
The memory 4003 is used for storing computer programs for executing the embodiments of the present application, and is controlled by the processor 4001 to execute. The processor 4001 is used to execute computer programs stored in the memory 4003 to implement the steps shown in the foregoing method embodiments.
The electronic device package may include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (personal digital assistant), a PAD (tablet computer), a PMP (portable multimedia player), a vehicle-mounted terminal (e.g., a car navigation terminal), etc., and a stationary terminal such as a digital TV, a desktop computer, etc., among others. The electronic device shown in fig. 4 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
The embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when being executed by a processor, the computer program can implement the steps and corresponding contents of the foregoing method embodiment, compared with the related art, and implement: the embodiment of the application determines a target disaster recovery switching scene by responding to the triggering of the disaster recovery switching of the service system; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster tolerance flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.
Embodiments of the present application further provide a computer program product, including a computer program, where the computer program, when executed by a processor, may implement the steps and corresponding contents of the foregoing method embodiments, as compared with the related art, and implement: the embodiment of the application determines a target disaster recovery switching scene by responding to the triggering of the disaster recovery switching of the service system; determining a target business disaster tolerance flow corresponding to a target disaster tolerance switching scene from a preset flow library; starting a target business disaster recovery flow; the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched by disaster tolerance. According to the embodiment of the application, disaster recovery switching of the service system is realized through the visual angle, the operation is simple, and the task arrangement modes under different scenes are met.
The terms "first," "second," "third," "fourth," "1," "2," and the like in the description and in the claims of the present application and in the above-described drawings (if any) are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used are interchangeable under appropriate circumstances such that the embodiments of the application described herein are capable of operation in other sequences than described or illustrated herein.
It should be understood that, although each operation step is indicated by an arrow in the flowchart of the embodiment of the present application, the implementation order of the steps is not limited to the order indicated by the arrow. In some implementation scenarios of the embodiments of the present application, the implementation steps in the flowcharts may be performed in other sequences as desired, unless explicitly stated otherwise herein. In addition, some or all of the steps in each flowchart may include multiple sub-steps or multiple stages based on an actual implementation scenario. Some or all of these sub-steps or stages may be performed at the same time, or each of these sub-steps or stages may be performed at different times, respectively. In a scenario where execution times are different, an execution sequence of the sub-steps or the phases may be flexibly configured according to requirements, which is not limited in the embodiment of the present application.
The above are only optional embodiments of partial implementation scenarios in the present application, and it should be noted that, for those skilled in the art, other similar implementation means based on the technical idea of the present application are also within the scope of protection of the embodiments of the present application without departing from the technical idea of the present application.

Claims (11)

1. A disaster recovery switching method of a service system is characterized by comprising the following steps:
responding to the triggering of disaster tolerance switching of a service system, and determining a target disaster tolerance switching scene;
determining a target business disaster tolerance flow corresponding to the target disaster tolerance switching scene from a preset flow library;
starting the target business disaster tolerance process;
the process library comprises a plurality of service disaster tolerance processes which are configured in advance, each service disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the service disaster tolerance processes are used for executing workflows which are configured in advance and switched in a disaster tolerance mode.
2. The method of claim 1, wherein triggering the disaster recovery handover in response to the traffic system further comprises:
configuring corresponding workflow for each disaster tolerance scene;
and configuring corresponding executable codes, execution categories and execution state information for each step in the workflow, and specifying execution sequence information among the steps to generate a business disaster recovery flow corresponding to the workflow.
3. The method according to claim 2, wherein the starting the target business disaster recovery process comprises:
determining a current step performed in the workflow;
judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step;
if the executable code is determined to be executed, determining a next step from the workflow after the executable code is executed.
4. The method of claim 3, wherein the execution state information includes information indicating whether the corresponding step was abnormally retried, paused, or skipped;
the judging whether to execute the corresponding executable code according to the execution state information corresponding to the current step includes:
if the execution state information is used for indicating the abnormal retry of the corresponding step, executing the corresponding executable code, and if the execution is abnormal, re-executing the corresponding executable code according to the abnormal times;
if the execution state information is used for indicating that the corresponding step is breakpoint pause, pausing to execute the corresponding executable code;
and if the execution state information is used for indicating that the corresponding step is skipped, executing the corresponding executable code in a skipping way, and determining the next step from the workflow.
5. The method according to claim 4, wherein the generating of the service disaster recovery procedure corresponding to the workflow further comprises:
defining and implementing the executable code execution logic, and defining identification information of each execution state of the executable code.
6. The method of claim 5, wherein said determining a next step from said workflow is preceded by:
and updating the execution result of the current step according to the identification information.
7. The method of claim 6, wherein said determining a current step performed in said workflow comprises:
and determining all upstream steps of the current step from the workflow, and if the execution results of all the upstream steps are determined to be preset execution results, determining to execute the current step.
8. A disaster recovery switching device of a service system, comprising:
the target disaster recovery switching scene determining module is used for responding to the triggering of disaster recovery switching by the service system and determining a target disaster recovery switching scene;
the target service disaster tolerance flow determining module is used for determining a target service disaster tolerance flow corresponding to the target disaster tolerance switching scene from a preset flow library;
the starting module is used for starting the target business disaster tolerance process;
the process library comprises a plurality of disaster tolerance processes which are configured in advance, each disaster tolerance process corresponds to at least one disaster tolerance switching scene, and the business disaster tolerance process is used for executing a workflow which is configured in advance and switched in a disaster tolerance mode.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory, characterized in that the processor executes the computer program to implement the steps of the method of any of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
11. A computer program product comprising a computer program, characterized in that the computer program realizes the steps of the method of any one of claims 1-7 when executed by a processor.
CN202111656700.2A 2021-12-30 2021-12-30 Disaster tolerance switching method and device for business system, electronic equipment and storage medium Pending CN114610530A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111656700.2A CN114610530A (en) 2021-12-30 2021-12-30 Disaster tolerance switching method and device for business system, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111656700.2A CN114610530A (en) 2021-12-30 2021-12-30 Disaster tolerance switching method and device for business system, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114610530A true CN114610530A (en) 2022-06-10

Family

ID=81857742

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111656700.2A Pending CN114610530A (en) 2021-12-30 2021-12-30 Disaster tolerance switching method and device for business system, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114610530A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118250153A (en) * 2024-05-28 2024-06-25 深圳市科力锐科技有限公司 Service disaster recovery network configuration method, device, equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118250153A (en) * 2024-05-28 2024-06-25 深圳市科力锐科技有限公司 Service disaster recovery network configuration method, device, equipment and storage medium
CN118250153B (en) * 2024-05-28 2024-08-09 深圳市科力锐科技有限公司 Service disaster recovery network configuration method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
US20210374025A1 (en) Fault Injection Method and Apparatus, Electronic Device and Storage Medium
CN109189677B (en) Test method and device for updating state of variable value
CN114610530A (en) Disaster tolerance switching method and device for business system, electronic equipment and storage medium
EP4224317A1 (en) Method and apparatus for controlling distributed operation system, and device, medium and program product
CN115599665A (en) Disaster recovery system testing method and device, electronic equipment and storage medium
CN113760611A (en) System site switching method and device, electronic equipment and storage medium
CN112965799A (en) Task state prompting method and device, electronic equipment and medium
CN113537837A (en) Automatic sorting method and device and computer equipment
CN112631843A (en) Equipment testing method and device, electronic equipment, readable medium and product
CN112818204A (en) Service processing method, device, equipment and storage medium
CN114647531B (en) Failure solving method, failure solving system, electronic device, and storage medium
CN115190008B (en) Fault processing method, fault processing device, electronic equipment and storage medium
CN111367934A (en) Data consistency checking method, device, server and medium
CN112463514A (en) Monitoring method and device for distributed cache cluster
CN108255667B (en) Service monitoring method and device and electronic equipment
CN115437961A (en) Data processing method and device, electronic equipment and storage medium
CN115470075A (en) Application program fault detection method and device, electronic equipment and storage medium
CN114091909A (en) Collaborative development method, system, device and electronic equipment
CN113448767A (en) Distributed transaction database recovery method, device, equipment and storage medium
CN115311082A (en) Transaction data difference rolling method, difference rolling application system, medium and electronic equipment
CN115878460A (en) Regression testing method, device, computer equipment and storage medium
CN109714373B (en) Script cooperation method and device
CN115391227A (en) Fault testing method, device, equipment and medium based on distributed system
CN107566478B (en) Data pushing method, system and computer readable storage medium
CN115391138A (en) Page browsing data uploading method and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination