Data migration method and device, electronic equipment and storage medium

By displaying an interactive interface of production data in a smart factory and generating and migrating business archive requirements, the problem of inappropriate batch migration of data in the existing technology is solved, and the accuracy and storage efficiency of data migration are achieved.

CN119311666APending Publication Date: 2025-01-14HANGZHOU HOLLYSYS AUTOMATION
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411347435.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-26
Publication Date
2025-01-14

AI Technical Summary

Technical Problem

The existing technology can only batch migrate archived data, but cannot perform data migration according to business logic, resulting in poor data migration effect.

Method used

By displaying an interactive interface containing production data, generate business archive requirements in response to user operations, determine and display the target migration data, and migrate it to the archive service after the user confirms it.

Benefits of technology

It realizes accurate positioning and migration of data according to users' business needs, saves storage space, avoids storage pressure caused by batch migration, and ensures the stability of the production environment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119311666A_ABST
    Figure CN119311666A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of computer information, and provides a data migration method and device, electronic equipment and a storage medium. The method comprises the following steps: displaying an interactive interface containing production data in production service; in response to a first trigger operation for the production data, generating a service archiving demand, the service archiving demand being used for representing data needing to be archived; determining target migration data from the production data according to the business archiving demand, and displaying the target migration data in the interactive interface; and in response to a second trigger operation for the target migration data, migrating the target migration data to migrate the target migration data into the archiving service, the first trigger operation being an operation triggered by a user according to own service requirements, so that the service archiving requirements can accurately represent data needing to be archived, and the archiving efficiency is improved. And subsequently determining the target migration data according to the service archiving demand, thereby realizing accurate positioning of the target migration data needing to be migrated according to the service demand of the user.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer information technology, and in particular to a data migration method, device, electronic device and storage medium. Background Art

[0002] With the development of science and technology, smart factories have emerged. Smart factories are modern factories that use advanced information technology and automation technology to achieve intelligent monitoring, analysis and optimization control of the entire production process to improve production efficiency, product quality and operational flexibility.

[0003] Smart factories generate a large amount of production data during the production process. The more production data is stored, the greater the storage space and access speed pressure will be. In addition, many historical production data do not need to be accessed frequently. Therefore, this part of the data needs to be migrated and archived. However, the existing technology can only migrate archived data in batches, and cannot migrate archived data according to certain business logic. Summary of the invention

[0004] In view of this, the embodiments of the present application provide a data migration method, device, electronic device and storage medium to solve the problem in the prior art that data can only be archived in batches and the archived data cannot be migrated according to business logic, resulting in poor data migration effect.

[0005] According to a first aspect of an embodiment of the present application, a data migration method is provided, the method comprising: displaying an interactive interface containing production data in a production service; generating a business archiving requirement in response to a first trigger operation on the production data, the business archiving requirement being used to characterize the data that needs to be archived; determining target migration data from the production data according to the business archiving requirement, and displaying the target migration data through the interactive interface; and migrating the target migration data in response to a second trigger operation on the target migration data, so as to migrate the target migration data to the archiving service.

[0006] According to a second aspect of an embodiment of the present application, a data migration device is provided, which includes: a display module for displaying an interactive interface containing production data in a production service; a requirement module for generating a business archiving requirement in response to a first trigger operation on the production data, the business archiving requirement being used to characterize the data that needs to be archived; a determination module for determining target migration data from the production data according to the business archiving requirement, and displaying the target migration data through an interactive interface; and a migration module for migrating the target migration data in response to a second trigger operation on the target migration data, so as to migrate the target migration data to the archiving service.

[0007] According to a third aspect of an embodiment of the present application, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above method when executing the computer program.

[0008] According to a fourth aspect of an embodiment of the present application, a computer-readable storage medium is provided, which stores a computer program, and when the computer program is executed by a processor, the steps of the above method are implemented.

[0009] Compared with the prior art, the embodiments of the present application have the following beneficial effects: the method of the embodiments of the present application displays an interactive interface containing production data in a production service; in response to a first trigger operation on the production data, a business archiving requirement is generated, and the business archiving requirement is used to characterize the data that needs to be archived; target migration data is determined from the production data according to the business archiving requirement, and the target migration data is displayed through the interactive interface; in response to a second trigger operation on the target migration data, the target migration data is migrated to migrate the target migration data to the archiving service, the first trigger operation is an operation triggered by the user according to his own business needs, so the business archiving requirement can accurately characterize the data that needs to be archived, and the target migration data is subsequently determined according to the business archiving requirement, so that the target migration data that needs to be migrated is accurately located according to the user's business needs, and the target migration data is migrated according to the second trigger operation, which can not only ensure that the storage of the existing production environment is not affected and save storage space, but also retain useful production data according to different business needs and migrate the target archive data, thereby avoiding the problem in the related technology that data can only be archived in batches and the archived data cannot be migrated according to business logic, resulting in poor data migration effect. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0011] Figure 1 It is a flowchart of a data migration method provided in an embodiment of the present application;

[0012] Figure 2 This is a basic flow chart of a data migration method provided by an embodiment of the present application;

[0013] Figure 3 It is a flowchart of another data migration method provided in an embodiment of the present application;

[0014] Figure 4 It is a flowchart of another data migration method provided in an embodiment of the present application;

[0015] Figure 5 It is a flowchart of another data migration method provided in an embodiment of the present application;

[0016] Figure 6 It is a flowchart of another data migration method provided in an embodiment of the present application;

[0017] Figure 7 is a flowchart of another optional data migration method provided in an embodiment of the present application;

[0018] Figure 8 It is a flowchart of another optional data migration method provided in an embodiment of the present application;

[0019] Fig. 9 It is a structural schematic diagram of a data migration device provided in an embodiment of the present application;

[0020] Fig.10 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0021] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.

[0022] A data migration method and device according to an embodiment of the present application will be described in detail below with reference to the accompanying drawings.

[0023] Figure 1 This is a data migration method provided by an embodiment of the present application, such as Figure 1 As shown, the method includes:

[0024] S101, displaying an interactive interface containing production data in a production service;

[0025] S102, generating a business archiving requirement in response to a first triggering operation on production data;

[0026] S103, determining target migration data from production data according to business archiving requirements, and displaying the target migration data through an interactive interface;

[0027] S104: In response to a second trigger operation on the target migration data, migrate the target migration data to migrate the target migration data to the archiving service.

[0028] It can be understood that the data migration method provided in this example is applied to a terminal and / or a server, which can collect production data generated by the smart factory during the production process; in order to better illustrate this method, the data migration method provided in this example will be applied to the server as an example for explanation.

[0029] In some examples, such as Figure 2 As shown, software developers pre-set the information model corresponding to the production service in the development environment, and subsequent users can generate production data through the information model corresponding to the production service. Specifically, the user (user) selects the structure of the table and field according to the interactive interface provided by the information model corresponding to the production service (exemplarily, the database table and field structure built in the information model corresponding to the production service are checked), and the database table required by the business and the interface provided to the outside are automatically generated, saving the efficiency of writing code again; software developers pre-set the information model corresponding to the archiving service in the development environment, and subsequent relevant personnel can archive data through the information model corresponding to the archiving service.

[0030] It is understandable that the server can display an interactive interface containing production data in the production service, and the user can interact with the interactive interface containing production data in the production service to add, delete, check and modify the production data. In the solution provided in this example, the user can also input a first trigger operation through the interactive interface containing production data in the production service to generate a business archiving requirement, which is used to characterize the data that needs to be archived, wherein the first trigger operation is used to select the data in the interactive interface, and the first trigger operation is an operation triggered by the user according to his own business needs. This method realizes the visual operation of business archiving needs and simplifies the problem that the traditional archiving migration solution requires a lot of native development and adaptation.

[0031] After generating the business archiving requirement, in this example, the server will determine the target migration data from the production data according to the business archiving requirement, and display the target migration data through an interactive interface; it can be understood that the more production data is stored, the greater the storage space and access speed pressure will be, and a lot of historical production data does not need to be accessed frequently, so this part of the data needs to be migrated and archived. Therefore, this example will determine the target migration data according to the above business archiving requirement, so as to accurately locate the target migration data that needs to be migrated according to the user's business needs.

[0032] In some examples, the server displays the target migration data through an interactive interface, and the user can determine whether the target migration data meets the business needs through the displayed results. When the user determines that the target migration data meets his or her own business needs, a second trigger operation for the target migration data is issued through the interactive interface. The second trigger operation is used to instruct the migration of the target migration data to migrate the target migration data to the archiving service.

[0033] According to the technical solution provided in the embodiment of the present application, an interactive interface containing production data in a production service is displayed; in response to a first trigger operation on the production data, a business archiving requirement is generated, and the business archiving requirement is used to characterize the data that needs to be archived; according to the business archiving requirement, target migration data is determined from the production data, and the target migration data is displayed through the interactive interface; in response to a second trigger operation on the target migration data, the target migration data is migrated to migrate the target migration data to the archiving service. The first trigger operation is an operation triggered by the user according to his own business needs, so the business archiving requirement can accurately characterize the data that needs to be archived. Subsequently, the target migration data is determined according to the business archiving requirement, and the target migration data that needs to be migrated is accurately located according to the user's business needs. The target migration data is migrated according to the second trigger operation, which can not only ensure that the storage of the existing production environment is not affected and save storage space, but also retain useful production data according to different business needs and migrate the target archive data, thereby avoiding the problem in the related technology that data can only be archived in batches and the archived data cannot be migrated according to business logic, resulting in poor data migration effect.

[0034] In some embodiments, the production data includes: a plurality of data tables, each of which includes a plurality of data fields, such as Figure 3 As shown, in response to a first trigger operation on production data, a business archiving requirement is generated, including:

[0035] S301, receiving a first trigger operation for multiple data tables, and determining a target data table and a target data field;

[0036] S302: Generate business archiving requirements based on the target data table and target data fields.

[0037] It can be understood that the production data includes: multiple data tables, the data tables include multiple data fields, and the user's business needs may be to migrate all the data in a certain data table, or to migrate the data of a certain field in a certain data table.

[0038] In this example, the server receives the first trigger operation of the user for multiple data tables, and determines the target data table structure and the target data field. For example, the server provides A, B, C, D...N data tables through an interactive interface, and the user can select any data table as the target data table, and the user can also select a field in any data table as the target data field.

[0039] Continuing from the above example, after determining the target data table and the target data field, this example further generates a business archiving requirement based on the target data table and the target data field; illustratively, the target data table and the target data field are combined to obtain the business archiving requirement.

[0040] According to the technical solution provided in the embodiment of the present application, a first trigger operation for multiple data tables is received, and the target data table and the target data field are determined; based on the target data table and the target data field, a business archiving requirement is generated, so that the business archiving requirement can accurately reflect the user's business needs.

[0041] In some embodiments, Figure 4 As shown in the figure, target migration data is determined from production data based on business archiving requirements, including:

[0042] S401, determining initial migration data from production data according to a preset data determination rule;

[0043] S402: According to the target data table structure and target data fields included in the business archiving requirement, the initial migration data is retrieved to obtain the target migration data.

[0044] It is understandable that a smart factory will generate a large amount of production data during the production process. The more production data is stored, the greater the storage space and access speed pressure will be, and a lot of historical production data does not need to be accessed frequently, so this part of the data needs to be migrated and archived; that is, the production data may include recently generated production data and data that needs to be migrated. In order to avoid the transfer of recently generated and frequently used production data, which may lead to erroneous migration behavior, this example will further determine the initial migration data from the production data based on the preset data determination rules.

[0045] Among them, determining the initial migration data from the production data according to the preset data determination rules includes but is not limited to: determining the initial migration data from the production data according to the frequency of data usage, and / or determining the initial migration data from the production data according to the data generation time; determining the initial migration data from the production data according to the data usage frequency, including: obtaining the usage frequency of each data in the production data, and taking the data with a usage frequency lower than the preset frequency as the initial migration data; determining the initial migration data from the production data according to the data generation time, including: obtaining the generation time of each data in the production data, and taking the data with a generation time exceeding the preset time as the initial migration data.

[0046] After determining the initial migration data, this example retrieves the initial migration data based on the target data table structure and target data fields included in the business archiving requirements to obtain the target migration data, thereby avoiding erroneous migration behavior caused by transferring recently generated and frequently used production data.

[0047] According to the technical solution provided in the embodiment of the present application, the initial migration data is determined from the production data according to the preset data determination rules; the initial migration data is retrieved according to the target data table structure and the target data field included in the business archiving requirements to obtain the target migration data, wherein the initial migration data is determined from the production data according to the preset data determination rules, so that only the production data that is not recently generated and / or is not frequently used is used as the initial migration data, and the production data that is recently generated and / or frequently used will not be used as the initial migration data later, thereby avoiding the transfer of the production data that is recently generated and needs to be used frequently, resulting in erroneous migration behavior.

[0048] In some embodiments, Figure 5 As shown, in response to the second trigger operation on the target migration data, the target migration data is migrated, including:

[0049] S501, in response to a second trigger operation on target migration data, determining a production database address and an archive database address of the target migration data;

[0050] S502: Obtain target migration data according to the production database address, and migrate the target migration data to the archive database address.

[0051] Specifically, in response to the second trigger operation for the target migration data, the server determines the production database address and the archive database address of the target migration data, where the production database address is the address of the target migration data in the database corresponding to the production service, and the archive database address is the target address of the target migration data in the database corresponding to the archive service after the target migration data is migrated to the archive service.

[0052] In which, in response to the second trigger operation, the server determines the production database address of the target migration data from the production service and the archive database address from the archive service. Then, the target migration data is obtained according to the production database address, and the target migration data is migrated to the archive database address. The above migration may be to cut the target migration data from the production database address to the archive database address, or to copy the target migration data from the production database address to the archive database address, and then delete the target migration data in the production database address; in some examples, when copying the target migration data from the production database address to the archive database address, the target migration data in the production database address may not be deleted.

[0053] In order to better understand the present method, this embodiment provides a more specific example for illustration. Figure 2 As shown, first, the application front end or business back end obtains the user's business needs by calling the external interface (the interface exposed by the production service) automatically generated by the information model of the production service. The business needs can determine the target data table and the target data field, and then determine the business archiving needs based on the target data table and the target data field; the production service binds the business archiving needs and a corresponding functional module and stores them in its own database; and determines the target migration data based on the target data table and the target data field, and then passes the business table, the production data in the production service, and the target migration data to the information system integration for copying and storing the target migration data; the information system integration is used to synchronize the target migration data to the database corresponding to the archiving service; wherein, the information system integration has a visual interface in the production environment, and configures the target data table and the target data field to be archived through the interface according to the user's business needs, and selects the production database address and the archiving database address corresponding to the production data. It can also customize and develop its own archiving visual interface through the external interface provided by the information system integration.

[0054] That is, in this example, the user queries the table structure information by calling the information model in the production service, and the corresponding server displays an interactive interface containing the production data in the production service, such as Figure 6 As shown, the user then generates a business archiving requirement through the first trigger operation. Specifically, the user checks the target data table and the target data field. After receiving the target data table and the target data field, the backend assembles and generates the business archiving requirement. The production database of the production service stores the business archiving requirement. When the user subsequently selects the business archiving requirement, the backend queries the corresponding migration data according to the business archiving requirement. The production service returns the target migration data. The application front end calls the API interface given by the archiving service to the information system integration. The information system integration executes the migration archiving of the target migration data and migrates the target migration data to the archiving service by copying.

[0055] This method can determine the target migration data according to different business archiving requirements, rather than mechanically migrating all production data. It can make full use of its own business characteristics to migrate, save, and distinguish historical and production data.

[0056] According to the technical solution provided in the embodiment of the present application, in response to the second trigger operation for the target migration data, the production database address and the archive database address of the target migration data are determined; the target migration data is obtained according to the production database address, and the target migration data is migrated to the archive database address. The above method is used to migrate the target migration data from the production database address to the archive database address.

[0057] In some examples, such as Figure 7 As shown, in response to the second trigger operation on the target migration data, after migrating the target migration data, the method further includes:

[0058] S701, obtaining the growth rate of production data in production services;

[0059] S701. A migration cycle corresponding to a business archiving requirement is set according to a growth rate, and new target migration data is migrated according to new target migration data determined according to the migration cycle.

[0060] The method provided in this example can also automatically transfer the production data in the production service; specifically, in this example, the growth rate of the production data in the production service is obtained, and then the migration cycle is determined according to the growth rate; it can be understood that the higher the growth rate, the shorter the migration cycle; the lower the growth rate, the longer the migration cycle; wherein, the specific relationship between the growth rate and the migration cycle can be flexibly set by relevant personnel according to actual needs.

[0061] After determining the migration cycle, this example will periodically determine new target migration data according to the migration cycle and migrate the new target migration data. For example, if the migration cycle is two days, then every two days, the new target migration data will be re-determined from the production data according to the business archiving requirements, and the new target migration data will be automatically migrated; for another example, if the migration cycle is three months, then every three months, the server will re-determine new target migration data from the production data according to the business archiving requirements, and automatically migrate the new target migration data.

[0062] According to the technical solution provided in the embodiment of the present application, the growth rate of production data in production services is obtained; the migration period corresponding to the business archiving demand is set according to the growth rate, and the new target migration data is migrated according to the new target migration data determined by the migration period, thereby realizing automatic determination of new target migration data according to the user's business needs, avoiding manual operation by the user, and improving the user experience; the above method realizes visual configuration of business archiving needs according to the user's needs, and after determining the business archiving needs, the migration period of data archiving can be customized according to the growth rate of production data and incremental archiving can be supported. In general, the data migration method can realize the migration and archiving of production data in smart factories more efficiently, more simply and more flexibly, and plays an important role in improving production efficiency, saving energy and reducing costs, ensuring the safety of production data, and fast and efficient storage and migration.

[0063] In some examples, such as Figure 8 As shown, in response to the second trigger operation on the target migration data, after migrating the target migration data, the method further includes:

[0064] S801, displaying a data query interface, and determining a target service from production services and archive services in response to a triggering operation of a query control in the data query interface;

[0065] S802: In response to a query operation on a query control, data is retrieved from a target service, and the retrieval result is displayed.

[0066] Specifically, users can query and / or call data in production services, and users can also query and / or call data in archive services. Exemplarily, this example will display a data query interface, and in response to the trigger operation of the query control in the data query interface, the target service is determined from the production service and the archive service; that is, the user can freely choose the data to be queried and / or called in the production service and the archive service. When the user's trigger operation selects the production service, the production service is used as the target service; when the user's trigger operation selects the archive service, the archive service is used as the target service.

[0067] After the target service is determined, in response to a query operation on the query control, data is retrieved from the target service and the retrieval result is displayed, so that the user can query the data in the target service.

[0068] It is understandable that when users are producing services, they can call production data through the production database and archive data through the archive database at any time. Users can quickly query production data through the production database, and can also quickly query archived data through the archive service, such as Figure 6 shown.

[0069] According to the technical solution provided in the embodiment of the present application, a data query interface is displayed, and in response to the triggering operation of the query control in the data query interface, a target service is determined from the production service and the archiving service; in response to the query operation on the query control, data is retrieved from the target service, and the retrieval results are displayed, so that users can efficiently query the production data and the archived data. The method transfers the target migration data to another archiving service, which also provides the same access capability as the production environment, is completely indistinguishable from the production environment, except that the access efficiency is reduced, but it meets the expectation of only providing relatively inefficient historical data and historical tracing problems.

[0070] All the above optional technical solutions can be arbitrarily combined to form optional embodiments of the present application, which will not be described one by one here.

[0071] The following is an embodiment of the device of the present application, which can be used to execute the embodiment of the method of the present application. For details not disclosed in the embodiment of the device of the present application, please refer to the embodiment of the method of the present application.

[0072] This embodiment also provides a data migration device, such as Fig. 9 As shown, the device comprises:

[0073] Display module 901, used to display an interactive interface containing production data in the production service;

[0074] A requirement module 902, configured to generate a business archiving requirement in response to a first trigger operation on production data, where the business archiving requirement is used to characterize data that needs to be archived;

[0075] A determination module 903 is used to determine target migration data from production data according to business archiving requirements, and to display the target migration data through an interactive interface;

[0076] The migration module 904 is configured to migrate the target migration data in response to a second trigger operation on the target migration data, so as to migrate the target migration data to the archiving service.

[0077] In some examples, the migration module 904 is also used to determine the production database address and archive database address of the target migration data in response to a second trigger operation on the target migration data; obtain the target migration data according to the production database address, and migrate the target migration data to the archive database address.

[0078] In some examples, the production data includes: multiple data tables, each data table includes multiple data fields; the requirement module 902 is also used to receive a first trigger operation for the multiple data tables, determine the target data table and the target data field; and generate a business archiving requirement based on the target data table and the target data field.

[0079] In some examples, the determination module 903 is also used to determine the initial migration data from the production data according to a preset data determination rule; retrieve the initial migration data according to the target data table structure and target data fields included in the business archiving requirements to obtain the target migration data.

[0080] In some examples, the migration module 904 is also used to obtain the growth rate of production data in production services; set the migration cycle corresponding to the business archiving requirements according to the growth rate, and migrate the new target migration data according to the new target migration data determined by the migration cycle.

[0081] In some examples, the migration module 904 is also used to display a data query interface, determine a target service from production services and archive services in response to a trigger operation of a query control in the data query interface, retrieve data from the target service in response to a query operation on the query control, and display the retrieval results.

[0082] According to the technical solution provided in the embodiment of the present application, the data migration device provided in the embodiment displays an interactive interface containing production data in the production service; in response to a first trigger operation on the production data, a business archiving requirement is generated, and the business archiving requirement is used to characterize the data that needs to be archived; according to the business archiving requirement, the target migration data is determined from the production data, and the target migration data is displayed through the interactive interface; in response to a second trigger operation on the target migration data, the target migration data is migrated to migrate the target migration data to the archiving service, the first trigger operation is an operation triggered by the user according to his own business needs, so the business archiving requirement can accurately characterize the data that needs to be archived, and the target migration data is subsequently determined according to the business archiving requirement, so as to achieve accurate positioning of the target migration data that needs to be migrated according to the user's business needs, and the target migration data is migrated according to the second trigger operation, which can not only ensure that the storage of the existing production environment is not affected and save storage space, but also retain useful production data according to different business needs, migrate the target archive data, and avoid the problem in the related technology that only batch archive data can be archived and the archive data cannot be migrated according to business logic, resulting in poor data migration effect.

[0083] Fig.10 Schematic diagram of an electronic device 10 provided in an embodiment of the present application. Fig.10 As shown, the electronic device 10 of this embodiment includes: a processor 1001, a memory 1002, and a computer program 1003 stored in the memory 1002 and executable on the processor 1001. When the processor 1001 executes the computer program 1003, the steps in the above-mentioned method embodiments are implemented. Alternatively, when the processor 1001 executes the computer program 1003, the functions of the modules / units in the above-mentioned device embodiments are implemented.

[0084] The electronic device 10 may be a desktop computer, a notebook, a PDA, a cloud server, or other electronic device. The electronic device 10 may include, but is not limited to, a processor 1001 and a memory 1002. Those skilled in the art will appreciate that Fig.10 The electronic device 10 is merely an example and does not limit the electronic device 10 . The electronic device 10 may include more or fewer components than shown in the figure, or different components.

[0085] The processor 1001 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.

[0086] The memory 1002 may be an internal storage unit of the electronic device 10, for example, a hard disk or memory of the electronic device 10. The memory 1002 may also be an external storage device of the electronic device 10, for example, a plug-in hard disk, a smart memory card (Smart Med ia Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the electronic device 10. The memory 1002 may also include both an internal storage unit of the electronic device 10 and an external storage device. The memory 1002 is used to store computer programs and other programs and data required by the electronic device.

[0087] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units.

[0088] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. The computer program may include computer program code, and the computer program code may be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of regional requirements and patent practice. For example, in some areas, according to regional requirements and patent practice, the computer-readable medium does not include electric carrier signals and telecommunication signals.

[0089] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.

Claims

1. A data migration method, characterized in that: The method comprises: Display an interactive interface containing production data from a production service; In response to a first trigger operation on the production data, generating a business archiving requirement, wherein the business archiving requirement is used to characterize the data that needs to be archived; Determining target migration data from the production data according to the business archiving requirements, and displaying the target migration data through the interactive interface; In response to a second trigger operation on the target migration data, the target migration data is migrated to migrate the target migration data to an archiving service.

2. The method according to claim 1, characterized in that The production data includes: a plurality of data tables, each of which includes a plurality of data fields; in response to a first trigger operation on the production data, generating a business archiving requirement includes: receiving the first trigger operation for the plurality of data tables, and determining a target data table and a target data field; The business archiving requirement is generated according to the target data table and the target data field.

3. The method according to claim 2, characterized in that Determining target migration data from the production data according to the business archiving requirement includes: Determining initial migration data from the production data according to a preset data determination rule; According to the target data table structure and the target data field included in the business archiving requirement, the initial migration data is retrieved to obtain the target migration data.

4. The method according to claim 1, characterized in that In response to a second trigger operation on the target migration data, migrating the target migration data includes: In response to the second trigger operation on the target migration data, determining a production database address and an archive database address of the target migration data; The target migration data is acquired according to the production database address, and the target migration data is migrated to the archive database address.

5. The method according to claim 1, characterized in that In response to a second trigger operation on the target migration data, after migrating the target migration data, the method further includes: Obtaining a growth rate of the production data in the production service; A migration period corresponding to the business archiving requirement is set according to the growth rate, and new target migration data is migrated according to new target migration data determined according to the migration period.

6. The method according to claim 5, characterized in that In response to a second trigger operation on the target migration data, after migrating the target migration data, the method further includes: Displaying a data query interface, and determining a target service from the production service and the archive service in response to a triggering operation of a query control in the data query interface; In response to a query operation on the query control, data is retrieved from the target service and the retrieval result is displayed.

7. A data migration device, characterized in that: The device comprises: A display module, used to display an interactive interface containing production data in the production service; A demand module, configured to generate a business archiving demand in response to a first trigger operation on the production data, wherein the business archiving demand is used to characterize the data that needs to be archived; A determination module, configured to determine target migration data from the production data according to the business archiving requirement, and to display the target migration data through the interactive interface; The migration module is used to migrate the target migration data in response to a second trigger operation on the target migration data, so as to migrate the target migration data to an archiving service.

8. The device according to claim 7, characterized in that The migration module is also used to determine the production database address and archive database address of the target migration data in response to the second trigger operation on the target migration data; obtain the target migration data according to the production database address, and migrate the target migration data to the archive database address.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.