CN113742212A - New and old system migration test method and device - Google Patents
New and old system migration test method and device Download PDFInfo
- Publication number
- CN113742212A CN113742212A CN202110741252.XA CN202110741252A CN113742212A CN 113742212 A CN113742212 A CN 113742212A CN 202110741252 A CN202110741252 A CN 202110741252A CN 113742212 A CN113742212 A CN 113742212A
- Authority
- CN
- China
- Prior art keywords
- new
- data
- comparison
- service
- old
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000013509 system migration Methods 0.000 title claims abstract description 33
- 238000010998 test method Methods 0.000 title claims abstract description 11
- 238000004891 communication Methods 0.000 claims abstract description 56
- 238000012360 testing method Methods 0.000 claims abstract description 48
- 238000000034 method Methods 0.000 claims abstract description 43
- 238000000547 structure data Methods 0.000 claims abstract description 21
- 238000013508 migration Methods 0.000 claims description 56
- 230000005012 migration Effects 0.000 claims description 56
- 238000004590 computer program Methods 0.000 claims description 17
- 230000008569 process Effects 0.000 abstract description 23
- 238000012795 verification Methods 0.000 abstract description 7
- 230000006870 function Effects 0.000 description 56
- 238000010586 diagram Methods 0.000 description 13
- 238000012545 processing Methods 0.000 description 13
- 238000006243 chemical reaction Methods 0.000 description 6
- 239000000872 buffer Substances 0.000 description 4
- 238000004458 analytical method Methods 0.000 description 3
- 238000012546 transfer Methods 0.000 description 3
- 238000005538 encapsulation Methods 0.000 description 2
- 230000000977 initiatory effect Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000006978 adaptation Effects 0.000 description 1
- 238000013459 approach Methods 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 230000001413 cellular effect Effects 0.000 description 1
- 238000012217 deletion Methods 0.000 description 1
- 230000037430 deletion Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000007613 environmental effect Effects 0.000 description 1
- 239000011521 glass Substances 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000012827 research and development Methods 0.000 description 1
- 230000000717 retained effect Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3684—Test management for test design, e.g. generating new test cases
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/21—Design, administration or maintenance of databases
- G06F16/214—Database migration support
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/76—Adapting program code to run in a different environment; Porting
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Software Systems (AREA)
- Data Mining & Analysis (AREA)
- Debugging And Monitoring (AREA)
Abstract
The invention provides a new and old system migration test method and a device, which can be used in the technical field of finance, and comprises the following steps: acquiring bottom layer structure data generated when an old system and a new system run; comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule; if the comparison is passed, the success of the new and old system migration is determined, and the verification of the integrity and the correctness of the service function is carried out on the new and old services in different stages in different scenes by automatically combining and using the comparison of the communication area and the comparison of the table structure and the data record in the new and old system migration process, so that the working efficiency of the banking service test is improved.
Description
Technical Field
The invention relates to the technical field of internet finance, in particular to a new and old system migration testing method and device.
Background
Each bank gradually develops the domestic research and development, and realizes the functions of the existing business in a host (IBM mainframe) on a distributed open platform, thereby realizing the migration of new and old systems. The migration process mainly realizes the conversion of a technical platform and a hardware system, the original service function is kept unchanged, and the integrity and the correctness of the original function are required to be ensured after the migration; meanwhile, in order to ensure stable operation of the system during migration, a gradual migration mode needs to be considered, and parallel support of the platform and the host service is realized in one service transaction, namely, the original host service function needs to be reserved, and the platform part function needs to be realized.
Due to the adoption of complex conditions such as gradual migration, parallel operation and the like, a rapid and uniform comparison tool is lacked.
Disclosure of Invention
Aiming at the migration process in the prior art, the conversion of a technical platform and a hardware system is mainly realized, the original service function is kept unchanged, and the integrity and the correctness of the original function are required to be ensured after the migration; meanwhile, in order to ensure the stable operation of the system during migration, a gradual migration mode needs to be considered, the parallel operation of a platform and a host is supported in a service transaction, namely the original host service function is kept, and partial functions of the platform are realized, so that the migration condition is extremely complex, the complex conditions of gradual migration, parallel operation and the like are adopted, a rapid and unified comparison tool is lacked, and the problems are all solved through manual operation at present.
In order to solve the technical problems, the invention provides the following technical scheme:
an embodiment of a first aspect of the present invention provides a new and old system migration testing method, including:
acquiring bottom layer structure data generated when an old system and a new system run;
comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule;
and if the comparison is passed, determining that the new system and the old system are successfully migrated.
In a preferred embodiment, the infrastructure data comprises: the interface serves the corresponding source code data and the original metadata information of the transaction registration.
In a preferred embodiment, the comparing the infrastructure data corresponding to the old system and the new system based on the set comparison rule includes:
analyzing the source code data corresponding to the interface service, and analyzing the communication area definition of the service interface;
obtaining a heterogeneous database and a homologous table data record according to the original metadata information registered by the transaction;
and comparing the communication area definition, the heterogeneous database and the homologous table data record.
In a preferred embodiment, the step of comparing the definitions of the communication areas includes:
determining field definition of a return output of the service interface according to the communication area definition of the service interface;
respectively calling the corresponding interface services of the new system and the old system by using the same transaction request;
and comparing all fields returned to the communication area after the two transaction requests are initiated, and marking field differences.
In a preferred embodiment, the heterogeneous table comprises: DB2 database tables and open platform MySQl database tables; the step of comparing the data records of the heterogeneous database and the homologous table comprises the following steps:
writing the same transaction data into the DB2 database table and an open platform MySQl database table;
according to a preset table comparison table, searching a field relation of the DB2 database table corresponding to the open platform MySQl database table;
and determining whether the data of the corresponding fields are consistent or not according to the field relation, and the transaction data written in the DB2 database table and the open platform MySQl database table.
An embodiment of a second aspect of the present invention provides a new and old system migration testing apparatus, including:
the acquisition module is used for acquiring bottom layer structure data generated when the old system and the new system run;
the comparison module is used for comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule;
and the migration determining module is used for determining that the new system and the old system are successfully migrated if the comparison is passed.
In a preferred embodiment, the infrastructure data comprises: the interface serves the corresponding source code data and the original metadata information of the transaction registration.
In a preferred embodiment, the alignment module includes:
the communication area definition unit analyzes the source code data corresponding to the interface service and analyzes the communication area definition of the service interface;
the table data recording unit is used for obtaining a heterogeneous database and a homologous table data record according to the original metadata information registered in the transaction;
and the comparison unit is used for comparing the communication area definition, the heterogeneous database and the homologous table data record.
In a preferred embodiment, the alignment unit comprises:
the field definition unit is used for determining the field definition of the returned output of the service interface according to the communication area definition of the service interface;
the interface calling unit is used for calling the interface services corresponding to the new system and the old system respectively by using the same transaction requests;
and the difference marking unit compares all the fields returned to the communication area after the two transaction requests are initiated and marks the field difference.
In a preferred embodiment, the heterogeneous table comprises: DB2 database tables and open platform MySQl database tables; the alignment unit further comprises:
the data writing unit is used for writing the same transaction data into the DB2 database table and the open platform MySQl database table;
the searching unit is used for searching the field relation of the DB2 database table corresponding to the open platform MySQl database table according to a preset table comparison table;
and the data comparison unit is used for determining whether the data of the corresponding fields are consistent or not according to the field relation, the DB2 database table and the transaction data written in the open platform MySQl database table.
A third aspect of the present invention provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the new and old system migration testing method when executing the computer program.
A fourth aspect of the present invention provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the method for testing migration of old and new systems.
According to the technical scheme, the invention provides a new and old system migration test method and device, and the method comprises the steps of firstly obtaining bottom layer structure data generated when an old system and a new system run; then, comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule; finally, if the comparison is passed, the successful migration of the new and old systems is determined, and it can be seen that the verification method and the verification device automatically combine the comparison of the communication areas, the comparison of the table structures and the data records and verify the integrity and the correctness of the service functions in different scenes for the new and old services in different stages in the migration process of the new and old systems, thereby improving the working efficiency of bank service testing, improving the speed of processing transaction data, increasing the data throughput and reducing the waiting time of users.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a general schematic diagram of a testing method for migration of new and old systems of a bank in an embodiment of the invention.
Fig. 2 is a flowchart of a testing method for migration of new and old systems of a bank in the embodiment of the present invention.
Fig. 3 is a flowchart illustrating a migration testing method for new and old systems according to an embodiment of the present invention.
Fig. 4 is a schematic structural diagram of a new and old system migration testing apparatus in an embodiment of the present invention.
Fig. 5 is a schematic structural diagram of an electronic device in the embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some embodiments of the present invention, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that the new and old system migration test method and apparatus disclosed by the present invention can be used in the financial field, and can also be used in any field except the financial field.
In the prior art, the transfer process in the prior art mainly realizes the conversion of a technical platform and a hardware system, while the original service function remains unchanged, and after the transfer, the integrity and the correctness of the original function need to be ensured; meanwhile, in order to ensure the stable operation of the system during migration, a gradual migration mode needs to be considered, the parallel operation of a platform and a host is supported in one service transaction, namely the service function of the original host is kept, and partial functions of the platform are realized, so that the migration situation is extremely complex, the problems that the complex situations such as gradual migration, parallel operation and the like are adopted, a rapid and unified comparison tool is lacked, and the prior art is manually carried out are solved.
Aiming at various loopholes and problems existing in the prior technical scheme, the invention provides a new and old system migration test scheme, which realizes automatic comparison of a table structure of transaction result records and data records of the original EI service transaction (host transaction) and the new EI service transaction (host transaction); the automatic comparison of transaction input and output communication areas and the comparison of a table structure of transaction result records and data records on the new EI service transaction and the new ACS service transaction are realized; therefore, possible problems are automatically found, the integrity and the correctness of the original functions after the system is migrated are ensured, meanwhile, the method provided by assertion classification and independent provision is used, the influence of environment and data pollution on the automatic test is reduced as much as possible, and the accuracy of the automatic test is improved.
The invention provides a method and a device for realizing new and old system migration testing in one or more embodiments of the invention, and specifically comprises the following steps: acquiring bottom layer structure data generated when an old system and a new system run; comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule; and if the comparison is passed, determining that the new system and the old system are successfully migrated. In the invention, in the process of transferring the new and old systems, the comparison of communication areas and the comparison of table structures and data records are automatically combined and used for verifying the integrity and the correctness of the service functions in different scenes for the new and old services in different stages, thereby improving the working efficiency of bank service testing, improving the speed of processing transaction data, increasing the data throughput and reducing the waiting time of users.
It is understood that the new and old system migration testing apparatus of the present invention may be a server or a mobile terminal, and may include, for example, a smart phone, a tablet electronic device, a portable computer, a desktop computer, a Personal Digital Assistant (PDA), a smart wearable device, and the like. Wherein, intelligence wearing equipment can include intelligent glasses, intelligent wrist-watch, intelligent bracelet etc..
The new and old system migration testing device is provided with a communication module, and can be in communication connection with the service server to realize data transmission with the service server.
The new and old system migration testing apparatus and the service server may communicate with each other using any suitable network protocol, including a network protocol that has not been developed at the filing date of the present application. The network protocol may include, for example, a TCP/IP protocol, a UDP/IP protocol, an HTTP protocol, an HTTPS protocol, or the like. Of course, the network Protocol may also include, for example, an RPC Protocol (Remote Procedure Call Protocol) used above the above Protocol, a REST Protocol (Representational State Transfer Protocol), and the like.
The invention provides a new and old system migration testing method and a device, which can automatically combine the comparison of communication areas and the comparison of table structures and data records in different scenes for new and old services in different stages in the migration process of the new and old systems to verify the integrity and the correctness of service functions, thereby improving the working efficiency of bank service testing, improving the speed of processing transaction data, increasing the data throughput and reducing the waiting time of users.
The following embodiments and application examples are specifically and respectively described.
In order to solve the problems that the migration process in the prior art mainly realizes the conversion of a technical platform and a hardware system, the original service function is kept unchanged, and the integrity and the correctness of the original function are required to be ensured after the migration; meanwhile, in order to ensure stable operation of the system during migration, a gradual migration mode needs to be considered, parallel operation of a platform and a host is supported in one service transaction, namely, an original host service function needs to be reserved, and a platform part function needs to be realized, so that the migration situation is extremely complex, complex situations such as gradual migration, parallel operation and the like are adopted, a rapid and unified comparison tool is lacked, and the problems are all manually performed at present, and the invention provides an embodiment of a new and old system migration test method, which is shown in fig. 3 and specifically comprises the following contents:
step S101: and acquiring the infrastructure data generated when the old system and the new system run.
Step S102: and comparing the corresponding underlying structure data of the old system and the new system based on a set comparison rule.
Step S103: and if the comparison is passed, determining that the new system and the old system are successfully migrated.
According to the technical scheme, in the new and old system migration process, the verification of the integrity and correctness of the service function is carried out on the new and old services in different stages by automatically combining the comparison of the communication area and the comparison of the table structure and the data record in different scenes, so that the working efficiency of the bank service test is improved.
To illustrate the meaning of the underlying structural data, in one or more embodiments of the invention, the underlying structural data comprises: the interface services corresponding source code data and transaction registered original metadata information.
In order to provide an operation flow of the comparison operation, in one or more embodiments of the present invention, the comparing the infrastructure data corresponding to the old system and the new system based on the set comparison rule includes:
s21: analyzing the source code data corresponding to the interface service, and analyzing the communication area definition of the service interface;
s22: obtaining a heterogeneous database and a homologous table data record according to the original metadata information registered by the transaction;
s23: and comparing the communication area definition, the heterogeneous database and the homologous table data record.
In the above embodiment, the step of comparing the definitions of the communication areas includes:
determining field definition of a return output of the service interface according to the communication area definition of the service interface;
respectively calling the corresponding interface services of the new system and the old system by using the same transaction request;
and comparing all fields returned to the communication area after the two transaction requests are initiated, and marking field differences.
The heterogeneous table comprises: DB2 database tables and open platform MySQl database tables; the step of comparing the data records of the isomorphic database and the homologous table comprises the following steps:
writing the same transaction data into the DB2 database table and an open platform MySQl database table;
according to a preset table comparison table, searching a field relation of the DB2 database table corresponding to the open platform MySQl database table;
and determining whether the data of the corresponding fields are consistent or not according to the field relation, and the transaction data written in the DB2 database table and the open platform MySQl database table.
The following description will be made with reference to specific examples.
Fig. 1 is a general schematic diagram of a testing method for migration of new and old systems of a bank.
(1) The original transaction flow is that a host (IBM mainframe) is directly loaded from a channel (such as counter, mobile phone bank, internet bank and the like), an exposed EI original service interface is accessed, and then the functions are completed by calling other programs.
(2) The new transaction flow is to connect the open platform from the channel, access the ATS (service scene function encapsulation) service exposed by the open platform, and then complete the function by calling the rest programs.
(3) In order to ensure the migration accuracy of the new and old systems, the new ATS service provides two access paths simultaneously, one is to call the host EI new service (replacing the original EI old service) and call the rest programs of the original host to complete the functions, and the other is to call the brand-new platform ACS (service function encapsulation) service and call the rest programs of the brand-new platform to complete the functions.
(4) The two access paths are set through a switch, generally speaking, the first stage is to encapsulate ATS service and guide channel access, but the new service is passed through EI or host process is passed; the second stage is that the ATS service simultaneously accesses the host EI new service and the platform ACS service, the two processes are respectively and independently completed, and data are respectively recorded (double-write branch); the third phase is that the ATS service only calls the platform ACS service to complete the flow switching.
For the channel end, the functions provided by the old and new systems are the same, so that one transaction is to perform comparison test on three flow branches (EI original service; EI new service, ACS service). The main flow of the test method is as follows:
(1) the automatic comparison of the table structure of the transaction result records and the data records is realized for the original EI service transaction and the new EI service transaction;
(2) the automatic comparison of the transaction input and output communication areas and the comparison of the table structure of the transaction result record and the data record for the new EI service transaction and the new ACS service transaction are realized.
In some embodiments, the communication area comparison specifically includes parsing a source code of the ATS service to obtain a communication area definition of the service interface, and providing a comparison function for the transaction input structure.
Specifically, the source code of the ATS service is analyzed, and the communication area definition of the service interface is analyzed according to the JAVA reflection mode, so as to obtain the field definition of the service interface that returns OUTPUT. Then, the same transaction request is used, namely the data of the same INPUT is used, different parameter switches are set, two different calling paths of an EI new service host flow called by ATS service and an ACS service platform flow called by ATS service are taken, all fields returned to a communication area after two transactions are initiated are automatically compared, and the expected difference is marked. For example, the output type and the parameter name are the return fields of the service transaction, the return of the two transactions is compared, and the place of the mark column can be regarded as being in doubt according to the expectation.
In the invention, the data records of the heterogeneous database and the homologous table are compared, and the data records of the heterogeneous database, namely the table originally in the host DB2 database, and the table structure and the field comparison relationship of the MySQl database on the open platform are mainly analyzed; and simultaneously, providing tables based on the database of the original host DB2, and automatically analyzing and comparing the difference of the results of double writing of the same transaction (the operation of updating the database table of the host DB2 and the MySQL table of the platform by the same transaction).
Specifically, based on the original metadata information of the transaction registration, the comparison relationship between the heterogeneous databases after the migration of the old and new systems can be analyzed, for example, table T1 of the original host DB2 database includes 4 fields of T1_ a, T1_ b, T1_ c, and T1_ d, and after the migration, this table corresponds to two tables T2 and T3 of MySQL platform, each field corresponds to T2_ a and T2_ b of table T2, and T3_ c and T3_ d of table T3, and the following comparison relationship table (table 1) can be defined according to different comparison mode attributes:
TABLE 1 comparison relationship Table
Setting a transaction parameter switch, initiating the same double-write transaction, updating a host DB2 database table and a platform MySQL table of the same transaction, and automatically analyzing and comparing the difference of double-write results of the same transaction according to a predefined comparison relation table and a table based on an original host DB2 database.
In a preferred embodiment, the present invention may provide for the automatic generation and alignment of assertions. After the system sets the above-mentioned heterogeneous data structure comparison, the automatic assertion can be generated only after filling in the table structure comparison relation in the case, for example: the A host service is migrated as the X platform service, the A host service is T1, the X platform service uses T2, and the case filling T1-T2 will automatically generate assertion, and the fields T1_ a, T1_ b are automatically compared with the fields T2_ a, T2_ b. And loading, wherein the B host service is migrated to the Y platform service, the B host service uses the table T1, and the Y platform service uses the tables T2 and T3, so that the corresponding assertion can be automatically generated only by introducing the relations of T1-T2, T1-T3 and the like into the case.
In some embodiments, to automatically adapt to the expectations of different cases, assertions are isolated and provided in categories, and different cases may correspond to different assertions. The assertion of the automatic adaptation case judges whether to execute, if the transaction fails caused by environmental problems, if No Provider errors are reported, all assertions of the current case are not executed, and the case is set to skip; for each assertion, the assertion is executed only when the preorder condition of the case is satisfied, for example, in a test case of a certain bank card signing period, the current transaction is judged to return to the expectation of successful signing only when the preorder condition judges that the state of the bank card used in the current test is the state of the non-signing period. Therefore, the influence of the environment on the automatic test can be reduced to the greatest extent, and meanwhile, the influence that the automatic test result is not in accordance with the expectation due to the polluted data is avoided.
The specific flow schematic steps are given below, as shown in fig. 2:
step S01: after the automatic new-old comparison testing process is started, the scene of the case to be tested is automatically adapted, and the automatic switching setting of the transaction parameter switch is carried out.
Step S02: analyzing the source code of the interface service designed by the transaction, and analyzing the communication area definition of the service interface according to the JAVA reflection mode to obtain the field definition of the service interface returned to the OUTPUT.
Step S03: according to the original metadata information of the transaction registration, the comparison relationship of the heterogeneous databases after the new system and the old system are migrated can be obtained through analysis, and a comparison relationship table is defined.
Step S04: and automatically initiating a call, and testing and verifying the transaction.
Step S05: alignment homology table data records: the original EI service, which is the original communication flow, and the EI new service called by the ATS service are different from the former access flow, but the programs at the back end are all processed on the host, so that it is automatically checked whether the data records of the same table related to the host DB2 after the two communication flows are consistent.
Step S06: comparing heterogeneous table data records: for the double-write flow of the ATS service, namely the flow of calling an EI new service host by simultaneously walking the ATS service and the flow of calling an ACS service platform by the ATS service, the transaction data record comparison module is automatically used for double-write comparison, and whether the table of the host DB2 and the table of the platform MySQL and the records of the corresponding fields at the two sides are consistent or not is checked according to the comparison relationship.
Step S07: and returning by comparison transaction: and performing double writing processes on the ATS service, namely simultaneously performing an ATS service calling EI new service host process and performing an ATS service calling ACS service platform, and automatically analyzing and judging whether the contents of fields of OUTPUT information returned by the two processes are consistent or not.
Step S08: the expectations of different cases are automatically adapted according to the approach provided independently of the assertion classification.
Step S09: and automatically analyzing and judging whether the test result is successful.
It can be seen that the invention provides a method for testing the migration of new and old systems of a bank. The method has the following advantages:
1. through automatic comparison, the completeness and the correctness of functions of the new system and the old system after migration are automatically confirmed, assertion writing required by general automatic test verification is reduced, and meanwhile the problem of pain points of document deletion is solved.
2. The method realizes repeated execution, solves the problem of unstable functions in the migration process of the new and old systems, and avoids repeated modification.
3. And the method provided by independent assertion classification is used, so that the influence of environment and data pollution on the automatic test is reduced as much as possible, and the accuracy of the automatic test is improved.
In order to solve the problems that the migration process in the prior art mainly realizes the conversion of a technical platform and a hardware system, the original service function is kept unchanged, and the integrity and the correctness of the original function are required to be ensured after the migration; meanwhile, in order to ensure stable operation of the system during migration, a gradual migration mode needs to be considered, parallel operation of a platform and a host is supported in a service transaction, that is, an original host service function needs to be retained, and a platform part function needs to be realized, so that the migration situation is extremely complex, complex situations such as gradual migration, parallel operation and the like are adopted, a rapid and unified comparison tool is lacked, and the problems are all solved through manual operation at present, in one or more embodiments of the invention, the invention provides a new and old system migration testing method device, which comprises the following steps:
the acquisition module 11 is used for acquiring the underlying structure data generated when the old system and the new system run;
the comparison module 12 is used for comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule;
and the migration determining module 13 determines that the new system and the old system are successfully migrated if the comparison is passed.
In a preferred embodiment, the infrastructure data comprises: the interface serves the corresponding source code data and the original metadata information of the transaction registration.
The invention provides a new and old system migration testing device, which comprises the following steps of firstly, acquiring bottom layer structure data generated when an old system and a new system run; then, comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule; finally, if the comparison is passed, the successful migration of the new and old systems is determined, and it can be seen that the verification method and the verification device automatically combine the comparison of the communication area, the comparison of the table structure and the data record and verify the integrity and the correctness of the service function in different scenes for the new and old services in different stages in the migration process of the new and old systems, thereby improving the working efficiency of bank service testing, improving the speed of processing transaction data, increasing the data throughput and reducing the waiting time of users.
Based on the same inventive concept, in a preferred embodiment, the alignment module includes:
the communication area definition unit analyzes the source code data corresponding to the interface service and analyzes the communication area definition of the service interface;
the table data recording unit is used for obtaining a heterogeneous database and a homologous table data record according to the original metadata information registered in the transaction;
and the comparison unit is used for comparing the communication area definition, the heterogeneous database and the homologous table data record.
Based on the same inventive concept, in a preferred embodiment, the alignment unit includes:
the field definition unit is used for determining the field definition of the returned output of the service interface according to the communication area definition of the service interface;
the interface calling unit is used for calling the interface services corresponding to the new system and the old system respectively by using the same transaction requests;
and the difference marking unit compares all the fields returned to the communication area after the two transaction requests are initiated and marks the field difference.
Based on the same inventive concept, in a preferred embodiment, the heterogeneous table includes: DB2 database tables and open platform MySQl database tables; the alignment unit further comprises:
the data writing unit is used for writing the same transaction data into the DB2 database table and the open platform MySQl database table;
the searching unit is used for searching the field relation of the DB2 database table corresponding to the open platform MySQl database table according to a preset table comparison table;
and the data comparison unit is used for determining whether the data of the corresponding fields are consistent or not according to the field relation, the DB2 database table and the transaction data written in the open platform MySQl database table.
Based on the same inventive concept, in a preferred embodiment, the present invention can provide the functionality of automatic generation and comparison of assertions. After the heterogeneous data structures are set by the system for comparison, automatic assertion can be produced only by filling the table structure comparison relation in the case, for example: the A host service migrates to the X platform service, the A host service T1, the X platform service uses T2, and the case filling T1-T2 will automatically generate assertions, and automatically compare the fields T1_ a, T1_ b with the fields T2_ a, T2_ b. And loading, wherein the B host service is migrated to the Y platform service, the B host service uses the table T1, and the Y platform service uses the tables T2 and T3, so that the corresponding assertion can be automatically generated only by introducing the relations of T1-T2, T1-T3 and the like in the case.
In terms of hardware, in order to solve the problem that the migration process in the prior art mainly realizes the conversion of a technical platform and a hardware system, the original service function remains unchanged, and the integrity and the correctness of the original function need to be ensured after the migration; meanwhile, in order to ensure stable operation of the system during migration, a gradual migration mode needs to be considered, parallel operation of a platform and a host is supported in one service transaction, namely, an original host service function needs to be reserved, and partial functions of the platform need to be realized, so that the migration situation is extremely complex, the problems that a rapid and uniform comparison tool is lacked and the complex situations such as gradual migration, parallel operation and the like are adopted, and the prior art are all problems of manual operation are solved, the invention provides an embodiment of electronic equipment for realizing all or part of contents in the new and old system migration test method, and the electronic equipment comprises the following contents:
fig. 5 is a schematic block diagram of an apparatus configuration of an electronic device 9600 according to an embodiment of the present invention. As shown in fig. 5, the electronic device 9600 can include a central processor 9100 and a memory 9140; the memory 9140 is coupled to the central processor 9100. Notably, this FIG. 5 is exemplary; other types of structures may also be used in addition to or in place of the structure to implement telecommunications or other functions.
In one embodiment, the new and old system migration test method functions may be integrated into a central processor. Wherein the central processor may be configured to control:
step S101: and acquiring the infrastructure data generated when the old system and the new system run.
Step S102: and comparing the corresponding underlying structure data of the old system and the new system based on a set comparison rule.
Step S103: and if the comparison is passed, determining that the new system and the old system are successfully migrated.
According to the technical scheme, in the migration process of the old and new systems, the integrity and the correctness of the service function are verified by automatically combining the comparison of the communication areas and the comparison of the table structures and the data records in different scenes for the old and new services in different stages, so that the working efficiency of the bank service test is improved.
In another embodiment, the server may be configured separately from the central processing unit 9100, for example, the server may be a chip connected to the central processing unit 9100, and the functions of the new and old system migration test methods may be implemented by the control of the central processing unit.
As shown in fig. 5, the electronic device 9600 may further include: a communication module 9110, an input unit 9120, an audio processor 9130, a display 9160, and a power supply 9170. It is worthy to note that the electronic device 9600 also does not necessarily include all of the components shown in fig. 5; further, the electronic device 9600 may further include components not shown in fig. 5, which may be referred to in the art.
As shown in fig. 5, a central processor 9100, also sometimes referred to as a controller or operational control, may include a microprocessor or other processor device and/or logic device, which central processor 9100 receives input and controls the operation of the various components of the electronic device 9600.
The memory 9140 can be, for example, one or more of a buffer, a flash memory, a hard drive, a removable media, a volatile memory, a non-volatile memory, or other suitable device. The information relating to the failure may be stored, and a program for executing the information may be stored. And the central processing unit 9100 can execute the program stored in the memory 9140 to realize information storage or processing, or the like.
The input unit 9120 provides input to the central processor 9100. The input unit 9120 is, for example, a key or a touch input device. Power supply 9170 is used to provide power to electronic device 9600. The display 9160 is used for displaying display objects such as images and characters. The display may be, for example, an LCD display, but is not limited thereto.
The memory 9140 can be a solid state memory, e.g., Read Only Memory (ROM), Random Access Memory (RAM), a SIM card, or the like. There may also be a memory that holds information even when power is off, can be selectively erased, and is provided with more data, an example of which is sometimes called an EPROM or the like. The memory 9140 could also be some other type of device. Memory 9140 includes a buffer memory 9141 (sometimes referred to as a buffer). The memory 9140 may include an application/function storage portion 9142, the application/function storage portion 9142 being used for storing application programs and function programs or for executing a flow of operations of the electronic device 9600 by the central processor 9100.
The memory 9140 can also include a data store 9143, the data store 9143 being used to store data, such as contacts, digital data, pictures, sounds, and/or any other data used by an electronic device. Driver storage portion 9144 of memory 9140 may include various drivers for the electronic device for communication functions and/or for performing other functions of the electronic device (e.g., messaging applications, contact book applications, etc.).
The communication module 9110 is a transmitter/receiver 9110 that transmits and receives signals via an antenna 9111. The communication module (transmitter/receiver) 9110 is coupled to the central processor 9100 to supply input signals and receive output signals, which may be the same as in the case of a conventional mobile communication terminal.
Based on different communication technologies, a plurality of communication modules 9110, such as a cellular network module, a bluetooth module, and/or a wireless local area network module, may be provided in the same electronic device. The communication module (transmitter/receiver) 9110 is also coupled to a speaker 9131 and a microphone 9132 via an audio processor 9130 to provide audio output via the speaker 9131 and receive audio input from the microphone 9132, thereby implementing ordinary telecommunications functions. The audio processor 9130 may include any suitable buffers, decoders, amplifiers and so forth. In addition, the audio processor 9130 is also coupled to the central processor 9100, thereby enabling recording locally through the microphone 9132 and enabling locally stored sounds to be played through the speaker 9131.
An embodiment of the present invention further provides a computer-readable storage medium capable of implementing all steps in the new and old system migration testing method in the foregoing embodiment, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the computer program implements all steps of the new and old system migration testing method in the foregoing embodiment, where the execution subject of the computer program is a server or a client, for example, when the processor executes the computer program, the processor implements the following steps:
step S101: and acquiring the infrastructure data generated when the old system and the new system run.
In the invention, the requirement analysis is an essential link in software development, and the requirement scheme is mainly used for defining scenes, processes and the like of services. The analysis and understanding of the requirement document are crucial for developers, the ambiguity can face the problem of code modification and even rewriting, and the requirement for the requirement document flow graphic is more urgent as the complexity of business logic increases.
Step S102: and comparing the corresponding underlying structure data of the old system and the new system based on a set comparison rule.
Step S103: and if the comparison is passed, determining that the new system and the old system are successfully migrated.
According to the technical scheme, the computer storage medium provided by the invention can automatically combine the comparison of the communication areas and the comparison of the table structures and the data records in different scenes for the new and old services in different stages in the migration process of the new and old systems to verify the integrity and the correctness of the service functions, thereby improving the working efficiency of the bank service test.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (devices), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The principle and the implementation mode of the invention are explained by applying specific embodiments in the invention, and the description of the embodiments is only used for helping to understand the method and the core idea of the invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and as described above, the content of the present specification should not be construed as a limitation to the present invention.
Claims (12)
1. A new and old system migration test method is characterized by comprising the following steps:
acquiring bottom layer structure data generated when an old system and a new system run;
comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule;
and if the comparison is passed, determining that the new system and the old system are successfully migrated.
2. The method according to claim 1, wherein the infrastructure data comprises: the interface services corresponding source code data and transaction registered original metadata information.
3. The method for testing migration of old and new systems according to claim 2, wherein the comparing operation of the infrastructure data corresponding to the old system and the new system based on the set comparison rule comprises:
analyzing the source code data corresponding to the interface service, and analyzing the communication area definition of the service interface;
obtaining a heterogeneous database and a homologous table data record according to the original metadata information registered by the transaction;
and comparing the communication area definition, the heterogeneous database and the homologous table data record.
4. The method according to claim 3, wherein the step of comparing the definitions of the communication areas comprises:
determining field definition of a return output of the service interface according to the communication area definition of the service interface;
respectively calling the corresponding interface services of the new system and the old system by using the same transaction request;
and comparing all fields returned to the communication area after the two transaction requests are initiated, and marking field differences.
5. The method according to claim 4, wherein the heterogeneous table comprises: DB2 database tables and open platform MySQl database tables; the step of comparing the data records of the heterogeneous database and the homologous table comprises the following steps:
writing the same transaction data into the DB2 database table and an open platform MySQl database table;
according to a preset table comparison table, searching a field relation of the DB2 database table corresponding to the open platform MySQl database table;
and determining whether the data of the corresponding fields are consistent or not according to the field relation, and the transaction data written in the DB2 database table and the open platform MySQl database table.
6. A new and old system migration testing device is characterized by comprising:
the acquisition module is used for acquiring bottom layer structure data generated when the old system and the new system run;
the comparison module is used for comparing the bottom layer structure data corresponding to the old system and the new system based on a set comparison rule;
and the migration determining module is used for determining that the new system and the old system are successfully migrated if the comparison is passed.
7. The new and old system migration testing apparatus according to claim 6, wherein the infrastructure data comprises: the interface services corresponding source code data and transaction registered original metadata information.
8. The new and old system migration testing apparatus according to claim 7, wherein the comparing module comprises:
the communication area definition unit analyzes the source code data corresponding to the interface service and analyzes the communication area definition of the service interface;
the table data recording unit is used for obtaining a heterogeneous database and a homologous table data record according to the original metadata information registered in the transaction;
and the comparison unit is used for comparing the communication area definition, the heterogeneous database and the homologous table data record.
9. The new and old system migration testing apparatus according to claim 7, wherein the comparing unit comprises:
the field definition unit is used for determining the field definition of the returned output of the service interface according to the communication area definition of the service interface;
the interface calling unit is used for calling the interface services corresponding to the new system and the old system respectively by using the same transaction requests;
and the difference marking unit compares all the fields returned to the communication area after the two transaction requests are initiated and marks the field difference.
10. The new and old system migration testing apparatus according to claim 9, wherein the heterogeneous table includes: DB2 database tables and open platform MySQl database tables; the alignment unit further comprises:
the data writing unit is used for writing the same transaction data into the DB2 database table and the open platform MySQl database table;
the searching unit is used for searching the field relation of the DB2 database table corresponding to the open platform MySQl database table according to a preset table comparison table;
and the data comparison unit is used for determining whether the data of the corresponding fields are consistent or not according to the field relation, the DB2 database table and the transaction data written in the open platform MySQl database table.
11. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method of any of claims 1 to 5 when executing the program.
12. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method of any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110741252.XA CN113742212A (en) | 2021-06-30 | 2021-06-30 | New and old system migration test method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110741252.XA CN113742212A (en) | 2021-06-30 | 2021-06-30 | New and old system migration test method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN113742212A true CN113742212A (en) | 2021-12-03 |
Family
ID=78728521
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110741252.XA Pending CN113742212A (en) | 2021-06-30 | 2021-06-30 | New and old system migration test method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113742212A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114885030A (en) * | 2022-06-02 | 2022-08-09 | 中国工商银行股份有限公司 | Service calling method, device, equipment, storage medium and program product |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150142660A1 (en) * | 2013-11-15 | 2015-05-21 | The Fusion Network LLC | Centralized financial account migration system |
CN111966665A (en) * | 2020-08-17 | 2020-11-20 | 中国银行股份有限公司 | Data migration test method and device |
CN112905459A (en) * | 2021-02-08 | 2021-06-04 | 中国工商银行股份有限公司 | Service interface testing method and device, electronic equipment and storage medium |
-
2021
- 2021-06-30 CN CN202110741252.XA patent/CN113742212A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150142660A1 (en) * | 2013-11-15 | 2015-05-21 | The Fusion Network LLC | Centralized financial account migration system |
CN111966665A (en) * | 2020-08-17 | 2020-11-20 | 中国银行股份有限公司 | Data migration test method and device |
CN112905459A (en) * | 2021-02-08 | 2021-06-04 | 中国工商银行股份有限公司 | Service interface testing method and device, electronic equipment and storage medium |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114885030A (en) * | 2022-06-02 | 2022-08-09 | 中国工商银行股份有限公司 | Service calling method, device, equipment, storage medium and program product |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3848793A1 (en) | Api-based software development platform | |
CN110413528B (en) | Intelligent configuration method and system for test environment | |
CN112463634B (en) | Software testing method and device under micro-service architecture | |
CN111796860B (en) | Micro front end scheme implementation method and device | |
CN111949522A (en) | User interface automatic testing method and device | |
CN103634393A (en) | IVR (interactive voice response) and realization method thereof | |
CN111158987B (en) | Health check method and device for micro-service architecture | |
CN112799944A (en) | System performance testing method and system | |
CN112346965A (en) | Test case distribution method, device and storage medium | |
CN113742212A (en) | New and old system migration test method and device | |
CN106990974B (en) | APP updating method and device and electronic equipment | |
CN111367561B (en) | Remote development method and device for software program | |
CN112860585A (en) | Test script assertion generation method and device | |
CN113050985A (en) | Front-end engineering dependence automatic registration method and device | |
CN111930624A (en) | Test link message data processing method and device | |
CN113791984B (en) | Automatic interface testing method and device | |
CN113050936B (en) | Front-end data processing method and device based on integrated development environment | |
CN113076262B (en) | Webpage automatic testing method and device | |
CN113452776B (en) | PaaS platform service scheduling method and device and PaaS platform | |
CN114968917A (en) | Method and device for rapidly importing file data | |
CN113535558A (en) | Software version transmission method and device | |
CN113127370A (en) | Report system smoking test method, RPA robot and system | |
CN113515447A (en) | System automation test method and device | |
CN113158259A (en) | Block chain integrity verification method and device | |
CN115701591A (en) | Business process testing method, device, medium and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |