Airflow-based metadata integration and management system and working method
Through the Airflow-based metadata management system, the unified adaptation of relational databases is solved, and the complexity and stability of the business platform's adaptation to the database is achieved, and the metadata management with high stability and security is achieved.
Patent Information
- Application Number
- CN202411127715.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-16
- Publication Date
- 2024-11-29
AI Technical Summary
Under the traditional method, each business platform needs to independently adapt to various relational databases to obtain metadata, resulting in high complexity, poor application stability, and affect OLTP operations under database pressure, resulting in unstability in the business system.
Based on Airflow's integrated metadata management system, it provides a unified interface and entity model, obtains metadata through API, integrates service checksum to perform integration tasks, reduces the adaptation complexity of the business platform to the database, and protects the database by obtaining metadata regularly. stability.
It realizes the unified acquisition of metadata for various business platforms, improves application stability and database security, reduces database pressure, and ensures the stable operation of the business system.
Smart Images

Figure CN119046356A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a metadata and metadata management system, and in particular to an Airflow-based metadata integration and metadata management system and a working method. Background Art
[0002] Metadata is data that describes data, mainly information that describes the attributes of data. An efficient and reliable metadata management system can effectively manage big data, thereby making reasonable and full use of big data and solving problems encountered in the use of big data.
[0003] like Figure 1 As shown, in the traditional way, each business platform needs to independently adapt to various relational databases to obtain parsing metadata, which has the following problems: because each business platform is an independent system, the development environment, language, and version used may be different. In this case, it is necessary to independently adapt to various relational databases, and the adaptation complexity is large; the metadata obtained by the business platform is the latest. If there is a change in the database table, the business platform will obtain the changed metadata. In this case, most of the logic that relies on metadata for operations will be wrong, and the application stability will be poor; when the number of business platforms is large and the concurrency is high, a large number of database connections will be occupied, which will cause great pressure on the database and even affect the operation of OLTP, causing instability in the business system. Summary of the invention
[0004] In view of the problems existing in the above-mentioned prior art, the present invention provides a metadata integration and management system and working method based on Airflow, provides a unified metadata acquisition interface for each business system, and defines a unified entity model. Each business platform no longer needs to adapt to various relational databases to obtain metadata, nor does it need to adapt to the differences in metadata information of various databases; the complexity of each business platform is reduced, the stability of the business platform is improved; and the stability and security of the database are effectively protected.
[0005] In order to achieve the above object, the technical solution adopted by the present invention is: integrating metadata and managing metadata system based on Airflow, including: Business platform: metadata information in the metadata management platform can be obtained through APIs, regardless of the database type; Metadata management platform: provides a unified external API and defines a unified entity model for metadata; configures the connection information and configuration information of various relational data sources, and issues integration tasks to integration services; Integration service: used to verify whether the integration tasks published by the metadata management platform are correct; Integration task: execute the integration task and retrieve the corresponding information in the corresponding database. Database: Integrate metadata of multiple relational databases.
[0006] Furthermore, the integration service is an integration service based on the open source component Airflow.
[0007] Furthermore, the working method of integrating metadata and managing the metadata system based on Airflow includes the following steps: Step 1: Start the metadata management platform and integration services; Step 5: The metadata management platform configures connection information and other configuration information of various relational data sources; Step 3: The metadata management platform sends the integration task to the integration service; Step 4: The integration service verifies whether the integration task is correct. If correct, the integration task is placed in the task queue and waits for execution. If wrong, the metadata management platform is informed of the reason for the task error. Step 5: Integration task execution; Step 6: Each business platform obtains metadata information uniformly through HTTP.
[0008] Furthermore, the step 5 is specifically: Step 5.1, obtain metadata information and parse it into a unified entity model defined by the metadata management platform; Step 5.2, determine whether the current entity table exists in the metadata management platform. If it exists, obtain the latest entity model EM2 of the current entity model EM1 in the metadata management platform, compare EM1 and EM2, if EM1 is equal to EM2, then mention the integration of the entity model, if EM1 is not equal to EM2, then record the changed content in the EM2 entity model, and pass EM2 to the next step; if the current entity model does not exist in the metadata management, then directly pass the current entity model to the next step; Step 5.3: Transfer the entity model from the previous step to the metadata management platform.
[0009] The beneficial effects of the present invention are: (1) The integrated service is used to adapt to the data sources of various relational databases. A three-tier architecture is defined for the relational database. The metadata management platform provides a unified API to publish metadata information of various data sources. Each business platform only needs to obtain metadata information through the API, regardless of the database type. (2) Each time the integration service obtains metadata information, it will compare it with the latest version of metadata information currently saved by the metadata platform. If there is any inconsistency, a new version will be inserted. The business platform uses different versions of metadata according to needs, and the application has high stability. (3) The metadata of each relational data source is obtained at regular intervals and closed after use. The time for obtaining metadata can be set to the time when the database is idle, which will protect the stability of the database. BRIEF DESCRIPTION OF THE DRAWINGS
[0010] Figure 1 It is a structural schematic diagram of the background technology; Figure 2 It is a structural schematic diagram of the present invention. DETAILED DESCRIPTION
[0011] In order to make the purpose, technical solution and advantages of the present invention more clear, the present invention is further described in detail below through the accompanying drawings and embodiments. However, it should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the scope of the present invention.
[0012] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by technicians in the technical field to which the present invention belongs. The terms used in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention.
[0013] like Figure 2 As shown, metadata is integrated and managed based on Airflow, including: Business platform: metadata information in the metadata management platform can be obtained through APIs, regardless of the database type; Metadata management platform: provides a unified external API and defines a unified entity model for metadata; configures the connection information and configuration information of various relational data sources, and issues integration tasks to integration services; Integration service: used to verify whether the integration tasks published by the metadata management platform are correct; Integration task: execute the integration task and retrieve the corresponding information in the corresponding database. Database: Integrate metadata of multiple relational databases.
[0014] The integration service is based on the open source component Airflow. The working method of integrating metadata and managing the metadata system based on Airflow includes the following steps: Step 1: Start the metadata management platform and integration services; Step 5: The metadata management platform configures connection information and other configuration information of various relational data sources; Step 3: The metadata management platform sends the integration task to the integration service; Step 4: The integration service verifies whether the integration task is correct. If correct, the integration task is placed in the task queue and waits for execution. If wrong, the metadata management platform is informed of the reason for the task error. Step 5: Integration task execution; Step 6: Each business platform obtains metadata information uniformly through HTTP.
[0015] Furthermore, the step 5 is specifically: Step 5.1, obtain metadata information and parse it into a unified entity model defined by the metadata management platform; Step 5.2, determine whether the current entity table exists in the metadata management platform. If it exists, obtain the latest entity model EM2 of the current entity model EM1 in the metadata management platform, compare EM1 and EM2, if EM1 is equal to EM2, then mention the integration of the entity model, if EM1 is not equal to EM2, then record the changed content in the EM2 entity model, and pass EM2 to the next step; if the current entity model does not exist in the metadata management, then directly pass the current entity model to the next step; Step 5.3: Transfer the entity model from the previous step to the metadata management platform.
[0016] The database is MySQL, Postgres, Oracle, SQLServer, and other relational databases.
[0017] The underlying layer of the integration service is implemented based on a scheduled task framework. In theory, any open source scheduled task framework on the market can implement this service, such as Quartz, Spring Task, xxl-job, etc. The integration service implements metadata extraction logic for multiple relational databases.
[0018] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modification, equivalent substitution or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. Integrate metadata and manage metadata system based on Airflow, characterized by: include: Business platform: metadata information in the metadata management platform can be obtained through APIs, regardless of the database type; Metadata management platform: provides a unified external API and defines a unified entity model for metadata; configures the connection information and configuration information of various relational data sources, and issues integration tasks to integration services; Integration service: used to verify whether the integration tasks published by the metadata management platform are correct; Integration task: execute the integration task and retrieve the corresponding information in the corresponding database. Database: Integrate metadata of multiple relational databases.
2. The system for integrating and managing metadata based on Airflow according to claim 1, characterized in that: The integration service is an integration service based on the open source component Airflow.
3. The working method for integrating metadata and managing metadata system based on Airflow according to claim 2, characterized in that: The steps include: Step 1: Start the metadata management platform and integration services; Step 5: The metadata management platform configures connection information and other configuration information of various relational data sources; Step 3: The metadata management platform sends the integration task to the integration service; Step 4: The integration service verifies whether the integration task is correct. If correct, the integration task is placed in the task queue and waits for execution. If wrong, the metadata management platform is informed of the reason for the task error. Step 5: Integration task execution; Step 6: Each business platform obtains metadata information uniformly through HTTP.
4. The working method for integrating metadata and managing metadata system based on Airflow according to claim 3 is characterized in that: The step 5 is specific as follows: Step 5.1, obtain metadata information and parse it into a unified entity model defined by the metadata management platform; Step 5.2, determine whether the current entity such as the table exists in the metadata management platform. If it does, obtain the latest entity model EM2 of the current entity model EM1 in the metadata management platform, compare EM1 and EM2, if EM1 is equal to EM2, then mention the integration of the entity model, if EM1 is not equal to EM2, then record the changed content in the EM2 entity model, and pass EM2 to the next step; If the current entity model does not exist in the metadata management, the current entity model is directly passed to the next step; Step 5.3: Transfer the entity model from the previous step to the metadata management platform.
Citation Information
Cited By
Metadata intelligent driving-based data integration system
CN121935481A
