Data migration method and device, computer program product and electronic equipment

Through the intention identification and change of the monitoring mechanism, incremental migration of the graph database is realized, solving the problems of low efficiency and poor accuracy of traditional migration methods, and achieving an efficient and intelligent data migration process.

CN120407539APending Publication Date: 2025-08-01CHINA TELECOM CORP LTD TECHNOLOGY INNOVATION CENTER +1
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202510473568.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-15
Publication Date
2025-08-01

AI Technical Summary

Technical Problem

The traditional incremental migration method of graph databases relies on manual configuration, resulting in low migration efficiency and poor accuracy, and it is easy to cause inaccurate data synchronization or failure due to human errors.

Method used

By introducing an intent identification mechanism for migration task description information, users' needs are automatically analyzed, migration intent information is generated, and real-time capture and timing triggering of data changes is realized based on change monitoring and triggering time information, and multiple migration triggering methods are supported and integrated into an automated process.

Benefits of technology

It significantly improves the intelligence and efficiency of data migration, ensures data integrity and consistency, reduces resource consumption and impact on the source system, and reduces manual intervention.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120407539A_ABST
    Figure CN120407539A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of computers, in particular to a data migration method and device, a computer program product and electronic equipment. The data migration method comprises the steps of obtaining migration task description information, and performing intention recognition on the migration task description information to obtain migration intention information; generating a migration task according to the migration intention information, monitoring the change of the target data according to the migration task to obtain changed data, and determining migration triggering time information according to the migration task; and based on the migration triggering time information, triggering a data migration operation to migrate the changed data to the graph database according to the migration task. Incremental migration of the graph database can be completed through intention recognition, and the data migration efficiency and accuracy are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technologies, and more particularly, to a data migration method, a data migration device, a computer program product, and an electronic device. Background Art

[0002] With the development of the computer field, graph databases have been widely used in many fields. For example, in the operator field, graph databases can be used to store and analyze complex relational data, such as network package price analysis. However, with the continuous growth of data scale and the change of business requirements, the traditional incremental migration method of graph databases faces many challenges in practical applications. For example, it relies on manual configuration of migration time and rules. Thus, it not only increases the burden on configurators but also easily leads to problems such as inaccurate or failed data synchronization due to human errors. Therefore, the current data migration method has the disadvantages of low migration efficiency and accuracy.

[0003] It should be noted that the information disclosed in the above background art section is only used to enhance the understanding of the background of the present disclosure, and thus may include information that does not constitute the prior art known to those of ordinary skill in the art. Summary of the Invention

[0004] An object of the present disclosure is to provide a data migration method, a data migration device, a computer program product, and an electronic device, so as to be able to complete the incremental migration of a graph database through intention recognition, and improve the data migration efficiency and accuracy.

[0005] Other features and advantages of the present disclosure will become apparent through the following detailed description, or be learned in part through the practice of the present disclosure.

[0006] According to one aspect of the present disclosure, a data migration method is provided, including: obtaining migration task description information, performing intention recognition on the migration task description information to obtain migration intention information; generating a migration task according to the migration intention information, listening for changes in target data according to the migration task to obtain changed data, and determining migration trigger time information according to the migration task; based on the migration trigger time information, triggering a data migration operation to migrate the changed data to the graph database according to the migration task.

[0007] In an exemplary embodiment of the present disclosure, the obtaining the migration task description information includes: obtaining a first prompt word template; in response to an input operation for the first prompt word template, generating the migration task description information according to the input information and the first prompt word template.

[0008] In an exemplary embodiment of the present disclosure, the migration task description information at least includes the source database attribute information corresponding to the target data, the graph database attribute information, the relationship mapping rule between the source database and the graph database, and the data migration time.

[0009] In an exemplary embodiment of the present disclosure, the intention recognition of the migration task description information to obtain migration intention information includes: using a preset large model to perform intention recognition on the migration task description information to obtain the migration intention information; performing semantic analysis on the migration task description information to obtain a semantic analysis result, and determining identification information according to the semantic analysis result, where the identification information is used to uniquely identify the migration task corresponding to the migration intention information.

[0010] In an exemplary embodiment of the present disclosure, the migration intention information includes the source database attribute information, the graph database attribute information, the relationship mapping rule between the source database and the graph database, and the data migration time; generating a migration task according to the migration intention information includes: starting a data monitoring task according to the source database attribute information, where the data monitoring task is used to monitor changes in the target data in the source database; starting a timed trigger task according to the data migration time, where the timed trigger task is used to trigger data migration when the current time reaches the data migration time to determine migration trigger time information; based on the graph database attribute information and the relationship mapping rule between the source database and the graph database, determining a data migration task, where the data migration task is used to execute data migration according to the migration trigger time information after the timed trigger task triggers data migration.

[0011] In an exemplary embodiment of the present disclosure, the method further includes: associating the data monitoring task, the timed trigger task, and the data migration task with the migration task based on the identification information.

[0012] In an exemplary embodiment of the present disclosure, determining a data migration task based on the graph database attribute information and the relationship mapping rule between the source database and the graph database includes: generating a graph database migration instruction according to the changed data obtained by the data monitoring task and the relationship mapping rule; triggering a data migration operation based on the migration trigger time information to migrate the changed data to the graph database according to the migration task includes: responding to the timed trigger task triggering data migration, and starting to execute the graph database migration instruction at the moment corresponding to the migration trigger time information to migrate the changed data to the graph database.

[0013] In an exemplary embodiment of the present disclosure, the method further includes: obtaining the task status of the migration task; and providing the task status and the identification information corresponding to the migration task to the user.

[0014] In an exemplary embodiment of the present disclosure, the method further includes: responding to an input operation for a second prompt word template, generating task stop description information according to the input information and the second prompt word template; performing intent recognition on the task stop description information to obtain intent information for stopping the task; and terminating the target migration task according to the intent information for stopping the task.

[0015] In an exemplary embodiment of the present disclosure, the task stop description information includes the identification information of the target migration task; and the terminating the target migration task according to the intent information for stopping the task includes: canceling the data listening task corresponding to the target migration task according to the identification information of the target migration task; and canceling the timed trigger task corresponding to the target migration task based on the identification information of the target migration task.

[0016] In an exemplary embodiment of the present disclosure, the triggering a data migration operation based on the migration trigger time information to migrate the changed data to the graph database according to the migration task includes: obtaining system operation attribute information; and adjusting the thread speed corresponding to the migration task and / or the batch task speed of multiple migration tasks according to the system operation attribute information.

[0017] According to one aspect of the present disclosure, there is provided a data migration apparatus, including: an intent recognition module, configured to obtain migration task description information, perform intent recognition on the migration task description information to obtain migration intent information; a first task processing module, configured to generate a migration task according to the migration intent information, listen for changes in target data according to the migration task to obtain changed data, and determine migration trigger time information according to the migration task; and a second task processing module, configured to trigger a data migration operation based on the migration trigger time information to migrate the changed data to the graph database according to the migration task.

[0018] According to one aspect of the present disclosure, there is provided a computer program product, including a computer program, which when executed by a processor, implements the method according to any one of the above.

[0019] According to one aspect of the present disclosure, there is provided an electronic device, including: a processor; and a memory, configured to store executable instructions of the processor; wherein the processor is configured to execute the method according to any one of the above by executing the executable instructions.

[0020] The data migration method in the exemplary embodiments of the present disclosure obtains migration task description information, performs intent recognition on the migration task description information to obtain migration intent information, then generates a migration task according to the migration intent information, monitors changes in the target data according to the migration task to obtain changed data, and determines migration trigger time information according to the migration task. Finally, based on the migration trigger time information, a data migration operation is triggered to migrate the changed data to the graph database according to the migration task. On the one hand, by introducing an intent recognition mechanism for migration task description information, it can automatically parse the user's data migration requirements, convert natural language descriptions or semi-structured descriptions into executable migration intent information, significantly reducing the technical threshold of data migration operations and improving the intelligence of data migration. On the other hand, based on the change monitoring mechanism of the target data for the migration task, real-time capture of data changes is achieved, ensuring that source data changes can be promptly reflected in the migration process, solving the data timeliness problem existing in traditional batch migration methods, ensuring the integrity and consistency of the migrated data, and avoiding resource waste caused by repeated full-volume data migration through the incremental migration mechanism of changed data, significantly reducing the consumption of network bandwidth and computing resources. On the other hand, by determining the migration trigger time information, it supports multiple migration trigger methods such as timed trigger and conditional trigger, and can flexibly configure the migration timing according to business requirements and data characteristics, effectively reducing the impact on the performance of the source system while ensuring timely data migration. In addition, integrating intent recognition, task generation, change monitoring, and trigger migration into an automated process reduces the manual intervention link and greatly improves the efficiency and accuracy of data migration.

[0021] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, and cannot limit the present disclosure. Brief Description of the Drawings

[0022] By reading the following detailed description with reference to the accompanying drawings, the above and other objects, features, and advantages of the exemplary embodiments of the present disclosure will become readily understood. In the drawings, several embodiments of the present disclosure are shown in an exemplary rather than restrictive manner, wherein:

[0023] Figure 1 Shows an application environment diagram related to a data migration method in an exemplary embodiment of the present disclosure.

[0024] Figure 2 Shows a flowchart of a data migration method according to an exemplary embodiment of the present disclosure.

[0025] Figure 3 Shows a flowchart of an implementation manner for obtaining migration task description information according to an exemplary embodiment of the present disclosure.

[0026] Figure 4The flowchart of an implementation manner for obtaining migration intention information according to an exemplary embodiment of the present disclosure is shown.

[0027] Figure 5 The flowchart of an implementation manner for generating a migration task according to an exemplary embodiment of the present disclosure is shown.

[0028] Figure 6 The flowchart of a data migration according to an exemplary embodiment of the present disclosure is shown.

[0029] Figure 7 The schematic diagram of a data migration system according to an exemplary embodiment of the present disclosure is shown.

[0030] Figure 8 The flowchart of another data migration according to an exemplary embodiment of the present disclosure is shown.

[0031] Figure 9 The schematic diagram of the composition of a data migration device according to an exemplary embodiment of the present disclosure is shown.

[0032] Figure 10 The block diagram of an electronic device according to an exemplary embodiment of the present disclosure is shown.

[0033] In the drawings, the same or corresponding reference numerals indicate the same or corresponding parts. Detailed implementation manners

[0034] Now, exemplary embodiments will be described more fully with reference to the accompanying drawings. However, the exemplary embodiments can be implemented in various forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be more complete and comprehensive, and the concept of the exemplary embodiments will be fully conveyed to those skilled in the art. The same reference numerals in the drawings denote the same or similar structures, and thus their detailed descriptions will be omitted.

[0035] In addition, the described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of the embodiments of the present disclosure. However, those skilled in the art will realize that the technical solutions of the present disclosure can be practiced without one or more of the specific details, or other methods, components, devices, steps, etc. can be adopted. In other cases, well-known structures, methods, devices, implementations, or operations are not shown or described in detail to avoid obscuring aspects of the present disclosure.

[0036] The block diagrams shown in the accompanying drawings are only functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software form, or in one or more software-hardened modules, or in different networks and / or processor devices and / or microcontroller devices.

[0037] Artificial Intelligence (AI) is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a way similar to human intelligence. Artificial intelligence also studies the design principles and implementation methods of various intelligent machines to enable the machines to have the functions of perception, reasoning, and decision-making.

[0038] Artificial intelligence technology is an interdisciplinary subject with a wide range of fields, including both hardware-level and software-level technologies. The basic technologies of artificial intelligence generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, and mechatronics. The software technologies of artificial intelligence mainly include several major directions such as computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning.

[0039] Large Language Models (LLMs) refer to artificial intelligence models with ultra-large-scale parameters and strong generalization capabilities. Through massive data training, deep learning models with tens of billions to trillions of parameter scales can handle multi-modal tasks such as natural language, images, and audio.

[0040] The technical solution provided by the exemplary embodiment of the present disclosure relates to the large model technology of artificial intelligence. Based on the large model, intention recognition is performed according to the obtained migration description information provided by the user, and a migration task is generated according to the intention recognition result, and the migration task is automatically executed.

[0041] It should be noted that the exemplary embodiment of the present disclosure can be applied to fields that require graph database data migration, such as enterprise data architecture modernization, knowledge graph construction and maintenance, social networks and recommendation systems, financial risk control, Internet of Things and supply chain management, biomedicine and health care, etc., without limitation.

[0042] The data migration method provided by the exemplary embodiment of the present disclosure can be applied to, for example Figure 1In the application environment shown. Among them, the terminal 101 communicates with the server 102 through the network. The data storage system can store the data that the server 102 needs to process. The data storage system can be integrated on the server 102, or placed on the cloud or other network servers.

[0043] In one exemplary embodiment, the data migration method provided by the exemplary embodiments of the present disclosure can be executed by the server 102. Correspondingly, the data migration device is set in the server 102. Correspondingly, in this manner executed by the server 102, the server 102 can start executing the technical solution in the exemplary embodiments of the present disclosure in response to a trigger execution order, where the trigger execution order can be sent by the terminal used by the user, or can be locally triggered by the server in response to some automated events.

[0044] The server 102 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. The server 102 can execute background tasks.

[0045] Furthermore, in another exemplary embodiment, the terminal 101 can also have a similar function to the server 102, so as to execute the data migration method provided by the exemplary embodiments of the present disclosure.

[0046] Among them, the terminal 101 can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, an Internet of Things device, and a portable wearable device. The Internet of Things device can be a smart speaker, a smart TV, a smart air conditioner, and a smart in-vehicle device, etc. The portable wearable device can be a smart watch, a smart bracelet, a head-mounted device, etc. The terminal 101 can also be referred to as a mobile terminal, a terminal device, a mobile device, etc. The exemplary embodiments of the present disclosure do not limit the type of the terminal 101.

[0047] In addition, the technical solution of the exemplary embodiments of the present disclosure can also be executed jointly by the terminal 101 and the server 102. In this manner of joint execution by the terminal 101 and the server 102, some steps in the technical solution provided by the exemplary embodiments of the present disclosure are executed by the terminal 101, while some other steps are executed by the server 102. It should be noted that in this manner of joint execution by the terminal 101 and the server 102, the steps respectively executed by the terminal 101 and the server 102 can be dynamically adjusted according to the actual situation, and no special restrictions are imposed on this.

[0048] Among them, the terminal 101 and the server 102 can be directly or indirectly connected through a wireless communication method, and no special restrictions are imposed on the exemplary embodiments of the present disclosure herein.

[0049] Graph databases are widely used in many fields. For example, in the operator field, graph databases can be used to store and analyze complex relationship data, such as network package price analysis, production and sales product retrieval, etc. However, with the continuous growth of data scale and the change of business requirements, the traditional incremental migration method of graph databases faces many challenges in practical applications. For example, it depends on manual configuration of migration time and rules. In this way, it not only increases the burden on configuration personnel, but also easily leads to problems such as inaccurate or failed data synchronization due to human errors. Therefore, the current data migration method has the disadvantages of low migration efficiency and accuracy.

[0050] Based on this, the exemplary embodiments of the present disclosure provide a data migration method, as Figure 2 shown in the flowchart of the data migration method of the exemplary embodiments of the present disclosure. Referring to Figure 2 shown, this data migration method includes steps S210 to S240, which are introduced in detail as follows:

[0051] In step S210, obtain the migration task description information, and perform intent recognition on the migration task description information to obtain the migration intent information.

[0052] In the exemplary embodiments of the present disclosure, the migration task description information refers to the source information provided by the user or the system for describing the data migration requirements, which is a set of elements including the source and target of data migration, conversion rules, execution conditions, etc., and is the original input for intent recognition. A preset large model can be used to perform intent recognition on the migration task description information to obtain the migration intent information.

[0053] Among them, the preset large model can be an open-source large model or a large model fine-tuned and trained according to the task description information and intent recognition sample data, and no restrictions are imposed on this.

[0054] The migration intent information refers to the standardized migration requirement representation obtained by parsing and recognizing the migration task description information, which can be directly understood and executed by (such as the migration system), and is the intermediate semantic layer connecting the user requirements and the specific migration tasks.

[0055] In some optional embodiments, the migration task description information at least includes the source database attribute information corresponding to the target data, the graph database attribute information, the relationship mapping rule between the source database and the graph database, and the data migration time.

[0056] Among them, the source database attribute information corresponding to the target data refers to the set of characteristic parameters that describe the source data storage system to be migrated and is used to accurately locate and access the source data. The source data storage system can be a relational database, and the source database attribute information may include, but is not limited to, the type of relational database, IP (Internet Protocol) address, port number, access credentials, database instance name, and data table name, etc. The types of relational databases may include, but are not limited to, Oracle, MySQL, PostgreSQL, and SQL Server, etc., and no specific restrictions are imposed thereon.

[0057] The graph database attribute information refers to the set of characteristic parameters and data organization requirements that describe the target graph database system and is used to guide the target storage form of the data. It may include, but is not limited to, the IP, port, access credentials, and graph database instance of the graph database. The data migration time refers to the time strategy that controls the execution timing of the migration task, including the initial migration time and / or the continuous synchronization strategy. The initial migration time is used to indicate the moment when the migration task starts to execute. The continuous synchronization strategy is a dynamic update mechanism that maintains data consistency between the source database and the target graph database after the initial data migration. This strategy ensures that changes (insertion, deletion, modification) to the source data can be reflected in the target graph database in real-time or near real-time without the need for repeated full-scale migrations. For example, the data migration time includes strategies such as performing data migration within the time period from 20:00 to 22:00 every day, performing data migration with real-time updates, and performing data migration throughout Saturday and Sunday.

[0058] The relationship mapping rules between the source database and the graph database refer to the set of specifications that define how to convert the inter-table relationships in the source database into the inter-node relationships in the graph database and may include node mapping rules and relationship mapping rules.

[0059] Among them, the node mapping rules include the mapping rules for defining the mapping between the database table and the graph database entity, and the mapping rules for the database table fields and the graph database entity attributes. The relationship mapping rules are used to define the mapping rules for mapping the association relationship between two data tables in the relational database to the association relationship between the head and tail entities of the graph database. The association relationship between the head and tail entities of the graph database is represented by a directed edge, indicating the association relationship from the head entity to the tail entity.

[0060] It should be understood that in a relational database, the association between tables is established through foreign keys, while in a graph database, the association is directly connected by edges (Edge). In a graph database, the head entity represents the starting node in the relationship, the tail entity represents the target node in the relationship, and the association relationship is the edge connecting the two entities. Based on the relationship mapping rules between the source database and the graph database, the incremental migration of table data in the relational database to the graph database can be accurately performed.

[0061] By performing intent recognition on the migration task description information, migration intent information can be obtained. The migration intent information includes structured information such as source database attribute information, graph database attribute information, relationship mapping rules between the source database and the graph database, and data migration time, etc., and can thus be directly understood and executed by (such as a migration system).

[0062] In step S220, a migration task is generated according to the migration intent information, the changes of the target data are monitored according to the migration task to obtain changed data, and the migration trigger time information is determined according to the migration task.

[0063] In an exemplary embodiment of the present disclosure, the migration task can be understood as a migration strategy generated according to the migration intent information, including a data monitoring task, a timed trigger task, and a data migration task. Among them, the changes of the target data can be monitored through the data monitoring task to obtain changed data, and the target data refers to the data in the data tables to be migrated in the source database to be migrated. The migration trigger time information can be determined through the timed trigger task, and the data migration task can be triggered. The data migration operation can be triggered through the data migration task.

[0064] In some optional embodiments, an open-source tool (such as Debezium, an open-source distributed platform) can be used to be responsible for the data change events of the database, and the data change events are stored in a distributed message queue (such as Kafka). By calling the open-source tool API (Application Programming Interface), the monitoring of the target data table is started (such as monitoring the database transaction log (such as the binlog of MySQL, the WAL of PostgreSQL)) to monitor the changes of the target data to obtain changed data. If data changes occur, the changed data is sent to the distributed message queue in the form of a message through the open-source tool to obtain the changed data therefrom.

[0065] By directly parsing the database transaction log using an open-source tool, change detection with millisecond-level latency can be achieved, which is at least two orders of magnitude more efficient than the traditional polling method (minute-level latency). It provides real-time or near-real-time changed data for data migration, upgrades the data migration timeliness from timed synchronization to near-real-time synchronization, and through the persistent storage of the distributed message queue, it can ensure that even if the migration service goes down, the change events can still be retained and re-consumed for fault tolerance metrics, thereby ensuring the system stability of data migration.

[0066] In step S230, based on the migration trigger time information, a data migration operation is triggered to migrate the changed data to the graph database according to the migration task.

[0067] In an exemplary embodiment of the present disclosure, the migration trigger time information can be used to indicate the time to start performing data migration. Optionally, a timing trigger can be created according to the migration task. Based on the timing trigger, when it is determined that the data migration time has arrived, the current moment is determined as the trigger time information, and the data migration operation is triggered.

[0068] In some alternative embodiments, the function of the timing trigger can be implemented by starting a process in the background. Among them, the process can use a Cron conditional expression to represent the data migration time, and continuously determine whether the current time meets the trigger condition (data migration time) defined by the Cron expression at intervals of a preset number of seconds (such as 1 second). Once the condition is met, the current time is determined as the trigger time information, and the data migration operation is immediately triggered through the process. For example, if it is set to perform data migration from 20:00 to 22:00 every day, the corresponding Cron expression is: "0 0 20-22 **?". Of course, the way to represent the data migration time is not limited to this, and it can also be expressed in other ways, which is not restricted here.

[0069] By starting a process and using a Cron conditional expression to drive the mechanism for triggering data migration, compared with the traditional timing task system, the time control accuracy is improved from the minute level to the second level.

[0070] The data migration method in the exemplary embodiment of the present disclosure, on the one hand, by introducing an intention recognition mechanism for migration task description information, can automatically analyze the user's data migration requirements, convert natural language descriptions or semi-structured descriptions into executable migration intention information, significantly reducing the technical threshold of data migration operations and improving the intelligence of data migration. On the other hand, based on the change monitoring mechanism of the target data for the migration task, real-time capture of data changes is achieved, ensuring that source data changes can be promptly reflected in the migration process, solving the data timeliness problem existing in the traditional batch migration method, ensuring the integrity and consistency of the migrated data, and through the incremental migration mechanism of changed data, avoiding resource waste caused by repeated full-scale data migration, significantly reducing the consumption of network bandwidth and computing resources. On the further hand, through the determination of the migration trigger time information, various migration trigger methods such as timing trigger and conditional trigger are supported, and the migration timing can be flexibly configured according to business requirements and data characteristics, effectively reducing the impact on the performance of the source system while ensuring timely data migration. In addition, integrating intention recognition, task generation, change monitoring, and trigger migration into an automated process reduces the manual intervention link and greatly improves the efficiency and accuracy of data migration.

[0071] In an exemplary embodiment, an implementation manner for obtaining migration task description information is provided. As Figure 3 shown, obtaining the migration task description information may include:

[0072] Step S310: Obtain the first prompt template.

[0073] The first prompt template is a predefined semantic framework containing fillable placeholders, used to guide the user to input a complete description of the migration requirements. Among them, the first prompt template can come from a local template library or from a cloud template.

[0074] As an example, the following is a first prompt template: "I need to synchronize the incremental data of a relational database to a graph database. Please help me complete the incremental migration task and provide the following information: 1. Source database attribute information: {}; 2. Graph database attribute information: {}; 3. Data migration time: {}; 4. Relationship mapping rules between the source database and the graph database: {}". The first prompt template contains four placeholders "{}", used to indicate that the user needs to fill in specific information according to the actual situation.

[0075] Step S320: Respond to the input operation for the first prompt template, and generate migration task description information according to the input information and the first prompt template.

[0076] The user can input according to the first prompt template to obtain input information, and thus generate migration task description information according to the input information and the first prompt template.

[0077] Through template guidance, non-technical personnel can complete professional-level migration descriptions, and the structured template enforces the integrity of key elements, which can reduce the defect rate of the generated migration task description information, provide accurate guidance information for data migration, and also enable users to trigger data migration through natural language interaction.

[0078] In an exemplary embodiment, an implementation manner for obtaining migration intention information is provided. As Figure 4 shown, performing intention recognition on the migration task description information to obtain migration intention information may include:

[0079] Step S410: Use a preset large model to perform intention recognition on the migration task description information to obtain migration intention information.

[0080] Step S420: Perform semantic analysis on the migration task description information to obtain a semantic analysis result, and determine identification information according to the semantic analysis result. The identification information is used to uniquely identify the migration task corresponding to the migration intention information.

[0081] Among them, a fine-tuned large model or an open-source large model can be used to perform semantic analysis on the migration task description information to obtain migration intention information. As can be seen above, the migration intention information includes source database attribute information, graph database attribute information, relationship mapping rules between the source database and the graph database, and data migration time.

[0082] In step S420, semantic analysis is performed on the migration task description information to obtain the semantic analysis result. For the semantic analysis, a pre-trained semantic analysis model can be used. The exemplary embodiments of the present disclosure do not limit the type of the pre-trained semantic analysis model.

[0083] In some optional embodiments, the identification information is used to uniquely identify the migration task corresponding to the migration intention information. It can be understood that the user may express the same migration intention in different ways. For example, "migrate the updated data of the relational database to the target graph database" and "synchronize the updated data of the relational data to the target database". Although the expressions are different, their migration intentions are the same. Therefore, to ensure the uniqueness of the content of the migration task and prevent duplicate submission of the same migration task, the identification information can also be determined according to the semantic analysis result to be used to uniquely identify the migration task corresponding to the migration intention information.

[0084] Among them, the migratable task description information can be processed by text vectorization, and based on the text vectorization processing result, it is matched whether there is an existing text vectorization processing result whose vector similarity with the text vectorization processing result is greater than a preset threshold. If not, a unique identifier is generated according to the text vectorization processing result. If so, the identification information corresponding to the existing text vectorization processing result is obtained as the identification information of this text vectorization processing result.

[0085] Optionally, if not, when generating a unique identifier according to the text vectorization processing result, a hash code can be used to generate the unique identifier. For example, the semantic hash of the text vectorization processing result is calculated as the unique identifier, or the structural hash of the text vectorization processing result (such as calculating the SimHash value of the text vectorization processing result as the unique identifier). The exemplary embodiments of the present disclosure include but are not limited to the above ways of calculating the identification information (unique identifier).

[0086] Optionally, when there is a hash collision in generating the identification information, it can also be processed by at least one of the methods of appending a nanosecond-level timestamp, injecting a random number salt value, and generating a conforming identifier.

[0087] By generating the identification information of the migration task corresponding to the migration intention information, the uniqueness of the migration intention at the semantic level can be ensured, duplicate task submission can be avoided to achieve system optimization, and due to the semantic relevance of the identification information, it is beneficial to support seamless association among task scheduling, resource monitoring, and billing systems.

[0088] Based on the foregoing exemplary embodiments, an implementation manner of generating a migration task is further provided. As Figure 5 shown, generating a migration task according to the migration intention information may include:

[0089] Step S510: Start a data monitoring task according to the source database attribute information. The data monitoring task is used to monitor changes to the target data in the source database.

[0090] Step S520: Start a timed trigger task according to the data migration time. The timed trigger task is used to trigger data migration when the current time reaches the data migration time to determine the migration trigger time information.

[0091] Step S530: Determine a data migration task based on the graph database attribute information and the relationship mapping rules between the source database and the graph database. The data migration task is used to perform data migration according to the migration trigger time information after the timed trigger task triggers data migration.

[0092] It should be noted that the execution order between Step S510 and Step S520 is not restricted. They can be executed simultaneously or sequentially, and no restrictions are imposed on this. In addition, the specific details of Step S510 and Step S520 have been described in the above exemplary embodiments and will not be elaborated here.

[0093] In some optional embodiments, the data monitoring task, the timed trigger task, and the data migration task can also be associated with the migration task based on the identification information to ensure that all operations are associated with the same migration task, achieving the coordination and unified scheduling of subsequent migration tasks.

[0094] In some optional embodiments, in Step S530, a graph database migration instruction can be generated according to the changed data obtained by the data monitoring task and the relationship mapping rules.

[0095] As an example, taking the addition of a new entity to the Neo4j graph database as an example, the statement of its migration instruction can be expressed as: CREATE(n:Entity{id:'1',name:'Example Entity',description:'This is an example entity'}) RETURN n. Among them, Neo4j is a graph database management system used to store, retrieve, and process graph data, and organizes and represents data in the form of a graph.

[0096] Based on this, after generating the graph database migration instruction, it can enter the waiting state, and then respond to the timed trigger task to trigger data migration, and start executing the graph database migration instruction at the moment corresponding to the migration trigger time information to migrate the changed data to the graph database.

[0097] By generating the graph database migration instruction, not only can the data migration task be executed when data migration is triggered, but also discrete change events can be compiled into batch processing instructions, increasing the amount of word network round-trip processing and improving the migration efficiency.

[0098] In an exemplary embodiment, the task status of the migration task can also be obtained, and the task status and the identification information corresponding to the migration task are provided to the user.

[0099] The task status refers to the status information describing the current execution of the migration task. For example, it is in normal execution, stopped execution, or may also include the execution progress of the migration task, etc.

[0100] Optionally, the task status can be pushed to the user through a visual interface (such as a Web console), email, SMS, or API callback. Optionally, the task status and identification information (such as identification information, progress, elapsed time, associated resources) can be presented in the user interface in the form of a table, progress bar, or chart. Optionally, it also supports the user to filter the migration tasks according to the identification information (such as task ID, time range), or click on the migration task entry to view detailed information (such as error logs, retry operations).

[0101] Providing the task status and the identification information corresponding to the migration task to the user allows the user to timely confirm the start of the task and guide subsequent operations.

[0102] In an exemplary embodiment, an implementation method for terminating data migration is also provided. The implementation method may include:

[0103] First, in response to an input operation for the second prompt word template, task stop description information is generated according to the input information and the second prompt word template. Secondly, intent recognition is performed on the task stop description information to obtain the intent information for stopping the task. Finally, the target migration task is terminated according to the intent information for stopping the task.

[0104] Similar to the first prompt word template, the second prompt word template is a predefined semantic framework containing fillable placeholders, which is used to guide the user to input a complete description of the migration requirements. The second prompt word template can come from a local template library or from the cloud template.

[0105] As an example, the following is a second prompt word template: "I need to terminate the incremental data synchronization of the relational database to the graph database. Please help me terminate the incremental migration task. Please provide the following information: 1. The identification information corresponding to the migration task: {}. The second prompt word template contains the placeholder "{}", which is used to indicate that the user needs to fill in specific information according to the actual situation. The identification information corresponding to the migration task has been provided to the user when the migration task is generated.

[0106] The user can input information based on the first and second prompt word templates to obtain input information, and then generate task stop description information based on the input information and the second prompt word template. Intent recognition is performed on the task stop description information to obtain the intention information of stopping the task. The above process of intent recognition of the migration task description information can be referred to.

[0107] Through template guidance, non-technical personnel can complete professional-level migration termination descriptions. Structured templates enforce the completeness of key elements, which can reduce the defect rate of generated task stop description information, provide accurate guidance information for terminating data migration, and enable users to trigger the termination of data migration through natural language interaction.

[0108] The task stop description information includes identification information of the target migration task, and terminating the target migration task according to the intention information of stopping the task may include:

[0109] First, according to the identification information of the target migration task, the data monitoring task corresponding to the target migration task is canceled, and then based on the identification information of the target migration task, the timer triggering task corresponding to the target migration task is canceled.

[0110] It should be understood that since the identification information of the target migration task is obtained, the relevant information of the target migration task can be obtained based on the identification information, including but not limited to the source database attribute information, graph database attribute information, the relationship mapping rules between the source database and the graph database, and the data migration time of the target migration task, as well as the data monitoring task, timed trigger task and data migration task corresponding to the target migration task, so that any of the data monitoring task, timed trigger task and data migration task corresponding to the target migration task can be terminated to complete the termination operation of the target migration task.

[0111] As an example, you can use the target migration task's identifier to obtain the target data table and Kafka topic. Then, call the Debezium API to delete the target table's listener and the Kafka API to delete the specified topic. Furthermore, you can use the migration task's identifier to find the corresponding background process ID and terminate it, thereby deleting the scheduled task.

[0112] Directly locating the migration task and its included subtasks through identification information avoids traversing all tasks, which is conducive to the efficient release of system resources. In addition, using a single piece of identification information to simultaneously cancel data monitoring and timer triggering allows one-click full-link task cancellation, improving operation and maintenance efficiency.

[0113] In addition, after completing the termination operation of the target migration task, the task status can be fed back to the user, allowing the user to globally control the task status.

[0114] In an exemplary embodiment, based on the migration trigger time information, triggering a data migration operation to migrate changed data to a graph database according to a migration task may include:

[0115] First, obtain system running property information. Second, according to the system running property information, adjust the thread speed corresponding to the migration task and / or the batch task speed of multiple migration tasks.

[0116] Among them, the system running property refers to a set of quantifiable indicators reflecting the real-time state of the computing environment, which is used to evaluate the resource capabilities and health status of the current system for executing migration tasks. These properties constitute the decision-making basis for dynamic speed regulation, including system CPU (Central Processing Unit) utilization rate, memory usage rate, transmission delay, bandwidth occupancy rate, source library load fraction, etc. The thread speed corresponding to the migration task refers to the working rate of the data processing thread in a single migration task instance, such as the number of data units processed per unit time (e.g., records / second). The batch task speed of multiple migration tasks refers to the macro scheduling strategy when multiple migration tasks are executed in parallel, such as the batch size (e.g., the amount of data processed in a single transaction).

[0117] Optionally, the corresponding relationship between the system running property (such as CPU utilization rate) and the thread speed corresponding to the migration task can be preset in advance, so that the thread speed corresponding to the migration task can be adjusted according to the current system running property information and this corresponding relationship. Optionally, the corresponding relationships between different categories of system running properties (such as CPU utilization rate, memory usage rate) and the thread speed corresponding to the migration task can be set respectively. According to the current system running property information and each corresponding relationship, the thread speeds are determined respectively, and the obtained thread speeds are fused (such as weighted average) to obtain a fusion result, so as to adjust the thread speed corresponding to the migration task according to the fusion result. Of course, the determination method for the batch task speed of multiple migration tasks can also be through a similar method, that is, preset the corresponding relationship between the system running property (such as CPU utilization rate) and the batch task speed, so as to determine the batch task speed according to the current system running property and this corresponding relationship.

[0118] By means of adaptive load balancing, adjusting the thread speed corresponding to the migration task and / or the batch task speed of multiple migration tasks can ensure the migration efficiency, fully ensure the utilization rates of resources such as CPU, memory, and network, and at the same time achieve overload protection.

[0119] Figure 6 Shows a flowchart of data migration. Figure 7The following is a schematic diagram of a data migration system, which includes an intention recognition component, a planning and decision-making component, a data monitoring component, a timing trigger component, and a graph database migration component. The following will specifically describe the incremental migration of data in the graph database in combination with Figure 6 and Figure 7 . It should be understood that the features and functions of each component can be embodied in one module or unit or component. Conversely, the features and functions of the components described above can be further divided and embodied by multiple modules or units or components.

[0120] First, obtain the first prompt word template, and in response to the input operation for the first prompt word template, generate migration task description information based on the input information and the first prompt word template.

[0121] Second, perform intention recognition on the migration task description information to obtain migration intention information.

[0122] Among them, the intention recognition component can perform intention recognition on the migration task description information.

[0123] Then, generate a migration task according to the migration intention information.

[0124] Among them, the planning and decision-making component can obtain the migration intention information and generate a migration task.

[0125] In this way, the planning and decision-making component can start the data monitoring component and pass the identification information of the migration task and the source database attribute information, so that the data monitoring component monitors the changes of the target data according to the migration task to obtain the changed data. The planning and decision-making component can start the timing trigger component and provide the identification information of the migration task and the migration trigger time, so that the timing trigger component creates a trigger to start the timing trigger task. The planning and decision-making component can also start the graph database migration component and pass in the graph database attribute information and the relationship mapping rule between the source database and the graph database, so that after receiving the instruction of the trigger, it migrates the changed data to the graph database.

[0126] Finally, monitor the changes of the target data according to the migration task to obtain the changed data, and determine the migration trigger time information according to the migration task, so as to trigger the data migration operation based on the migration trigger time information to migrate the changed data to the graph database according to the migration task.

[0127] Among them, after the data monitoring component obtains the identification information of the migration task and the source database attribute information, it starts the real-time monitoring of the specified data table. After the timing trigger component obtains the identification information of the migration task and the migration trigger time, it can create a timing trigger for this migration task and actively trigger the operation of the graph database migration component when the set trigger time arrives. Correspondingly, after the graph database migration component receives the graph database attribute information and the relationship mapping rule between the source database and the graph database, it can generate a graph database migration instruction according to the changed data obtained by the data monitoring task and the relationship mapping rule, and then enter the waiting state. Furthermore, after receiving the trigger execution instruction from the timing trigger component, it immediately executes the generated graph database migration instruction to immediately migrate the changed data into the graph database.

[0128] In addition, the planning and decision-making component can also provide the task status and the identification information corresponding to the migration task to the user.

[0129] It should be noted that the specific details of the execution of each step have been described in the above exemplary embodiments and will not be elaborated here.

[0130] Figure 8 Shows another flowchart of data migration. The following will specifically describe the termination of the data increment migration of the graph database in combination with Figure 7 and Figure 8 It should be understood that the features and functions of each component can be embodied in one module or unit or component. Conversely, the features and functions of the components described above can be further divided and embodied by multiple modules or units or components.

[0131] First, in response to the input operation for the second prompt word template, task stop description information is generated according to the input information and the second prompt word template.

[0132] Secondly, intention recognition is performed on the task stop description information to obtain the intention information to stop the task.

[0133] Among them, the intention recognition component can perform intention recognition on the task stop description information.

[0134] Then, the target migration task is terminated according to the intention information to stop the task.

[0135] Among them, the planning and decision-making component can determine the migration task to be terminated according to the intention information to stop the task, and the planning and decision-making component can call the data monitoring component and transfer the identification information of the migration task, so that the data monitoring component terminates the monitoring of the specified data table according to the identification information. The planning and decision-making component can call the timing trigger component and provide the identification information of the migration task, so that the timing trigger component outputs a timing trigger task, such as the timing trigger component deletes the timing trigger associated with this migration task.

[0136] Finally, the task status of terminating the migration task can also be fed back to the user.

[0137] It should be noted that the specific details of the execution of each step have been described in the above exemplary embodiments and will not be elaborated here.

[0138] For the data migration method in the exemplary embodiments of the present disclosure, on the one hand, by introducing an intention recognition mechanism for migration task description information, it can automatically analyze the user's data migration requirements, convert natural language descriptions or semi-structured descriptions into executable migration intention information, enabling the user to efficiently complete the incremental migration task of the graph database without cumbersome manual configuration, significantly reducing the technical threshold of data migration operations and improving the intelligence of data migration. On the other hand, based on the change monitoring mechanism of the target data for the migration task, it realizes the real-time capture of data changes, ensures that source data changes can be promptly reflected in the migration process, solves the data timeliness problem existing in traditional batch migration methods, guarantees the integrity and consistency of the migrated data, and through the incremental migration mechanism of changed data, avoids the resource waste caused by repeated full-volume data migration, significantly reducing the consumption of network bandwidth and computing resources. On the further hand, through the determination of migration trigger time information, it supports multiple migration trigger methods such as timed trigger and conditional trigger, and can flexibly configure the migration timing according to business requirements and data characteristics, effectively reducing the impact on the performance of the source system while ensuring timely data migration. In addition, integrating intention recognition, task generation, change monitoring, and trigger migration into an automated process reduces the manual intervention link and greatly improves the efficiency and accuracy of data migration.

[0139] In the exemplary embodiments of the present disclosure, a data migration device is also provided. Refer to Figure 9 As shown, the data migration device 900 may include an intention recognition module 910, a first task processing module 920, and a second task processing module 930. Specifically:

[0140] The intention recognition module 910 is configured to obtain migration task description information, perform intention recognition on the migration task description information to obtain migration intention information; the first task processing module 920 is configured to generate a migration task according to the migration intention information, monitor changes in the target data according to the migration task to obtain changed data, and determine migration trigger time information according to the migration task; the second task processing module 930 is configured to, based on the migration trigger time information, trigger a data migration operation to migrate the changed data to the graph database according to the migration task.

[0141] Since the detailed content of each functional module of the data migration device in the exemplary embodiments of the present disclosure has been described in the exemplary embodiments of the above data migration method, it will not be elaborated here.

[0142] It should be noted that although several modules or units of the data migration device are mentioned in the above detailed description, such a division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of the two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.

[0143] The exemplary embodiments of the present disclosure also provide a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, it implements the above data migration method.

[0144] In one embodiment, the computer program product may be a tangible product containing a computer program, such as a computer-readable storage medium storing the computer program. The readable storage medium may be a storage medium based on signals such as electricity, magnetism, light, electromagnetic, infrared, etc., including but not limited to: random access memory (RAM), read-only memory (ROM), magnetic tape, floppy disk, flash memory (Flash), mechanical hard disk (HDD), solid state drive (SSD), and so on. Exemplarily, the computer program product may be implemented as a non-volatile storage medium storing the computer program, such as read-only memory, Nand Flash, etc.

[0145] In one embodiment, the computer program product may be an intangible product containing a computer program. Exemplarily, the computer program product may be implemented as a virtual digital product, such as an executable file storing the computer program, an installation package and other digital files.

[0146] The code of the computer program can be written in one or more programming languages. The program code can be executed entirely on the user's computing device, or partially on the user's computing device, or executed as an independent software package, or partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user's computing device through any type of network, such as a local area network (LAN), a wide area network (WAN), etc., or can be connected to an external computing device (for example, through an Internet connection provided by an operator).

[0147] A computer program can be carried or transmitted by electrical, magnetic, optical, electromagnetic, infrared, or other signals. An electronic device can convert the signal carrying the computer program into a digital signal and then run the computer program. When the computer program runs on the electronic device, its code is used to cause the electronic device to execute (more specifically, to cause the processor of the electronic device to execute) the method steps of various exemplary embodiments of the present disclosure, such as the steps of the data migration method described above.

[0148] In addition, in an exemplary embodiment of the present disclosure, an electronic device capable of implementing the above method is also provided. Those skilled in the art can understand that various aspects of the present disclosure can be implemented as a system, a method, or a program product. Therefore, various aspects of the present disclosure can be specifically implemented in the following forms: a complete hardware embodiment, a complete software embodiment (including firmware, microcode, etc.), or an embodiment combining hardware and software aspects, which can be collectively referred to as "circuits", "modules", or "systems" here.

[0149] The following refers to Figure 10 to describe the electronic device 1000 according to such an embodiment of the present disclosure. Figure 10 The displayed electronic device 1000 is merely an example and should not impose any limitations on the functions and usage scope of the embodiments of the present disclosure.

[0150] As Figure 10 shown, the electronic device 1000 is presented in the form of a general-purpose computing device. The components of the electronic device 1000 may include, but are not limited to: at least one of the above-mentioned processing units 1010, at least one of the above-mentioned storage units 1020, a bus 1030 connecting different system components (including the storage unit 1020 and the processing unit 1010), and a display unit 1040.

[0151] Among them, the storage unit stores program code, and the program code can be executed by the processing unit 1010, so that the processing unit 1010 executes the steps according to various exemplary embodiments of the present disclosure described in the above "Exemplary Method" section of this specification.

[0152] The storage unit 1020 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 1021 and / or a cache storage unit 1022, and may further include a read-only storage unit (ROM) 1023.

[0153] The storage unit 1020 may further include a program / utility 1024 having a set (at least one) of program modules 1025. Such program modules 1025 include, but are not limited to: an operating system, one or more application programs, other program modules, and program data. The implementation of a network environment may be included in each or some combination of these examples.

[0154] The bus 1030 can represent one or more of several types of bus architectures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of the various bus architectures.

[0155] The electronic device 1000 can also communicate with one or more external devices 1100 (such as a keyboard, a pointing device, a Bluetooth device, etc.), and can also communicate with one or more devices that enable a user to interact with the electronic device 1000, and / or communicate with any device that enables the electronic device 1000 to communicate with one or more other computing devices (such as a router, a modem, etc.). Such communication can be carried out through the input / output (I / O) interface 1050. Moreover, the electronic device 1000 can also communicate with one or more networks (such as a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through the network adapter 1060. As shown in the figure, the network adapter 1060 communicates with other modules of the electronic device 1000 through the bus 1030. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in combination with the electronic device 1000, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.

[0156] Through the description of the above embodiments, those skilled in the art can easily understand that the exemplary embodiments described herein can be implemented by software, or can be implemented by the way of software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure can be embodied in the form of a software product, and the software product can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.

[0157] In addition, the above drawings are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present disclosure, rather than for limiting purposes. It is easy to understand that the processes shown in the above drawings do not indicate or limit the time sequence of these processes. Additionally, it is also easy to understand that these processes can be executed synchronously or asynchronously, for example, in multiple modules.

[0158] Other embodiments of the present disclosure will be readily apparent to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. The present disclosure is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include known common general knowledge or conventional technical means in the technical field not disclosed by the present disclosure. The specification and examples are only to be considered as exemplary, and the true scope and spirit of the present disclosure are pointed out by the claims.

Claims

1. A data migration method, characterized in that, Including: Obtain migration task description information, perform intent recognition on the migration task description information to obtain migration intent information; Generate a migration task according to the migration intent information, monitor changes in target data according to the migration task to obtain changed data, and determine migration trigger time information according to the migration task; Based on the migration trigger time information, trigger a data migration operation to migrate the changed data to the graph database according to the migration task.

2. The method according to claim 1, wherein The obtaining of the migration task description information includes: Obtain a first prompt word template; Respond to an input operation for the first prompt word template, and generate the migration task description information according to the input information and the first prompt word template.

3. The method according to claim 1 or 2, characterized in that, The migration task description information at least includes source database attribute information corresponding to the target data, graph database attribute information, a relationship mapping rule between the source database and the graph database, and a data migration time.

4. The method according to claim 3, wherein The performing of intent recognition on the migration task description information to obtain migration intent information includes: Use a preset large model to perform intent recognition on the migration task description information to obtain the migration intent information; Perform semantic analysis on the migration task description information to obtain a semantic analysis result, and determine identification information according to the semantic analysis result, where the identification information is used to uniquely identify the migration task corresponding to the migration intent information.

5. The method according to claim 4, characterized in that, The migration intent information includes the source database attribute information, graph database attribute information, a relationship mapping rule between the source database and the graph database, and a data migration time; The generating of a migration task according to the migration intent information includes: Start a data monitoring task according to the source database attribute information, where the data monitoring task is used to monitor changes in target data in the source database; Start a timed trigger task according to the data migration time, where the timed trigger task is used to trigger data migration when the current time reaches the data migration time to determine migration trigger time information; Based on the graph database attribute information and the relationship mapping rule between the source database and the graph database, determine a data migration task, where the data migration task is used to perform data migration according to the migration trigger time information after the timed trigger task triggers data migration.

6. The method according to claim 5, wherein The method further includes: Based on the identification information, associate the data monitoring task, the timed trigger task, and the data migration task with the migration task.

7. The method according to claim 5, characterized in that The determining of the data migration task based on the graph database attribute information and the relationship mapping rule between the source database and the graph database includes: Generate a graph database migration instruction according to the changed data obtained by the data monitoring task and the relationship mapping rule; The triggering of the data migration operation based on the migration trigger time information to migrate the changed data to the graph database according to the migration task includes: Respond to the timed trigger task triggering data migration, and start executing the graph database migration instruction at the moment corresponding to the migration trigger time information to migrate the changed data to the graph database.

8. The method according to claim 5, wherein The method further includes: Obtain the task status of the migration task; Provide the task status and the identification information corresponding to the migration task to the user.

9. The method according to claim 8, wherein The method further includes: In response to an input operation for a second prompt word template, generate task stop description information according to the input information and the second prompt word template; Perform intent recognition on the task stop description information to obtain intent information for stopping the task; Terminate the target migration task according to the intent information for stopping the task.

10. The method according to claim 9, wherein The task stop description information includes the identification information of the target migration task; The terminating the target migration task according to the intent information for stopping the task includes: Cancel the data listening task corresponding to the target migration task according to the identification information of the target migration task; Cancel the timed trigger task corresponding to the target migration task based on the identification information of the target migration task.

11. The method according to claim 1, wherein The triggering, based on the migration trigger time information, a data migration operation to migrate the changed data to the graph database according to the migration task includes: Obtain system operation attribute information; Adjust the thread speed corresponding to the migration task and / or the batch task speed of multiple migration tasks according to the system operation attribute information.

12. A data migration device, characterized in that, Includes: An intent recognition module, configured to obtain migration task description information, perform intent recognition on the migration task description information to obtain migration intent information; A first task processing module, configured to generate a migration task according to the migration intent information, monitor changes to target data according to the migration task to obtain changed data, and determine migration trigger time information according to the migration task; A second task processing module, configured to trigger a data migration operation based on the migration trigger time information to migrate the changed data to the graph database according to the migration task.

13. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the method according to any one of claims 1 to 11.

14. An electronic device, characterized in that, Includes: A processor; And A memory, configured to store executable instructions of the processor; Wherein, the processor is configured to execute the method according to any one of claims 1 to 11 by executing the executable instructions.

Citation Information

Patent Citations

  • Data migration method and system, computing equipment and storage medium

    CN113468143A

  • Task processing method and device, electronic equipment and storage medium

    CN113761127A

  • Data migration method and device

    CN114048190A

  • Data migration method and device for heterogeneous database, equipment and storage medium

    CN115495440A

  • Data table migration method and device, electronic equipment and storage medium

    CN118519982A