A heterogeneous data integration and query system and method based on RDF

Through the RDF-based heterogeneous data integration and query system, the syntax and semantic heterogeneity of heterogeneous data sources are eliminated, and the pattern mapping and optimization algorithms are used to solve the problem of inefficient heterogeneous data processing, and efficient data integration and query are achieved. , improves the efficiency of semantic interoperability.

CN114297224BActive Publication Date: 2024-11-26GUIZHOU XIAOQI TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111579722.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-22
Publication Date
2024-11-26
Estimated Expiration
2041-12-22

AI Technical Summary

Technical Problem

The prior art is inefficient when processing heterogeneous data, has high memory consumption of computers, and cannot effectively solve the semantic heterogeneity problem of heterogeneous data sources, resulting in ambiguity in semantic processing.

Method used

Using a heterogeneous data integration and query system based on RDF, the heterogeneous data source is described through RDF Schema to eliminate syntax and semantic heterogeneity; using the pattern mapping of Global Schema and Local Schema, combined with Turtle and ontology technology, a virtual view is established to Reduce direct operation of the underlying data source; use the improved Cost-Based Optimization algorithm to optimize query statements, and add data converters and cache systems to improve query efficiency.

Benefits of technology

It realizes efficient integration and query of heterogeneous data sources, reduces query time and computer resource consumption, ensures that the data format meets expectations, and improves the efficiency of semantic interoperability and the basis of data sharing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114297224B_ABST
    Figure CN114297224B_ABST
Patent Text Reader

Abstract

The present invention claims protection for a heterogeneous data integration and query system and method based on RDF, which belongs to the field of combining heterogeneous data integration with data semantic processing technology, including: original data layer, data encapsulation layer, semantic layer, data query layer and application layer, the original data layer transmits structured data or unstructured data in the heterogeneous database to the data encapsulation layer, the data encapsulation layer transmits the encapsulated data to the semantic layer, the semantic layer transmits the data after semantic processing to the data query layer, and the data query layer transmits the data to the application layer. For this architecture, based on the current laboratory experimental conditions, a computer with an i5‑8400 processor, 20G memory, and 1T hard disk is used as an experimental platform. The designed heterogeneous data integration and query system and method can reduce the occupation of computer resources and greatly reduce the response time of data query. The data content and format finally obtained by the present invention are consistent with expectations, proving that the system and method proposed in the present invention are feasible.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of combining heterogeneous data integration with data semantic processing technology, and relates to a heterogeneous data integration and query system and method based on RDF. Background Art

[0002] The Internet of Things system often generates a large amount of heterogeneous data during work. Giving these data a meaning that can be understood by the machine is the main means to solve the incompatibility of heterogeneous data. However, when giving meaning to data, semantic heterogeneity often occurs, resulting in differences in the interpretation of the same thing, which is reflected in the different understandings of the same thing in different fields. In order to solve the problems caused by this heterogeneity, a large number of different types of solutions have emerged, which have greatly changed the communication between Internet of Things systems, data exchange and the extraction of semantic knowledge. At present, there are many types of semantic models, each with its own characteristics, coexisting and developing. The basis of these models includes ontology, middleware, semantic web, especially based on ontology, including oneM2M, semantic sensor network (SSN) ontology, WSSN, contextual ontology CANON, IOT-Lite, M3 ontology, etc. However, these technologies often do not have a unified data source format as a result return when using data, resulting in ambiguity in semantic processing. In order to better use data in semantic interoperability work, the present invention can be used as the first step of semantic interoperability, that is, to perform relevant processing on heterogeneous data.

[0003] After searching, the application publication number CN107895046B, a heterogeneous data integration platform, is used to seamlessly connect various heterogeneous data sources. The platform includes an application system, a virtual data layer and a data source layer. The application system is used to connect to the access interface and manage various node data sources through the virtual data layer; the virtual data layer is used to integrate and manage several distributed, independent heterogeneous data sources; the data source layer is used to receive heterogeneous data sources. The present invention provides a heterogeneous data integration platform, which divides the platform into an application system, a virtual data layer and a data source layer, seamlessly connects various heterogeneous data sources, and uses an abstract object method to shield the underlying differences of various data sources from the upper application system. This technology directly operates on the underlying data source, extracts various heterogeneous data to establish a virtual data layer, and directly operates the virtual data layer, which is inefficient and consumes a lot of computer memory. In view of this, the present invention adds a time cost optimization algorithm for each heterogeneous data source to calculate the cost of the query statement before querying and optimize it to the optimal query statement, which can greatly reduce the query time and computer resources; in addition, the present invention maps different data sources locally and overall, shields the differences in the underlying data sources, and uses ontology mapping technology for querying, which is much more efficient than directly operating the underlying data source, and a data converter is added in the present invention, so that the query data format fully meets the expectations of the technicians.

[0004] Application publication number CN110046280A, a multi-station surveillance video semantic retrieval system for random inspection, belongs to the field of video data processing and semantic Web technology. The overall architecture of the system includes: raw data layer, data processing layer, semantic layer, service layer and application layer. The raw data layer includes surveillance videos of each station on the production line and a sample video library for training. The data processing layer includes a sample video processing module and a surveillance video processing module. The semantic layer includes a video semantic annotation module, a video information semanticization module, a video domain knowledge ontology model, a semantic reasoning and query module, an ontology database and a semantic rule file. The service layer includes a video query service and a permission detection service. The application layer includes a video retrieval module, a video playback module and a user permission module. The present invention can perform semantic retrieval on the surveillance videos of each station on a certain product production line in random inspection, thereby improving the efficiency of random inspection. The technology realizes unified data processing at the bottom layer, cannot process heterogeneous data sources, and establishes all data ontology and puts it into the ontology library. When encountering heterogeneous data, the system cannot operate normally. The present invention maps heterogeneous data sources through ontology mapping technology, and can complete query conversion between different data during query. Summary of the invention

[0005] The present invention aims to solve the problem of low efficiency in processing massive data in the above prior art. A heterogeneous data integration and query system and method based on RDF is proposed. The technical solution of the present invention is as follows:

[0006] A heterogeneous data integration and query system and method based on RDF, comprising: an original data layer, a data encapsulation layer, a semantic layer, a data query layer and an application layer, wherein the original data layer transmits structured data or unstructured data in a heterogeneous database to the data encapsulation layer, the data encapsulation layer transmits the encapsulated data to the semantic layer, the semantic layer transmits the semantically processed data to the data query layer, and the data query layer transmits the data to the application layer, wherein:

[0007] The original data layer uses RDF Schema (Resource Description Framework) to describe different data sources, eliminating the syntax heterogeneity of heterogeneous data sources; and analyzes the relational table structure and semantics in the data source to eliminate the semantic heterogeneity of heterogeneous data sources;

[0008] The data encapsulation layer includes a web service and a data encapsulation module; the data encapsulation module is divided into a query converter and a result converter. The query converter converts the subquery into a subquery recognizable by the corresponding database according to different underlying databases; the result converter obtains different query results according to different subqueries, and then converts the query processing results into a format to generate a file in RDF data format;

[0009] The semantic layer includes Global Schema and Local Schema, as well as the schema mapping between the two schemas; the Global Schema first constructs a global ontology, then makes a semantic description of the global virtual view, and finally makes it unnecessary to query the underlying heterogeneous data source during the query process through the virtual view; the process of constructing Local Schema is the semantic description of the heterogeneous data source, and RDF can be serialized through Turtle to complete the schema creation. The Turtle document consists of a series of instructions, triple statements or blank lines;

[0010] The data query layer mainly processes user requests, including request optimization, result caching, and data source packaging; the query language used is SPARQL or SQL

[0011] The application layer includes web interface, management interface and other interfaces.

[0012] Furthermore, the triples of the semantic layer are a sequence of (subject, predicate, object) items separated by spaces and ending with '.' after each triple. There are three types of RDF terms: RDF URI references, text, and blank nodes. The corresponding local ontology and global ontology are established according to the underlying heterogeneous data source data types through RDF, and then schema mapping is performed to achieve interoperability, wherein the schema mapping is the mapping of Local Schema to Global Schema.

[0013] Furthermore, the mapping from Local Schema to Global Schema is performed by adopting an intermediate mapping method, that is, the Local Schema is first mapped into files described by RDF, and then these description files are mapped to the Global Schema. The mapping mode of the former is 1:1, and the mapping mode of the latter is n:1. It is a description model of public data, which is described by Turtle and ontology technology. The intermediate state of this mapping method belongs to the virtual view of the data source, rather than the real existence.

[0014] Furthermore, the data query layer includes a query cost optimization module, a selection and replication module, a query execution module, and a result cache module; wherein the query cost optimization module is used to calculate the query cost of the query statement and optimize it into a minimum cost query, and this process can obtain a cost planning document for query execution; the selection and replication module is used to replicate part of the query data as hot data; the query execution module is mainly responsible for the execution of the query plan, and when a request is issued, the processed result is returned to the query execution module; the result cache module caches the hot data to a specified memory space to facilitate subsequent queries, shorten the response time, and return the query results to the application layer in the format desired by the user.

[0015] Furthermore, the query cost optimization module obtains the expected result through SPARQL statements; firstly, a SPARQL query statement is generated; secondly, the query statement is processed to analyze the sub-query statement of the corresponding data source; and then, the time cost of the query statement is calculated through the improved Cost-Based Optimization algorithm to obtain the cost planning document of the query execution.

[0016] Furthermore, the improved Cost-Based Optimization algorithm requires the use of the script tool Preanalyze; the algorithm operation is as follows:

[0017] (1) First generate the ANALYZE statement to enable the algorithm, SET hive.cbo.enable = TRUE;

[0018] (2) Use / preanalyze.sh -f to analyze SPARQL statements, analyze different database query statement files according to the underlying database files, obtain statistical information and execute the files;

[0019] (3) After obtaining the analysis file, execute the / preanalyze.sh -d statement and / (database file suffix)s-imy.conf statement.

[0020] A heterogeneous data integration and query system and method based on any of the above systems, comprising the following steps:

[0021] The original data layer uses RDF Schema (Resource Description Framework) to describe different data sources and eliminate the syntax heterogeneity of heterogeneous data sources; it analyzes the relational table structure and semantics in the data source and eliminates the semantic heterogeneity of heterogeneous data sources;

[0022] The query converter converts the subquery into a subquery that can be recognized by the corresponding database according to the different underlying databases; the result converter obtains different query results according to different subqueries, and then converts the query processing results into a file in RDF data format;

[0023] The Global Schema first builds a global ontology, then makes a semantic description of the global virtual view, and finally uses the virtual view to avoid querying the underlying heterogeneous data sources during the query process. The process of building the Local Schema is the semantic description of the heterogeneous data sources. The RDF can be serialized through Turtle to complete the schema creation. The Turtle document consists of a series of instructions, triple statements or blank lines.

[0024] The data query layer implements the processing of user requests, including request optimization, result caching, and data source packaging; the query language used is SPARQL or SQL.

[0025] The advantages and beneficial effects of the present invention are as follows:

[0026] (1) Use RDF Schema to uniformly describe different data sources to eliminate the syntactic heterogeneity of heterogeneous data sources. Use Turtle to describe the ontology to eliminate the semantic heterogeneity of heterogeneous data sources.

[0027] (2) A heterogeneous data integration solution based on the RDF format is proposed. It is usually used to exchange, read and understand data between heterogeneous systems, such as the timetable of a Web page or the same meaning expression of industrial heterogeneous data. RDF documents are written in XML. By using XML, RDF information can be easily exchanged between computers using different types of operating systems and application languages. This lays the foundation for semantic interoperability.

[0028] (3) Utilize ontology knowledge and shared concept terms to achieve mapping from Local Schema to Global Schema and solve mapping problems in data integration.

[0029] (4) According to claim 6, the Cost-Based Optimization algorithm is improved so that it can optimize SQL query statements and support SPARQL query optimization, and finally obtain different costs according to different databases, and select the execution plan with the minimum cost and the highest accuracy for query. The advantage of the improved Cost-Based Optimization algorithm is that it can optimize different time costs of heterogeneous data sources, rather than being limited to one data source, and solve the current query cost problem of heterogeneous data sources.

[0030] (5) Add a cache system to data query to implement hot data caching. The cache algorithm selected for different businesses is different.

[0031] (6) Existing data queries are basically directly based on databases, and a few of them operate on data. The present invention operates on data based on RDF, laying a solid foundation for future semantic interoperability work. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Figure 1 The present invention provides a preferred embodiment of the heterogeneous data integration and query method based on RDF.

[0033] Figure 2 Query flow chart of data query layer DETAILED DESCRIPTION

[0034] The following will describe the technical solutions in the embodiments of the present invention in detail in conjunction with the accompanying drawings in the embodiments of the present invention. The described embodiments are only part of the embodiments of the present invention.

[0035] The technical solution of the present invention to solve the above technical problems is:

[0036] The present application implements a heterogeneous data integration and query system and method based on RDF, the architecture diagram is as follows: Figure 1 As shown in the figure, the overall architecture includes: raw data layer, data encapsulation layer, semantic layer, data query layer, and application layer. The raw data layer includes data sources in various databases or different data sources in the same database. The data encapsulation layer includes formatting and encapsulating heterogeneous data and displaying it on the front-end page. The semantic layer includes mapping of three modes. The data query layer includes optimization of data query statements after rewriting and storage of query results. The application layer includes web interfaces and management interfaces for various industries. This method is a heterogeneous data integration and query platform developed for different industries, which will promote the scientific development of related industries and provide a basis for semantic interoperability research.

[0037] in:

[0038] The original data layer includes data sources of various heterogeneous databases. The data sources have grammatical or semantic heterogeneity. In order to eliminate the heterogeneity, relevant technologies are needed to process the heterogeneous data sources. RDF Schema is used to describe different data sources to eliminate the grammatical heterogeneity of heterogeneous data sources. The relationship table structure and semantics in the data source are analyzed to construct Global Schema and Local Schema. Through the mapping of these two relationship modes, the semantic heterogeneity of heterogeneous data sources is eliminated.

[0039] The data encapsulation layer includes web services and data encapsulation modules; the data encapsulation module is divided into a query converter and a result converter. The query converter converts the subquery into a subquery that can be recognized by the corresponding database according to the different underlying databases; the result converter obtains different query results according to different subqueries, and then converts the query processing results into a format to generate a file in RDF data format;

[0040] The semantic layer includes Global Schema and Local Schema and the schema mapping between the two modes; Global Schema needs to establish a global ontology to provide a unified semantic description and complete the transition from the domain to the semantic level. First, a global ontology is constructed, and then a semantic description of the global virtual view is made. Finally, the virtual view is used to avoid querying the underlying heterogeneous data source during the query process; the process of constructing Local Schema is the semantic description of the heterogeneous data source. RDF can be serialized through Turtle to complete the schema creation. Turtle documents are composed of a series of instructions, triple statements or blank lines. A simple triple is a sequence of (subject, predicate, object) items separated by spaces and ended by '.' after each triple. There are three types of RDF terms: RDF URI references (URIs for short), text, and blank nodes; schema mapping is the mapping from Local Schema to Global Schema. The present invention uses an intermediate mapping method to perform schema mapping, that is, first mapping Local Schema into files described by RDF, and then mapping these description files to Global Schema. The former mapping mode is 1:1, and the latter mapping mode is n:1. It is a description model of public data, which is described by Turtle and ontology technology. The mapping method is characterized in that the intermediate state belongs to the virtual view of the data source, rather than the real existence.

[0041] The service data query layer includes a query cost optimization module, a selection replication module, a query execution module, and a result cache module; this layer mainly implements the processing of user requests, including optimization of requests, caching of results, and packaging of data sources, etc. The query language used is SPARQL or SQL. Among them, the query cost optimization module is used to calculate the query cost of the query statement and optimize it into a minimum cost query. This process can obtain the cost planning document for query execution; the selection replication module can copy part of the query data as hot data; the query execution module is mainly responsible for the execution of the query plan, and when the request is issued, the processed result is returned to the query execution module; the result cache module caches the hot data to the specified memory space to facilitate later queries, shorten the response time, and return the query results to the application layer in the format desired by the user.

[0042] The application layer includes web interface, management interface and other interfaces.

[0043] The heterogeneous data in the original data layer are divided into heterogeneous databases, including but not limited to MYSQL, SQLServer, ..., Oracle, and the heterogeneous data include structured data and unstructured data.

[0044] The query converter and result converter of the data encapsulation layer specifically include: query conversion, request initiation, request processing, and request response, wherein the result converter needs to convert the query results into RDF format.

[0045] The Global Schema and Local Schema of the semantic layer and the schema mapping between the two modes, where Local Schema is the relevant data source of the underlying database system, such as the underlying heterogeneous data MYSQL, SQLServer, ..., Oracle, and this mode is a heterogeneous mode; the intermediate format file of the file is mapped from the Local Schema, and the file is expressed in RDF format, and the intermediate file is mapped to the Global Schema, and this process is an inter-object process. In this process, it is necessary to map by establishing an ontology, and use Turtle to describe the ontology, retain data integrity, and solve the problem of data heterogeneity.

[0046] The data query layer mainly obtains the expected results through SPARQL statements. First, a SPARQL query statement is generated; second, the query statement is processed and the sub-query statement of the corresponding data source is analyzed; then, the time cost of the query statement is calculated through the improved Cost-Based Optimization algorithm to reduce the time and CPU performance cost during the query process and obtain the query time planning document;

[0047] The improved Cost-Based Optimization algorithm requires the use of the script tool Preanalyze;

[0048] (1) First generate the ANALYZE statement to enable the algorithm, SET hive.cbo.enable = TRUE;

[0049] (2) Use / preanalyze.sh -f to analyze SPARQL statements. According to the different underlying database files, analyze different database query statement files, obtain statistical information and execute the files.

[0050] (3) After obtaining the analysis file, execute the / preanalyze.sh -d statement and / (database file suffix)s-imy.conf statement.

[0051] (4) According to the comparison of the results, it can be found that the algorithm effectively removes repeated query statements in the file and removes objects that are analyzed multiple times, reducing computer resource overhead and improving query efficiency.

[0052] Reduced query time.

[0053] The application scenario of this example is based on the implementation of geographic information integration application, as shown in Table 1, Table 2, and Table 3. Figure 1 As shown in the architecture diagram, due to heterogeneous databases, there are heterogeneous problems in data syntax and semantics. It is necessary to eliminate these two heterogeneities and return data in RDF format uniformly. Use RDF Schema to describe Table 1 and Table 2, and then use RDF Schema to describe Table 2 and Table 3. This can solve the heterogeneity between the syntax of heterogeneous data sources; use Turtle associated data to express the ontology, unify the data in Table 1, Table 2 and Table 3 under the global mode, and describe the mapping from the local mode to the global mode through RDF Schema and ontology technology. For example, in Table 1, Table 1.NAME = Global.MARK; for Table 2 and Table 3, the two tables are mapped after merging the data, so the attributes in Table 2 can be mapped to many data in Table 3. Table 2 and Table 3 can both be mapped to the global mode, and Table 1, Table 2 and Table 3 can also be mapped to each other. At this point, the construction of the semantic module is completed.

[0054] Furthermore, we construct a data query layer, which receives user query requests and processes them. Figure 2 As shown, first, the user submits a global query with demand, and the grammatical heterogeneity of heterogeneous data is eliminated through SPARQL description, and then the correct global query is generated through RDF Schem. Secondly, according to the complexity of the query statement, the entire query statement is decomposed into sub-queries, and then passed up in sequence. After the decomposition is completed, each sub-query is queried for cost, and each sub-query is optimized using an optimization algorithm to achieve the purpose of optimizing the global query. After the optimization is completed, the global query statement is processed for data source, the queried data is processed for result, and an LRU algorithm is designed to cache the results for the next query to reduce response time and computer resource costs. At this point, the data query layer design is completed.

[0055] The data encapsulation layer is processed using Web Service technology and uses SOAP (Simple Object Access Protocol) lightweight information processing technology to provide software services on the web. First, after the query converter receives the SPARQL subquery, it converts it into different query statements according to the underlying database. For example, for the Mysql database, the SPARQL query statement is converted into an SQL query statement. After the query, the result is returned to the result converter, and RDF triples are encapsulated. The queried data is divided into the "subject-verb-object" format and encapsulated into the RDF format for return. At this point, the design of the data encapsulation layer is completed.

[0056] In this implementation, the B / S structure is used to implement the above functions, and the equipment and software required are as follows:

[0057] Ontology building tool: TopBraidComposer

[0058] Web server: Tomcat web server

[0059] Integrated Development Environment (IDE): Eclipse

[0060] Hardware environment: i5-8400 processor, 20G memory, 1T hard disk

[0061] Database: Mysql, SQL Server, Oracle, etc.

[0062] In summary, the heterogeneous data integration and query system and method designed by the present invention based on RDF can realize the integration of heterogeneous data for query and return RDF format files, and optimize the query cost and reduce the cost of computer resources. It improves the practicality and effectiveness of data and lays a solid foundation for data sharing. In the future semantic interoperability work, the present invention can play a vital role, thereby improving the operating efficiency of the entire semantic interoperability system.

[0063] Fields type Null Notes Name Varchar(20) YES Traffic Name Number Int(8) PK Traffic No. Level Int(10) YES Traffic level Money Money(100) YES Transportation costs Condition Varchar(100) YES Traffic conditions Mark Varchar(20) YES road name

[0064] Table 1 Traffic status table of database 1

[0065]

[0066]

[0067] Table 2 Road facilities table of database 2

[0068] Fields type Null Notes Name Varchar(20) YES Traffic Name Money Money(100) YES Repair costs Tratime Int(10) Device delivery time Suggestion Varchar(100) YES Equipment investment advice Update Int(100) YES Equipment update time

[0069] Table 3 Traffic road facilities table of database 3

[0070] The systems, devices, modules or units described in the above embodiments may be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.

[0071] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0072] The above embodiments should be understood to be only used to illustrate the present invention and not to limit the protection scope of the present invention. After reading the contents of the present invention, technicians can make various changes or modifications to the present invention, and these equivalent changes and modifications also fall within the scope defined by the claims of the present invention.

Claims

1. A heterogeneous data integration and query system based on RDF, characterized in that: include: The original data layer, data encapsulation layer, semantic layer, data query layer and application layer, the original data layer transmits structured data or unstructured data in the heterogeneous database to the data encapsulation layer, the data encapsulation layer transmits the encapsulated data to the semantic layer, the semantic layer transmits the semantically processed data to the data query layer, and the data query layer transmits the data to the application layer, wherein: The original data layer uses the RDF Schema resource description framework mode to describe different data sources, eliminating the syntax heterogeneity of heterogeneous data sources; and analyzes the relational table structure and semantics in the data source to eliminate the semantic heterogeneity of heterogeneous data sources; The data encapsulation layer includes a web service and a data encapsulation module; the data encapsulation module is divided into a query converter and a result converter. The query converter converts the subquery into a subquery recognizable by the corresponding database according to different underlying databases; the result converter obtains different query results according to different subqueries, and then converts the query processing results into a format to generate a file in RDF data format; The semantic layer includes Global Schema and Local Schema, as well as the schema mapping between the two schemas; the Global Schema first constructs a global ontology, then makes a semantic description of the global virtual view, and finally makes it unnecessary to query the underlying heterogeneous data source during the query process through the virtual view; the process of constructing Local Schema is the semantic description of the heterogeneous data source, and RDF can be serialized through Turtle to complete the schema creation. The Turtle document consists of a series of instructions, triple statements or blank lines; The data query layer mainly processes user requests, including request optimization, result caching, and data source packaging; the query language used is SPARQL or SQL; The application layer includes web interface, management interface and other interfaces; The data query layer includes a query cost optimization module, a selection replication module, a query execution module, and a result cache module; wherein the query cost optimization module is used to calculate the query cost of the query statement and optimize it into a minimum cost query, and this process can obtain a cost planning document for query execution; the selection replication module is used to replicate part of the query data as hot data; the query execution module is mainly responsible for the execution of the query plan, and when a request is issued, the processed result is returned to the query execution module; the result cache module caches the hot data to a specified memory space to facilitate subsequent queries, shorten the response time, and return the query results to the application layer in the format desired by the user; The query cost optimization module obtains the expected result through SPARQL statements; firstly, a SPARQL query statement is generated; secondly, the query statement is processed to analyze the sub-query statement of the corresponding data source; then, the time cost of the query statement is calculated through the improved Cost-BasedOptimization algorithm to obtain the cost planning document of the query execution; The improved Cost-Based Optimization algorithm requires the use of the script tool Preanalyze; the algorithm operation is as follows: First generate the ANALYZE statement to enable the algorithm, SET hive.cbo.enable=TRUE; Use / preanalyze.sh -f to analyze SPARQL statements. According to the different underlying database files, analyze different database query statement files, obtain statistical information and execute the files. After obtaining the analysis file, execute the / preanalyze.sh -d statement and the / database file suffix s -i my.conf statement.

2. The RDF-based heterogeneous data integration and query system according to claim 1, characterized in that: The triples of the semantic layer are a sequence of (subject, predicate, object) items separated by spaces and ending with '.' after each triple. There are three types of RDF terms: RDF URI references, text, and blank nodes. RDF is used to establish corresponding local ontologies and global ontologies based on the underlying heterogeneous data source data types, and then schema mapping is performed to achieve interoperability, where schema mapping is the mapping from Local Schema to Global Schema.

3. The RDF-based heterogeneous data integration and query system according to claim 2, characterized in that: The mapping from Local Schema to Global Schema is performed by adopting an intermediate mapping method, that is, Local Schema is first mapped into files described by RDF, and then these description files are mapped to Global Schema. The mapping mode of the former is 1:1, and the mapping mode of the latter is n:

1. It is a description model of public data, which is described by Turtle and ontology technology. The intermediate state of this mapping method belongs to the virtual view of the data source, not the real existence.

4. A heterogeneous data integration and query method based on the system according to any one of claims 1 to 3, characterized in that: Includes the following steps: The original data layer uses the RDF Schema resource description framework model to describe different data sources and eliminate the syntax heterogeneity of heterogeneous data sources; By analyzing the relational table structure and semantics in the data source, the semantic heterogeneity of heterogeneous data sources can be eliminated; The query converter converts the subquery into a subquery that can be recognized by the corresponding database according to the different underlying databases; The result converter obtains different query results according to different sub-queries, and then converts the query processing results into a file in RDF data format; The Global Schema first builds a global ontology, then makes a semantic description of the global virtual view, and finally uses the virtual view to avoid querying the underlying heterogeneous data sources during the query process. The process of building the Local Schema is the semantic description of the heterogeneous data sources. The RDF can be serialized through Turtle to complete the schema creation. The Turtle document consists of a series of instructions, triple statements or blank lines. The data query layer implements the processing of user requests, including request optimization, result caching, and data source packaging; the query language used is SPARQL or SQL.