Government affair data synchronization and monitoring method and system

Through the combination of flink-cdc plug-in, RocketMQ component, monitoring module and ES search engine, real-time synchronization and monitoring of government data are achieved, which solves the problem of government service data synchronization and monitoring, and improves the quality of government services and the efficiency of data query.

CN118585584APending Publication Date: 2024-09-03INSPUR SOFTWARE CO LTD

Patent Information

Application Number
CN202410706577.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-03
Publication Date
2024-09-03

AI Technical Summary

Technical Problem

How to realize real-time synchronization and monitoring of government service data and improve the quality of government services. It is difficult for existing technology to effectively solve the problem of data synchronization and monitoring of government data.

Method used

Use the flink-cdc plug-in to monitor the business system database, realize real-time synchronization and monitoring of government data through RocketMQ components and monitoring modules, monitoring databases and ES search engines, structured processing of handling information, and data persistence and monitoring based on pre-configured monitoring rules. Query statistics.

Benefits of technology

It achieves real-time synchronization and monitoring of government service data, rapid query and statistics, improves government service capabilities, enables real-time supervision and feedback on problems, and improves the quality of government services.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118585584A
    Figure CN118585584A
Patent Text Reader

Abstract

The invention discloses a government affair data synchronization and supervision method and system, belongs to the technical field of government affair services, and aims to solve the technical problems of how to realize data synchronization and data supervision of government affair service data and improve the government affair service quality of government affair departments at all levels. A business system database is monitored through an flink-cdc plug-in, and structured file handling information is sent to a data synchronization theme in a Rocket MQ component; and the monitoring module persists the structured file handling information to a monitoring database for storage, sends a calculation message to the calculation subject, reads the file handling information specified by the calculation message from the monitoring database, and monitors the file handling process based on a pre-configured monitoring rule. Pushing the obtained monitoring result information to a monitoring ES search engine for storage; and offering file handling information through the supervision database, and offering supervision result information through the supervision ES search engine so as to realize query statistics service.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of government service technology, and specifically to a government data synchronization and monitoring method and system. Background Art

[0002] In the handling of government service items, the handling information includes handling information, handling process information, handling result information, special procedure information and material catalog information. The supervision and assessment of government service items should follow the four principles of objectivity and fairness, user orientation, classification assessment and internal and external conclusion.

[0003] How to achieve data synchronization and data monitoring of government service data and improve the quality of government services provided by government departments at all levels is a technical problem that needs to be solved. Summary of the invention

[0004] The technical task of the present invention is to address the above deficiencies and provide a government data synchronization and monitoring method and system to solve the technical problem of how to achieve data synchronization and data monitoring of government service data and improve the quality of government services of government departments at all levels.

[0005] In a first aspect, the present invention provides a government data synchronization and monitoring method, which is applied to a business system database, a flink-cdc plug-in, a RocketMQ component, a monitoring module, a monitoring database, and a monitoring ES search engine. The method comprises the following steps:

[0006] The business system database is monitored through the flink-cdc plug-in. When there are changes in business data in the business system database, the data to be synchronized is read from the business system database as the case information and the case information is structured to obtain structured case information. The structured case information is sent to the data synchronization topic in the RocketMQ component.

[0007] After the monitoring module receives the structured case information pushed by the data synchronization topic it subscribes to, it persists the structured case information to the monitoring database for storage based on the type of the board information, and sends a calculation message to the calculation topic in the RocketMQ component;

[0008] After receiving the calculation message pushed by the calculation topic it subscribes to, the monitoring module reads the case information specified by the calculation message from the monitoring database, monitors the case processing process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage;

[0009] The inspection database provides case information, and the inspection result information is provided through the inspection ES search engine to realize query and statistical services.

[0010] Preferably, the monitoring module includes a monitoring data synchronization module, a monitoring data calculation module and a monitoring timing calculation module. Correspondingly, the calculation subject in the RocketMQ component includes a data calculation subject corresponding to the monitoring data calculation module and a timing calculation subject corresponding to the monitoring timing calculation module;

[0011] After the monitoring data synchronization module receives the structured case information pushed by the subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the case information, and sends a calculation message to the data calculation topic in the RocketMQ component.

[0012] After receiving the data calculation message pushed by the subscribed data calculation topic, the monitoring data calculation module reads the corresponding case information from the monitoring database based on the case number specified in the data calculation message, and performs rule calculation on the case process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case needs timed calculation based on the case status and the monitoring rules that have been triggered by the case. If timed calculation is required, a timed calculation message is sent to the timed calculation topic;

[0013] After the monitoring timed calculation module receives the timed calculation message pushed by the subscribed timed calculation topic, it reads the corresponding case information and case result information from the monitoring database and the monitoring ES search engine based on the case number specified in the timed calculation message, and performs timed monitoring and calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires timed calculation based on the case status and the monitoring rules that have been triggered. If timed calculation is required, a timed calculation message is sent to the timed calculation topic.

[0014] Preferably, based on the type of the case information, the case information includes case handling information, case process information, case result information, special procedure information and material catalog information, wherein the case handling information, case process information, case result information, special procedure information and material catalog information are mapped based on the plate number;

[0015] The case handling process information, special procedure information and material catalog information are stored in the supervision database;

[0016] The case handling information and case handling result information are stored in the ES search engine. The ES search engine is configured with an object type structure named rulesFlag. RulesFlag is used to store the inspection result information. The inspection rules exist in the form of inspection rule name key in rulesFlag.

[0017] An exception rule table is formed based on the configured monitoring rules. The exception rule table includes id, monitoring rule name, monitoring rule category and monitoring rule code. The monitoring rule code is a different key in rulesFlag.

[0018] Abnormal rules are divided into time limit abnormalities, process abnormalities, content abnormalities, discretionary abnormalities and corruption risk point abnormalities.

[0019] Preferably, for the case information that needs to be synchronized, when the flink-cdc plug-in serializes the case information, a field is created in the flink-cdc plug-in to store the attribute information of the business system database. The attribute information includes database, schema, table and operation information. The source and type of the case information are determined based on the attribute information. The data structure of the case information is converted based on the source and type of the case information. The type of operation on the data that needs to be synchronized is determined based on the operation information. The operation types include addition, modification and deletion, and structured case information is obtained.

[0020] In a second aspect, the present invention provides a government data synchronization and monitoring system, including a flink-cdc plug-in, a RocketMQ component, a monitoring module, a monitoring database, and a monitoring ES search engine;

[0021] The flink-cdc plug-in is used to perform the following: monitor the business system database. When there are changes in business data in the business system database, read the data that needs to be synchronized from the business system database as the case information and perform structured processing on the case information to obtain structured case information, and send the structured case information to the data synchronization topic in the RocketMQ component;

[0022] The monitoring module is used to perform the following: after receiving the structured handling information pushed by its subscribed data synchronization topic, it persists the structured handling information to the monitoring database for storage based on the type of the board information, and sends a calculation message to the calculation topic in the RocketMQ component; after receiving the calculation message pushed by its subscribed calculation topic, it reads the handling information specified by the calculation message from the monitoring database, monitors the handling process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage;

[0023] The monitoring database and the monitoring ES search engine provide query and statistical services for case handling information and monitoring result information.

[0024] Preferably, the monitoring module includes a monitoring data synchronization module, a monitoring data calculation module and a monitoring timing calculation module. Correspondingly, the calculation subject in the RocketMQ component includes a data calculation subject corresponding to the monitoring data calculation module and a timing calculation subject corresponding to the monitoring timing calculation module;

[0025] Correspondingly, the monitoring data synchronization module is used to perform the following: after receiving the structured case information pushed by its subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the case information, and sends a calculation message to the data calculation topic in the RocketMQ component.

[0026] The monitoring data calculation module is used to perform the following: after receiving the data calculation message pushed by the subscribed data calculation topic, it reads the corresponding case information from the monitoring database based on the case number specified in the data calculation message, and performs rule calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case needs timed calculation based on the case status and the monitoring rules that have been triggered by the case. If timed calculation is required, a timed calculation message is sent to the timed calculation topic;

[0027] The monitoring timed calculation module is used to perform the following: after receiving the timed calculation message pushed by the subscribed timed calculation topic, it reads the corresponding case information and case result information from the monitoring database and the monitoring ES search engine based on the case number specified in the timed calculation message, and performs timed monitoring and calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires timed calculation based on the case status and the monitoring rules that have been triggered. If timed calculation is required, a timed calculation message is sent to the timed calculation topic.

[0028] Preferably, based on the type of the case information, the case information includes case handling information, case process information, case result information, special procedure information and material catalog information, wherein the case handling information, case process information, case result information, special procedure information and material catalog information are mapped based on the plate number;

[0029] The case handling process information, special procedure information and material catalog information are stored in the supervision database;

[0030] The case handling information and case handling result information are stored in the ES search engine. The ES search engine is configured with an object type structure named rulesFlag. RulesFlag is used to store the inspection result information. The inspection rules exist in the form of inspection rule name key in rulesFlag.

[0031] An exception rule table is formed based on the configured monitoring rules. The exception rule table includes id, monitoring rule name, monitoring rule category and monitoring rule code. The monitoring rule code is a different key in rulesFlag.

[0032] Abnormal rules are divided into time limit abnormalities, process abnormalities, content abnormalities, discretionary abnormalities and corruption risk point abnormalities.

[0033] Preferably, for the case information that needs to be synchronized, when the flink-cdc plug-in serializes the case information, a field is created in the flink-cdc plug-in to store the attribute information of the business system database. The attribute information includes database, schema, table and operation information. The source and type of the case information are determined based on the attribute information. The data structure of the case information is converted based on the source and type of the case information. The type of operation on the data that needs to be synchronized is determined based on the operation information. The operation types include addition, modification and deletion, and structured case information is obtained.

[0034] The government data synchronization and monitoring method and system of the present invention have the following advantages:

[0035] 1. Real-time synchronization and monitoring of government service data: Flink-cdc, rocketmq and ES search engine are used to implement real-time synchronization and monitoring calculation of government service data with different structures;

[0036] 2. Rapid query and related statistics of government service data: By storing government service data in a structured manner in the ES search engine and using different conditions for aggregated queries, statistical results of all dimensions under the full data volume can be quickly obtained. Compared with traditional database tables, performance issues under extremely large data volumes are avoided; compared with traditional government service systems, queries and statistics of various monitoring rule dimensions are added;

[0037] 3. Real-time supervision and feedback of problematic cases can be provided to improve government service capabilities: Through synchronized and monitored data, problematic cases can be quickly fed back to the government service system, and relevant systems can be urged to make rectifications to improve government service capabilities. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0039] The present invention is further described below in conjunction with the accompanying drawings.

[0040] Figure 1 This is a flowchart of a government data synchronization and monitoring method according to Example 1;

[0041] Figure 2 This is a schematic diagram of information storage of an ES search engine in a government data synchronization and monitoring method in Example 1. DETAILED DESCRIPTION

[0042] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it. However, the embodiments are not intended to limit the present invention. In the absence of conflict, the embodiments of the present invention and the technical features in the embodiments may be combined with each other.

[0043] The embodiments of the present invention provide a government data synchronization and monitoring method and system for solving the technical problem of how to achieve data synchronization and data monitoring of government service data and improve the quality of government services of government departments at all levels.

[0044] Embodiment 1:

[0045] The present invention provides a government data synchronization and monitoring method, which is applied to a business system database, a flink-cdc plug-in, a RocketMQ component, a monitoring module, a monitoring database, and a monitoring ES search engine. The method comprises the following steps:

[0046] Step S100: Monitor the business system database through the flink-cdc plug-in. When there is a change in business data in the business system database, read the data to be synchronized from the business system database as the handling information and perform structured processing on the handling information to obtain structured handling information, and send the structured handling information to the data synchronization topic in the RocketMQ component.

[0047] Step S200: After the monitoring module receives the structured case information pushed by the subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the board information, and sends a calculation message to the calculation topic in the RocketMQ component;

[0048] Step S300: After receiving the calculation message pushed by the subscribed calculation topic, the monitoring module reads the case handling information specified by the calculation message from the monitoring database, monitors the case handling process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage;

[0049] Step S400: Provide case handling information through the monitoring database, and provide monitoring result information through the monitoring ES search engine to realize query statistics service.

[0050] In this embodiment, the government service item handling information can be divided into five parts: case acceptance information (up_pro_accept), case process information (up_pro_process), case result information (up_pro_result), special procedure information (up_pro_specialprocedure), and material catalog information (up_pro_materialcatalogue). Each part has its own special table and field corresponding to it, and the case handling information, case process information, case result information, special procedure information and material catalog information are mapped based on the plate number.

[0051] There is a one-to-one relationship between case acceptance information, case result information and case information (each case has only one acceptance information and one result information), so the two parts of the case information are uniformly collected into an elasticsearch index structure according to the specified attributes as the basic information index of the case.

[0052] The relationship between the case handling process information, special procedure information, material catalog information and case handling information is many-to-one (each case handling has multiple case handling processes, multiple special procedures, and multiple material catalogs). Elasticsearch cannot provide good support for this many-to-one relationship, and the use scenario of this type of data is mostly to perform related queries after knowing the basic information of the case handling. Therefore, this part of the data is divided into tables according to the operation time and persisted in the database (the selection of the database is determined according to the actual situation). The case handling process information, special procedure information, and material catalog information are consistent, so as to meet the related query of this part of the case handling information.

[0053] The inspection result data is mostly used in scenarios that require fast response under large data volumes, such as case-related query, statistics, and supervision processes. Therefore, based on the elasticsearch index of case information, the inspection result information for different inspection rules is added to meet the needs of query, statistics, and business processes.

[0054] For the monitoring results of different rules, an object type structure named rulesFlag is set in the elasticsearch index to store the monitoring result information. Different monitoring rules exist in the form of monitoring rule name key in rulesFlag. If the corresponding rule is triggered, the value corresponding to its rule name key is 1 (for example, rulesFlag.Time limit rule == 1 means that the case triggers the time limit exception rule, otherwise it is not triggered).

[0055] Because rulesFlag has a one-to-one relationship with the case information, in order to facilitate the query and statistical analysis of relevant supervision data, rulesFlag is placed in the elasticsearch index structure of the basic case information (for example, Figure 2 shown).

[0056] In this embodiment, a combination of flink-cdc and rocketmq is used to achieve real-time data synchronization. Flink-cdc can monitor the operation logs of different types of databases (such as mysql binlog, pgsql wal) and output them in a structured manner. On this basis, the output structured information is sent to a fixed topic in rocketmq, and then a consumer is created to consume the messages in this topic, which can preliminarily achieve real-time monitoring of data from different business databases.

[0057] For the case information that needs to be synchronized, when the flink-cdc plug-in serializes the case information, the flink-cdc plug-in creates fields to store the attribute information of the business system database. The attribute information includes database, schema, table and operation information. The source and type of the case information are determined based on the attribute information. The data structure of the case information is converted based on the source and type of the case information. The type of operation on the data that needs to be synchronized is determined based on the operation information. The operation types include addition, modification and deletion, and structured case information is obtained.

[0058] In the consumer, for the data in the topic, flink-cdc will have special fields to store the database, schema, table and operation information of the database when serializing the information. This part of information can be used to determine which processing system the received data belongs to, and whether its data type is processing, process, special procedure, or material, and then perform the corresponding data structure conversion. After the conversion, the type of operation on the data can be determined based on the operation information, and the operation types include addition, deletion, and modification. Then, when the structured information is persisted, the corresponding operation can be performed to ensure the consistency and real-time synchronization of the monitoring data and the business system data.

[0059] Supervision rules can be divided into five aspects of abnormalities: time limit abnormalities, process abnormalities, content abnormalities, discretion abnormalities, and corruption risk point abnormalities. Each aspect can be specifically subdivided into different abnormalities (e.g., time limit abnormalities can be divided into: in-process case timeout abnormalities, completed case timeout abnormalities, in-process case warning abnormalities, etc.), so a separate table needs to be set for abnormal rules, which should at least contain id, supervision rule name, supervision rule classification, supervision rule specific content, and supervision rule code.

[0060] The monitoring rule code is the code corresponding to a specific monitoring rule, that is, the different keys in the monitoring result information rulesFlag, which are used to identify the specific triggering rules for handling cases; the specific content of the monitoring rule includes how to calculate the data for this rule and what conditions are met to trigger this rule (such as the overtime rule: determine whether the calculated time exceeds the promised completion time for the calculated case. If so, it is determined that the case triggers this rule).

[0061] As an improvement, in this embodiment, the monitoring module includes a monitoring data synchronization module, a monitoring data calculation module and a monitoring timing calculation module. Correspondingly, the calculation topics in the RocketMQ component include data calculation topics corresponding to the monitoring data calculation module and timing calculation topics corresponding to the monitoring timing calculation module.

[0062] After the monitoring data synchronization module receives the structured case information pushed by the subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the case information, and sends calculation messages to the data calculation topic in the RocketMQ component.

[0063] After the monitoring data calculation module receives the data calculation message pushed by the subscribed data calculation topic, it reads the corresponding case information from the monitoring database based on the case number specified in the data calculation message, and performs rule calculation on the case process based on the pre-configured monitoring rules. The obtained monitoring result information is pushed to the monitoring ES search engine for storage, and based on the case status and the monitoring rules that have been triggered by the case, it determines whether the case requires scheduled calculation. If scheduled calculation is required, a scheduled calculation message is sent to the scheduled calculation topic.

[0064] After the monitoring timed calculation module receives the timed calculation message pushed by the subscribed timed calculation topic, it reads the corresponding case information and case result information from the monitoring database and the monitoring ES search engine based on the case number specified in the timed calculation message, and performs timed monitoring and calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires timed calculation based on the case status and the monitoring rules that have been triggered. If timed calculation is required, a timed calculation message is sent to the timed calculation topic.

[0065] The method of this embodiment needs to obtain the handling information and perform calculation according to the corresponding supervision rules for the synchronized structured data. The calculation time can be divided into three categories: synchronization, calculation and scheduled calculation.

[0066] When there is data update, calculations need to be performed based on the latest case information to ensure the timeliness and accuracy of the calculation results. For this type of calculation, create a calculation topic in RocketMQ, and send a message to this calculation topic after the consumer data synchronization is completed. The message contains the case number information of the case, and set up a consumer to subscribe to this calculation topic. After receiving the message each time, the consumer queries the relevant information and monitoring rules of the synchronized case in the persistence layer of this model according to the case number, and then performs the corresponding calculation and persists the calculation results, thereby realizing the calculation function when the data is updated.

[0067] Scheduled calculations, for cases in progress, have rules that are highly time-sensitive (for example, a case in progress may not have timed out in the previous hour, but may have timed out in the next hour). Such cases require scheduled calculations and continuous updating of calculation results. For such calculations, create a scheduled topic in RocketMQ. After the consumer for calculations has calculated the data, determine whether the calculation results need to be calculated on a scheduled basis. If scheduled calculations are required, send a scheduled message to the scheduled topic (the specific timing is determined by the actual scenario). The message body is the same as that of the calculation topic. At the same time, set up a consumer to subscribe to this scheduled topic. This consumer will perform calculations again after receiving a message each time, and determine again whether scheduled calculations are required. If necessary, continue to send scheduled messages to the scheduled topic. If not, do not perform other operations, thereby realizing the function of scheduled calculations.

[0068] Based on the above synchronization, calculation and timed calculation, the functions of synchronization, monitoring and storage of government service data can be completed.

[0069] Embodiment 2:

[0070] The present invention provides a government data synchronization and monitoring system, including a flink-cdc plug-in, a RocketMQ component, a monitoring module, a monitoring database and a monitoring ES search engine.

[0071] The flink-cdc plug-in is used to perform the following: monitor the business system database. When there are business data changes in the business system database, read the data that needs to be synchronized from the business system database as the case information and structure the case information to obtain structured case information, and send the structured case information to the data synchronization topic in the RocketMQ component.

[0072] The monitoring module is used to perform the following: after receiving the structured case information pushed by its subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of board information, and sends a calculation message to the calculation topic in the RocketMQ component; after receiving the calculation message pushed by its subscribed calculation topic, it reads the case information specified by the calculation message from the monitoring database, monitors the case processing process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage.

[0073] The supervision database and supervision ES search engine provide query and statistical services for case handling information and supervision result information.

[0074] In this embodiment, the government service item handling information can be divided into five parts: case acceptance information (up_pro_accept), case process information (up_pro_process), case result information (up_pro_result), special procedure information (up_pro_specialprocedure), and material catalog information (up_pro_materialcatalogue). Each part has its own special table and field corresponding to it, and the case handling information, case process information, case result information, special procedure information and material catalog information are mapped based on the plate number.

[0075] There is a one-to-one relationship between case acceptance information, case result information and case information (each case has only one acceptance information and one result information), so the two parts of the case information are uniformly collected into an elasticsearch index structure according to the specified attributes as the basic information index of the case.

[0076] The relationship between the case handling process information, special procedure information, material catalog information and case handling information is many-to-one (each case handling has multiple case handling processes, multiple special procedures, and multiple material catalogs). Elasticsearch cannot provide good support for this many-to-one relationship, and the use scenario of this type of data is mostly to perform related queries after knowing the basic information of the case handling. Therefore, this part of the data is divided into tables according to the operation time and persisted in the database (the selection of the database is determined according to the actual situation). The case handling process information, special procedure information, and material catalog information are consistent, so as to meet the related query of this part of the case handling information.

[0077] The inspection result data is mostly used in scenarios that require fast response under large data volumes, such as case-related query, statistics, and supervision processes. Therefore, based on the elasticsearch index of case information, the inspection result information for different inspection rules is added to meet the needs of query, statistics, and business processes.

[0078] For the monitoring results of different rules, an object type structure named rulesFlag is set in the elasticsearch index to store the monitoring result information. Different monitoring rules exist in the form of monitoring rule name key in rulesFlag. If the corresponding rule is triggered, the value corresponding to its rule name key is 1 (for example, rulesFlag.Time limit rule == 1 means that the case triggers the time limit exception rule, otherwise it is not triggered).

[0079] Because rulesFlag and case information also have a one-to-one relationship, in order to facilitate the query and statistical analysis of relevant supervision data, rulesFlag is placed in the elasticsearch index structure of the basic case information.

[0080] In this embodiment, a combination of flink-cdc and rocketmq is used to achieve real-time data synchronization. Flink-cdc is used to monitor the operation logs of different types of databases (such as mysql binlog, pgsql wal) and output them in a structured manner. On this basis, the output structured information is sent to a fixed topic in rocketmq, and then a consumer is created to consume the messages in this topic, which can preliminarily achieve real-time monitoring of data from different business databases.

[0081] For the case information that needs to be synchronized, the flink-cdc plug-in is used to perform the following: When serializing the case information, the flink-cdc plug-in creates fields to store the attribute information of the business system database. The attribute information includes database, schema, table, and operate information. The source and type of the case information are determined based on the attribute information. The data structure of the case information is converted based on the source and type of the case information. The type of operation on the data that needs to be synchronized is determined based on the operate information. The operation types include adding, modifying, and deleting, and structured case information is obtained.

[0082] In the consumer, for the data in the topic, flink-cdc will have special fields to store the database, schema, table and operation information of the database when serializing the information. This part of information can be used to determine which processing system the received data belongs to, and whether its data type is processing, process, special procedure, or material, and then perform the corresponding data structure conversion. After the conversion, the type of operation on the data can be determined based on the operation information, and the operation types include addition, deletion, and modification. Then, when the structured information is persisted, the corresponding operation can be performed to ensure the consistency and real-time synchronization of the monitoring data and the business system data.

[0083] Supervision rules can be divided into five aspects of abnormalities: time limit abnormalities, process abnormalities, content abnormalities, discretion abnormalities, and corruption risk point abnormalities. Each aspect can be specifically subdivided into different abnormalities (e.g., time limit abnormalities can be divided into: in-process case timeout abnormalities, completed case timeout abnormalities, in-process case warning abnormalities, etc.), so a separate table needs to be set for abnormal rules, which should at least contain id, supervision rule name, supervision rule classification, supervision rule specific content, and supervision rule code.

[0084] The monitoring rule code is the code corresponding to a specific monitoring rule, that is, the different keys in the monitoring result information rulesFlag, which are used to identify the specific triggering rules for handling cases; the specific content of the monitoring rule includes how to calculate the data for this rule and what conditions are met to trigger this rule (such as the overtime rule: determine whether the calculated time exceeds the promised completion time for the calculated case. If so, it is determined that the case triggers this rule).

[0085] As an improvement, in this embodiment, the monitoring module includes a monitoring data synchronization module, a monitoring data calculation module and a monitoring timing calculation module. Correspondingly, the calculation topics in the RocketMQ component include data calculation topics corresponding to the monitoring data calculation module and timing calculation topics corresponding to the monitoring timing calculation module.

[0086] The monitoring data synchronization module is used to perform the following: after receiving the structured case information pushed by its subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the case information, and sends calculation messages to the data calculation topic in the RocketMQ component.

[0087] The monitoring data calculation module is used to perform the following: after receiving the data calculation message pushed by the subscribed data calculation topic, it reads the corresponding case information from the monitoring database based on the case number specified in the data calculation message, and performs rule calculation on the case process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires scheduled calculation based on the case status and the monitoring rules that have been triggered. If scheduled calculation is required, a scheduled calculation message is sent to the scheduled calculation topic.

[0088] The monitoring timed calculation module is used to perform the following: after receiving the timed calculation message pushed by the subscribed timed calculation topic, it reads the corresponding case information and case result information from the monitoring database and the monitoring ES search engine based on the case number specified in the timed calculation message, and performs timed monitoring and calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires timed calculation based on the case status and the monitoring rules that have been triggered. If timed calculation is required, a timed calculation message is sent to the timed calculation topic.

[0089] The system of this embodiment needs to obtain the handling information for the synchronized structured data and perform calculations according to the corresponding monitoring rules. This calculation time can be divided into three categories: synchronization, calculation and scheduled calculation.

[0090] When there is data update, calculations need to be performed based on the latest case information to ensure the timeliness and accuracy of the calculation results. For this type of calculation, create a calculation topic in RocketMQ, and send a message to this calculation topic after the consumer data synchronization is completed. The message contains the case number information of the case, and set up a consumer to subscribe to this calculation topic. After receiving the message each time, the consumer queries the relevant information and monitoring rules of the synchronized case in the persistence layer of this model according to the case number, and then performs the corresponding calculation and persists the calculation results, thereby realizing the calculation function when the data is updated.

[0091] Scheduled calculations, for cases in progress, have rules that are highly time-sensitive (for example, a case in progress may not have timed out in the previous hour, but may have timed out in the next hour). Such cases require scheduled calculations and continuous updating of calculation results. For such calculations, create a scheduled topic in RocketMQ. After the consumer for calculations has calculated the data, determine whether the calculation results need to be calculated on a scheduled basis. If scheduled calculations are required, send a scheduled message to the scheduled topic (the specific timing is determined by the actual scenario). The message body is the same as that of the calculation topic. At the same time, set up a consumer to subscribe to this scheduled topic. This consumer will perform calculations again after receiving a message each time, and determine again whether scheduled calculations are required. If necessary, continue to send scheduled messages to the scheduled topic. If not, do not perform other operations, thereby realizing the function of scheduled calculations.

[0092] The system of this embodiment can complete the functions of synchronization, monitoring and storage of government service data through data synchronization, calculation and timed calculation.

[0093] The present invention has been shown and described in detail above through the accompanying drawings and preferred embodiments. However, the present invention is not limited to these disclosed embodiments. Based on the above multiple embodiments, those skilled in the art can know that the means in the above different embodiments can be combined to obtain more embodiments of the present invention, and these embodiments are also within the protection scope of the present invention.

Claims

1. A method for synchronizing and monitoring government data, characterized in that: Applied to the business system database, flink-cdc plug-in, RocketMQ component, monitoring module, monitoring database and monitoring ES search engine, the method includes the following steps: The business system database is monitored through the flink-cdc plug-in. When there are changes in business data in the business system database, the data to be synchronized is read from the business system database as the case information and the case information is structured to obtain structured case information. The structured case information is sent to the data synchronization topic in the RocketMQ component. After the monitoring module receives the structured case information pushed by the data synchronization topic it subscribes to, it persists the structured case information to the monitoring database for storage based on the type of the board information, and sends a calculation message to the calculation topic in the RocketMQ component; After receiving the calculation message pushed by the calculation topic it subscribes to, the monitoring module reads the case information specified by the calculation message from the monitoring database, monitors the case processing process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage; The inspection database provides case information, and the inspection result information is provided through the inspection ES search engine to realize query and statistical services.

2. The government data synchronization and monitoring method according to claim 1, characterized in that: The monitoring module includes a monitoring data synchronization module, a monitoring data calculation module and a monitoring timing calculation module. Correspondingly, the calculation subject in the RocketMQ component includes a data calculation subject corresponding to the monitoring data calculation module and a timing calculation subject corresponding to the monitoring timing calculation module; After the monitoring data synchronization module receives the structured case information pushed by the subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the case information, and sends a calculation message to the data calculation topic in the RocketMQ component. After receiving the data calculation message pushed by the subscribed data calculation topic, the monitoring data calculation module reads the corresponding case information from the monitoring database based on the case number specified in the data calculation message, and performs rule calculation on the case process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case needs timed calculation based on the case status and the monitoring rules that have been triggered by the case. If timed calculation is required, a timed calculation message is sent to the timed calculation topic; After the monitoring timed calculation module receives the timed calculation message pushed by the subscribed timed calculation topic, it reads the corresponding case information and case result information from the monitoring database and the monitoring ES search engine based on the case number specified in the timed calculation message, and performs timed monitoring and calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires timed calculation based on the case status and the monitoring rules that have been triggered. If timed calculation is required, a timed calculation message is sent to the timed calculation topic.

3. The government data synchronization and monitoring method according to claim 1 or 2, characterized in that: Based on the type of case handling information, the case handling information includes case handling information, case handling process information, case handling result information, special procedure information and material catalog information, wherein the case handling information, case handling process information, case handling result information, special procedure information and material catalog information are mapped based on the plate number; The case handling process information, special procedure information and material catalog information are stored in the supervision database; The case handling information and case handling result information are stored in the ES search engine. The ES search engine is configured with an object type structure named rulesFlag. RulesFlag is used to store the inspection result information. The inspection rules exist in the form of inspection rule name key in rulesFlag. An exception rule table is formed based on the configured monitoring rules. The exception rule table includes id, monitoring rule name, monitoring rule category and monitoring rule code. The monitoring rule code is a different key in rulesFlag. Abnormal rules are divided into time limit abnormalities, process abnormalities, content abnormalities, discretionary abnormalities and corruption risk point abnormalities.

4. The government data synchronization and monitoring method according to claim 1 or 2, characterized in that: For the case information that needs to be synchronized, when the flink-cdc plug-in serializes the case information, the flink-cdc plug-in creates fields to store the attribute information of the business system database. The attribute information includes database, schema, table and operation information. The source and type of the case information are determined based on the attribute information. The data structure of the case information is converted based on the source and type of the case information. The type of operation on the data that needs to be synchronized is determined based on the operation information. The operation types include addition, modification and deletion, and structured case information is obtained.

5. A government data synchronization and monitoring system, characterized in that: Including flink-cdc plug-in, RocketMQ component, monitoring module, monitoring database and monitoring ES search engine; The flink-cdc plug-in is used to perform the following: monitor the business system database. When there are changes in business data in the business system database, read the data that needs to be synchronized from the business system database as the case information and perform structured processing on the case information to obtain structured case information, and send the structured case information to the data synchronization topic in the RocketMQ component; The monitoring module is used to perform the following: after receiving the structured case information pushed by the data synchronization topic it subscribes to, it persists the structured case information to the monitoring database for storage based on the type of the board information, and sends a calculation message to the calculation topic in the RocketMQ component; After receiving the calculation message pushed by the calculation topic it subscribes to, it reads the case information specified by the calculation message from the monitoring database, monitors the case processing process based on the pre-configured monitoring rules, and pushes the obtained monitoring result information to the monitoring ES search engine for storage; The monitoring database and the monitoring ES search engine provide query and statistical services for case handling information and monitoring result information.

6. The government data synchronization and monitoring system according to claim 5, characterized in that: The monitoring module includes a monitoring data synchronization module, a monitoring data calculation module and a monitoring timing calculation module. Correspondingly, the calculation subject in the RocketMQ component includes a data calculation subject corresponding to the monitoring data calculation module and a timing calculation subject corresponding to the monitoring timing calculation module; Correspondingly, the monitoring data synchronization module is used to perform the following: after receiving the structured case information pushed by its subscribed data synchronization topic, it persists the structured case information to the monitoring database for storage based on the type of the case information, and sends a calculation message to the data calculation topic in the RocketMQ component. The monitoring data calculation module is used to perform the following: after receiving the data calculation message pushed by the subscribed data calculation topic, it reads the corresponding case information from the monitoring database based on the case number specified in the data calculation message, and performs rule calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case needs timed calculation based on the case status and the monitoring rules that have been triggered by the case. If timed calculation is required, a timed calculation message is sent to the timed calculation topic; The monitoring timed calculation module is used to perform the following: after receiving the timed calculation message pushed by the subscribed timed calculation topic, it reads the corresponding case information and case result information from the monitoring database and the monitoring ES search engine based on the case number specified in the timed calculation message, and performs timed monitoring and calculation on the case process based on the pre-configured monitoring rules, pushes the obtained monitoring result information to the monitoring ES search engine for storage, and determines whether the case requires timed calculation based on the case status and the monitoring rules that have been triggered. If timed calculation is required, a timed calculation message is sent to the timed calculation topic.

7. The government data synchronization and monitoring system according to claim 5 or 6, characterized in that: Based on the type of case handling information, the case handling information includes case handling information, case handling process information, case handling result information, special procedure information and material catalog information, wherein the case handling information, case handling process information, case handling result information, special procedure information and material catalog information are mapped based on the plate number; The case handling process information, special procedure information and material catalog information are stored in the supervision database; The case handling information and case handling result information are stored in the ES search engine. The ES search engine is configured with an object type structure named rulesFlag. RulesFlag is used to store the inspection result information. The inspection rules exist in the form of inspection rule name key in rulesFlag. An exception rule table is formed based on the configured monitoring rules. The exception rule table includes id, monitoring rule name, monitoring rule category and monitoring rule code. The monitoring rule code is a different key in rulesFlag. Abnormal rules are divided into time limit abnormalities, process abnormalities, content abnormalities, discretionary abnormalities and corruption risk point abnormalities.

8. The government data synchronization and monitoring system according to claim 5 or 6, characterized in that: For the case information that needs to be synchronized, when the flink-cdc plug-in serializes the case information, the flink-cdc plug-in creates fields to store the attribute information of the business system database. The attribute information includes database, schema, table and operation information. The source and type of the case information are determined based on the attribute information. The data structure of the case information is converted based on the source and type of the case information. The type of operation on the data that needs to be synchronized is determined based on the operation information. The operation types include addition, modification and deletion, and structured case information is obtained.

Citation Information

Patent Citations

  • Government affair appointment item correlation retrieval method

    CN112269816A

  • Supervision method and supervision system for hospital treatment data

    CN114360712A

  • Government affair data monitoring method based on combination of canal, mq and es

    CN116775730A

  • Data synchronization method based on Rocket MQ

    CN117056422A

  • Method, device, and server for processing supervision information, and storage medium

    WO2019041859A1

Cited By

  • Government affair data information monitoring method based on government affair data monitoring model

    CN120687511A