CN111581098A - Interface data transfer storage method, device, server and storage medium - Google Patents

Interface data transfer storage method, device, server and storage medium Download PDF

Info

Publication number
CN111581098A
CN111581098A CN202010387535.4A CN202010387535A CN111581098A CN 111581098 A CN111581098 A CN 111581098A CN 202010387535 A CN202010387535 A CN 202010387535A CN 111581098 A CN111581098 A CN 111581098A
Authority
CN
China
Prior art keywords
interface
interface data
address
data
test platform
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.)
Granted
Application number
CN202010387535.4A
Other languages
Chinese (zh)
Other versions
CN111581098B (en
Inventor
梁科威
肖力群
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Zhumo Technology Co ltd
Original Assignee
Shenzhen Zhumo Technology Co ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Shenzhen Zhumo Technology Co ltd filed Critical Shenzhen Zhumo Technology Co ltd
Priority to CN202010387535.4A priority Critical patent/CN111581098B/en
Publication of CN111581098A publication Critical patent/CN111581098A/en
Application granted granted Critical
Publication of CN111581098B publication Critical patent/CN111581098B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/368Test management for test version control, e.g. updating test cases to a new software version
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/951Indexing; Web crawling techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/955Retrieval from the web using information identifiers, e.g. uniform resource locators [URL]
    • G06F16/9566URL specific, e.g. using aliases, detecting broken or misspelled links
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Debugging And Monitoring (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the invention discloses a system, a device, a server and a storage medium for transferring and storing interface data, wherein the system comprises: acquiring a homepage address of first interface data on a first test platform; simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address; acquiring corresponding second interface data according to the target interface address; and storing the target interface address and the corresponding second interface data to a second test platform. The embodiment of the invention realizes the automatic transfer of the interface data from the first test platform to the second test platform, improves the efficiency of interface data transfer and reduces the workload of technical personnel.

Description

Interface data transfer storage method, device, server and storage medium
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to a method, a device, a server and a storage medium for importing interface data into a database.
Background
The Interface is usually referred to as an API (Application Programming Interface), which is an Interface left by the operating system to the Application program and corresponds to an entrance and exit of a calling resource.
Along with the growth of services, interfaces are more and more, interface data are naturally more and more, and the interface data are not commonly used between different test platforms. For example, after the test platform is upgraded and modified, a large difference exists between a new test platform and an old test platform, which results in that the new test platform cannot directly call interface data in the old test platform, and a common method is that a technician introduces the interface data of the old test platform into the new test platform in a manual entry manner, which is not only inefficient, but also is prone to errors.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method, an apparatus, a server, and a storage medium for importing interface data into a database, so as to implement transfer and storage of interface data between different test platforms, and improve efficiency of transfer and storage of the interface data.
In a first aspect, an embodiment of the present invention provides a method for transferring and storing interface data, including:
acquiring a homepage address of first interface data on a first test platform;
simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
acquiring corresponding second interface data according to the target interface address;
and storing the target interface address and the corresponding second interface data to a second test platform.
Further, before the obtaining the homepage address of the first interface data on the first test platform, the method further includes:
a new storage space for storing interface addresses is created on the interface management platform.
Further, the acquiring the homepage address of the first interface data on the first test platform includes:
the method comprises the steps of obtaining a homepage address of first interface data on a first testing platform through a crawler and storing the homepage address into a preset list.
Further, the simulating the operation of the user on the homepage to obtain the plurality of target interface addresses of the homepage address comprises:
according to the preset list, simulating the operation of a user on a homepage through a selenium to obtain a plurality of target interface addresses in a first format of the homepage address;
and importing the target interface address in the first format into the new storage space to obtain the target interface address in the second format.
Further, the acquiring the corresponding second interface data according to the target interface address includes:
and acquiring corresponding second interface data through the crawler according to the target interface address in the second format.
Further, the storing the target interface address and the corresponding second interface data to a second test platform includes:
storing the target interface address and the corresponding second interface data into a preset file;
deleting historical interface data matched with the second interface data in a database of a second test platform;
and storing the target interface address in the preset file and the corresponding second interface data to a database of the second test platform.
Further, the historical interface data matched with the second interface data includes:
if the name of the historical interface data is the same as that of the second interface data, the historical interface data is the historical interface data matched with the second interface data; and/or
And if the identifier of the historical interface data is the same as the identifier of the second interface data, the historical interface data is the historical interface data matched with the second interface data.
In a second aspect, an embodiment of the present invention provides an apparatus for interface data transfer and storage, including:
the homepage address acquisition module is used for acquiring the homepage address of the first interface data on the first test platform;
the target interface address acquisition module is used for simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
the second interface data acquisition module is used for acquiring corresponding second interface data according to the target interface address;
and the second interface data storage module is used for storing the target interface address and the corresponding second interface data to a second test platform.
In a third aspect, an embodiment of the present invention provides a server, where the server includes:
one or more processors;
a storage device for storing one or more programs,
when the one or more programs are executed by the one or more processors, the one or more processors implement the method for interface data transfer storage provided by any embodiment of the invention.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the method for interface data transfer storage provided in any embodiment of the present invention.
The interface data transfer storage method provided by the embodiment of the invention obtains the homepage address of the first interface data on the first test platform; simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address; acquiring corresponding second interface data according to the target interface address; and storing the target interface address and the corresponding second interface data to a second test platform. The automatic interface data transfer method and the automatic interface data transfer device realize the automatic transfer of the interface data from the first test platform to the second test platform, improve the efficiency of interface data transfer and reduce the workload of technicians.
Drawings
Fig. 1 is a schematic flowchart of a method for transferring and storing interface data according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of a method for transferring and storing interface data according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of an interface data transfer and storage apparatus according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of a server according to a fourth embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.
Before discussing exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although a flowchart may describe the steps as a sequential process, many of the steps can be performed in parallel, concurrently or simultaneously. In addition, the order of the steps may be rearranged. A process may be terminated when its operations are completed, but may have additional steps not included in the figure. A process may correspond to a method, a function, a procedure, a subroutine, a subprogram, etc.
Furthermore, the terms "first," "second," and the like may be used herein to describe various orientations, actions, steps, elements, or the like, but the orientations, actions, steps, or elements are not limited by these terms. These terms are only used to distinguish one direction, action, step or element from another direction, action, step or element. For example, a first test platform may be referred to as a second test platform, and similarly, a second test platform may be referred to as a first test platform, without departing from the scope of the present application. Both the first test platform and the second test platform are test platforms, but they are not the same test platform. The terms "first", "second", etc. are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of the present invention, "plurality", "batch" means at least two, e.g., two, three, etc., unless specifically limited otherwise.
Example one
Fig. 1 is a schematic flowchart of a method for transferring and storing interface data according to an embodiment of the present invention, which is applicable to transferring and storing interface data between different test platforms. As shown in fig. 1, a method for transferring and storing interface data according to an embodiment of the present invention includes:
s110, acquiring a homepage address of the first interface data on the first test platform.
Specifically, web page development (also called web development, website development) is generally divided into front-end development and back-end development, the front-end development is a design of a static page of a web page, which is usually a part visible to the naked eye, the back-end development is a technology of a dynamic website, and the design and implementation of background logic of the website also store and read data of a user and the website, such as some registration entries and some pop-ups on the website. In general, front-end development and back-end development are performed separately, and communication is performed between the front end and the back end through an interface (API), so that an interface document is generated according to communication rules between the front end and the back end, the interface document defines some protocols, specifications, and requirements for communication between the front end and the back end, and data in the interface document is interface data.
The test platform refers to a platform for performing an interface automation test, and the first test platform is a test platform for transferring interface data, for example, an old interface automation test platform, and the interface data on the first test platform is referred to as first interface data.
The home page address refers to a home page address of a website, that is, a URL (Uniform resource locator) of a home page of the website, and it can be understood that the home page of the website is also an interface actually, and there are many other interfaces (corresponding to different function buttons of the home page of the website) in the home page of the website, so the home page address can be regarded as a collection of many interface addresses. For example, one embodiment has a home page address of https:// www.baidu.com/.
And S120, simulating the operation of the user on the homepage to acquire a plurality of target interface addresses of the homepage address.
Specifically, the target interface address refers to addresses of other interfaces in the home page of the website, and different home page addresses correspond to different target interface addresses. Simulating the user's operation on the homepage means simulating the user's access to different interfaces in the homepage, and obtaining a target interface address every time the user accesses one interface. For example, the homepage address of the Baidu website is https:// www.baidu.com/, various types of other interfaces such as 'news', 'video', 'map', 'bar' and the like exist on the homepage of the Baidu website, and when a user clicks different interfaces, the user can obtain the corresponding target interface address, for example, the user is simulated to click 'news', the target interface address http:// news.
S130, acquiring corresponding second interface data according to the target interface address.
Specifically, the second interface data refers to interface data obtained by re-accessing the corresponding interface according to the target interface address, where the process of accessing the corresponding interface according to the target interface address is also called requesting the target interface address. For example, interface data corresponding to the interface of video is obtained according to the target interface address http:// v.baidu.com/access corresponding video interface.
Optionally, the target interface address may be first imported into a transit platform, where the transit platform is an interface management platform, for example, YAPI, and then the transit platform requests the target interface address to obtain the corresponding second interface data.
S140, storing the target interface address and the corresponding second interface data to a second test platform.
Specifically, the second test platform refers to a platform for automated testing of a target interface for interface data transfer, for example, a new interface automated test platform after updating and upgrading an old interface automated test platform. And storing the obtained target interface address and the corresponding second interface data to a second test platform, so that the second test platform can also call the original interface data.
The interface data transfer and storage method provided by the embodiment of the invention obtains the homepage address of the first interface data on the first test platform; simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address; acquiring corresponding second interface data according to the target interface address; and storing the target interface address and the corresponding second interface data to a second test platform. The automatic interface data transfer method and the automatic interface data transfer device realize the automatic transfer of the interface data from the first test platform to the second test platform, improve the efficiency of interface data transfer and reduce the workload of technicians.
Example two
Fig. 2 is a schematic flowchart of a method for transferring and storing interface data according to a second embodiment of the present invention, which is a further refinement of the foregoing embodiment. As shown in fig. 2, the method for transferring and storing interface data provided by the second embodiment of the present invention includes:
and S210, creating a new storage space for storing the interface address on the interface management platform.
Specifically, the interface management platform is a platform capable of creating, publishing and maintaining an interface, which corresponds to a transit platform, such as YAPI. A new memory space is created on the interface management platform for storing interface addresses, e.g. subsequent target interface addresses. In YAPI, creating a new memory space is equivalent to creating a new tag, which is an identification of the memory space.
S220, acquiring a homepage address of the first interface data on the first test platform through a crawler and storing the homepage address into a preset list.
Specifically, a crawler (also called a web crawler) is a program or script that automatically crawls web information according to certain rules, such as crawling interface addresses or interface data. The first testing platform is an interface automation testing platform for interface data transfer, and usually, some management tools of interface documents, for example, swagger, are used on the interface automation testing platform, and therefore, the homepage address of the first interface data on the first testing platform may also be referred to as the URL of the interface document on swagger. The method includes the steps that URLs of interface documents on swaggers are obtained through a crawler, and then the obtained URLs of the interface documents are stored into a preset list, wherein the preset list is an option _ list, for example.
And S230, according to the preset list, simulating the operation of the user on the homepage through the selenium to obtain a plurality of target interface addresses in the first format of the homepage address.
Specifically, the selenium is a tool for testing the Web application, and the selenium test directly runs in the browser just like the operation of a real user, so that the selenium can simulate the operation of the user on a homepage according to the homepage address in a preset list (option _ list), and the obtained target interface address is the URL of the interface document stored in the swagger. Different test platforms or test tools may use different protocols and different representation formats of addresses (URLs) stored thereon, so that the obtained URL of the interface document on the swagger is referred to as a target interface address in the first format. When the user operation is simulated by using the selenium, a plurality of target interface addresses in the first format can be obtained by operating the chrome browser in a non-interface mode through a command of' chrome _ options.
S240, importing the target interface address in the first format into the new storage space to obtain the target interface address in the second format.
Specifically, the obtained URL of the interface document on swagger is imported into a new storage space in the interface management platform, that is, the target interface address is transferred from swagger to YAPI, and the representation form of the target interface address in YAPI is the second format.
And S250, acquiring corresponding second interface data through a crawler according to the target interface address in the second format.
Specifically, the target interface address in the second format is the target interface address in the YAPI, and the crawler can obtain not only the URL but also page data (interface data), so that the crawler requests the target interface address in the YAPI, and thus can obtain the second interface data corresponding to the target interface address.
Generally, interface data in the swagger of the first test platform are encrypted, if the interface data in the swagger are directly acquired without an interface management platform YAPI, decryption work needs to be carried out, the operation is complex, in the application, the user operation is simulated through a selenium and combined with a crawler, an encryption mechanism of the swagger is bypassed, and then second interface data are acquired through the YAPI, so that the decryption work can be omitted.
S260, storing the target interface address and the corresponding second interface data into a preset file.
Specifically, after the second interface data is acquired, the second interface data is not immediately stored in the second test platform, but the target interface address and the corresponding second interface data are stored in a preset file, so that the second test platform is preprocessed before the second interface data is stored. The preset file may be a txt file created in advance, or may be another type of file capable of importing data into the database.
And S270, deleting the historical interface data matched with the second interface data in the database of the second test platform.
In particular, the database of the second test platform may store interface data, for example, a MYSQL database. The historical interface data matched with the second interface data in the database of the second test platform is deleted, so that confusion or conflict between the newly introduced second interface data and the original historical interface data in the database can be avoided when the second interface data is stored in the database subsequently.
Specifically, the method for judging whether the historical interface data in the database is matched with the second interface data comprises the following steps: if the name of the historical interface data is the same as that of the second interface data, the historical interface data is the historical interface data matched with the second interface data; and/or if the identifier of the historical interface data is the same as the identifier of the second interface data, the historical interface data is the historical interface data matched with the second interface data. That is, the historical interface data matched with the second interface data may be screened out by name matching or identifier matching, and when name matching is used, matching may also be performed by the name of the interface document corresponding to the interface data.
The identifier in the identifier matching is a unique identifier added to the interface data in advance, and when historical interface data with the identifier identical to that of the second interface data exists in the database, the historical interface data is the interface data which is stored in the database before and has the same type as the second interface data, and the value of the second interface data stored this time may change, so that the historical interface data is deleted to avoid confusion.
S280, storing the target interface address in the preset file and the corresponding second interface data to a database of the second test platform.
Specifically, after the historical interface data matching the database of the second test platform and the second interface data is deleted, the target interface address in the preset file and the corresponding second interface data can be stored in the database, so that the interface data are transferred from the first test platform to the second test platform.
The interface data transfer and storage method provided by the second embodiment of the invention realizes the automatic transfer and storage of the interface data from the first test platform to the second test platform, improves the efficiency of interface data transfer, and reduces the workload of technicians. Moreover, by simulating user operation through the selenium and combining with the crawler, the encryption mechanism of swagger is bypassed, YAPI is used for reducing decryption work, the application range is wide, and data which can be acquired only after complex operation or encrypted login can be crawled.
EXAMPLE III
Fig. 3 is a schematic structural diagram of an interface data transfer and storage apparatus according to a third embodiment of the present invention, which is applicable to transfer and storage of interface data between different test platforms. The interface data transfer and storage device provided by the third embodiment of the present invention may be a method for implementing interface data transfer and storage provided by any embodiment of the present invention, and has a corresponding functional structure and beneficial effects of the implementation method.
As shown in fig. 3, an interface data transfer and storage apparatus provided by the third embodiment of the present invention includes: a home page address obtaining module 310, a target interface address obtaining module 320, a second interface data obtaining module 330 and a second interface data storing module 340.
The homepage address obtaining module 310 is configured to obtain a homepage address of the first interface data on the first test platform;
the target interface address acquisition module 320 is used for simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
the second interface data obtaining module 330 is configured to obtain corresponding second interface data according to the target interface address;
the second interface data storage module 340 is configured to store the target interface address and the corresponding second interface data to the second test platform.
Further, the method also comprises the following steps:
and the new storage space creating module is used for creating a new storage space for storing the interface address on the interface management platform.
Further, the home page address obtaining module 310 is specifically configured to:
the method comprises the steps of obtaining a homepage address of first interface data on a first testing platform through a crawler and storing the homepage address into a preset list.
Further, the target interface address obtaining module 320 is specifically configured to:
according to the preset list, simulating the operation of a user on a homepage through a selenium to obtain a plurality of target interface addresses in a first format of the homepage address;
and importing the target interface address in the first format into the new storage space to obtain the target interface address in the second format.
Further, the second interface data obtaining module 330 is specifically configured to:
and acquiring corresponding second interface data through the crawler according to the target interface address in the second format.
Further, the second interface data storage module 340 is specifically configured to:
storing the target interface address and the corresponding second interface data into a preset file;
deleting historical interface data matched with the second interface data in a database of a second test platform;
and storing the target interface address in the preset file and the corresponding second interface data to a database of the second test platform.
Further, the historical interface data matched with the second interface data includes:
if the name of the historical interface data is the same as that of the second interface data, the historical interface data is the historical interface data matched with the second interface data; and/or
And if the identifier of the historical interface data is the same as the identifier of the second interface data, the historical interface data is the historical interface data matched with the second interface data.
According to the interface data transfer and storage device provided by the embodiment of the invention, the homepage address acquisition module, the target interface address acquisition module, the second interface data acquisition module and the second interface data storage module are used for automatically transferring the interface data from the first test platform to the second test platform, so that the interface data transfer efficiency is improved, and the workload of technicians is reduced.
Example four
Fig. 4 is a schematic structural diagram of a server according to a fourth embodiment of the present invention. FIG. 4 illustrates a block diagram of an exemplary server 412 suitable for use in implementing embodiments of the present invention. The server 412 shown in fig. 4 is only an example and should not bring any limitations to the function and scope of use of the embodiments of the present invention.
As shown in FIG. 4, server 412 is in the form of a general purpose server. Components of server 412 may include, but are not limited to: one or more processors 416, a storage device 428, and a bus 418 that couples the various system components including the storage device 428 and the processors 416.
Bus 418 represents one or more of any of several types of bus structures, including a memory device bus or memory device controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. By way of example, such architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.
Server 412 typically includes a variety of computer system readable media. Such media can be any available media that is accessible by server 412 and includes both volatile and nonvolatile media, removable and non-removable media.
Storage 428 may include computer system readable media in the form of volatile Memory, such as Random Access Memory (RAM) 430 and/or cache Memory 432. The server 412 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 434 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 4, commonly referred to as a "hard drive"). Although not shown in FIG. 4, a magnetic disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk such as a Compact disk Read-Only Memory (CD-ROM), Digital Video disk Read-Only Memory (DVD-ROM) or other optical media may be provided. In these cases, each drive may be connected to bus 418 by one or more data media interfaces. Storage 428 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the invention.
A program/utility 440 having a set (at least one) of program modules 442 may be stored, for instance, in storage 428, such program modules 442 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. The program modules 442 generally perform the functions and/or methodologies of the described embodiments of the invention.
The server 412 may also communicate with one or more external devices 414 (e.g., keyboard, pointing terminal, display 424, etc.), with one or more terminals that enable a user to interact with the server 412, and/or with any terminals (e.g., network card, modem, etc.) that enable the server 412 to communicate with one or more other computing terminals. Such communication may occur via input/output (I/O) interfaces 422. Further, server 412 may communicate with one or more networks (e.g., a Local Area Network (LAN), Wide Area Network (WAN), and/or a public Network such as the Internet) via Network adapter 420. As shown in FIG. 4, network adapter 420 communicates with the other modules of server 412 via bus 418. It should be appreciated that although not shown in the figures, other hardware and/or software modules may be used in conjunction with the server 412, including but not limited to: microcode, end drives, Redundant processors, external disk drive Arrays, RAID (Redundant Arrays of Independent Disks) systems, tape drives, and data backup storage systems, among others.
The processor 416 executes various functional applications and data processing by executing programs stored in the storage device 428, for example, implementing a method for interface data transfer storage provided by any embodiment of the present invention, which may include:
acquiring a homepage address of first interface data on a first test platform;
simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
acquiring corresponding second interface data according to the target interface address;
and storing the target interface address and the corresponding second interface data to a second test platform.
EXAMPLE five
An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements a method for interface data transfer and storage according to any embodiment of the present invention, where the method may include:
acquiring a homepage address of first interface data on a first test platform;
simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
acquiring corresponding second interface data according to the target interface address;
and storing the target interface address and the corresponding second interface data to a second test platform.
Computer storage media for embodiments of the invention may employ any combination of one or more computer-readable media. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
A computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or terminal. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (10)

1. A method of interfacing data transfer storage, comprising:
acquiring a homepage address of first interface data on a first test platform;
simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
acquiring corresponding second interface data according to the target interface address;
and storing the target interface address and the corresponding second interface data to a second test platform.
2. The method of claim 1, wherein prior to obtaining the home address of the first interface data on the first test platform, further comprising:
a new storage space for storing interface addresses is created on the interface management platform.
3. The method of claim 2, wherein obtaining the home address of the first interface data on the first test platform comprises:
the method comprises the steps of obtaining a homepage address of first interface data on a first testing platform through a crawler and storing the homepage address into a preset list.
4. The method of claim 3, wherein the simulating the user's operation of the home page to obtain the plurality of target interface addresses of the home page address comprises:
according to the preset list, simulating the operation of a user on a homepage through a selenium to obtain a plurality of target interface addresses in a first format of the homepage address;
and importing the target interface address in the first format into the new storage space to obtain the target interface address in the second format.
5. The method of claim 4, wherein the obtaining corresponding second interface data according to the target interface address comprises:
and acquiring corresponding second interface data through the crawler according to the target interface address in the second format.
6. The method of claim 4, wherein storing the target interface address and corresponding second interface data to a second test platform comprises:
storing the target interface address and the corresponding second interface data into a preset file;
deleting historical interface data matched with the second interface data in a database of a second test platform;
and storing the target interface address in the preset file and the corresponding second interface data to a database of the second test platform.
7. The method of claim 6, wherein the historical interface data that matches the second interface data comprises:
if the name of the historical interface data is the same as that of the second interface data, the historical interface data is the historical interface data matched with the second interface data; and/or
And if the identifier of the historical interface data is the same as the identifier of the second interface data, the historical interface data is the historical interface data matched with the second interface data.
8. An apparatus for interfacing data transfer storage, comprising:
the homepage address acquisition module is used for acquiring the homepage address of the first interface data on the first test platform;
the target interface address acquisition module is used for simulating the operation of a user on a homepage to acquire a plurality of target interface addresses of the homepage address;
the second interface data acquisition module is used for acquiring corresponding second interface data according to the target interface address;
and the second interface data storage module is used for storing the target interface address and the corresponding second interface data to a second test platform.
9. A server, characterized in that the server comprises:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement a method of interfacing data transfer storage as recited in any of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, is adapted to carry out the method of interfacing data transfer storage according to any one of claims 1 to 7.
CN202010387535.4A 2020-05-09 2020-05-09 Method, device, server and storage medium for transferring and storing interface data Active CN111581098B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010387535.4A CN111581098B (en) 2020-05-09 2020-05-09 Method, device, server and storage medium for transferring and storing interface data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010387535.4A CN111581098B (en) 2020-05-09 2020-05-09 Method, device, server and storage medium for transferring and storing interface data

Publications (2)

Publication Number Publication Date
CN111581098A true CN111581098A (en) 2020-08-25
CN111581098B CN111581098B (en) 2024-02-23

Family

ID=72110781

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010387535.4A Active CN111581098B (en) 2020-05-09 2020-05-09 Method, device, server and storage medium for transferring and storing interface data

Country Status (1)

Country Link
CN (1) CN111581098B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112486460A (en) * 2020-11-30 2021-03-12 携程旅游信息技术(上海)有限公司 Method, system, device and medium for automatically importing interface document
CN112632513A (en) * 2020-12-29 2021-04-09 光大兴陇信托有限责任公司 Identity authentication implementation method based on front-end and back-end separation

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160378530A1 (en) * 2015-06-27 2016-12-29 Vmware, Inc. Remote-direct-memory-access-based virtual machine live migration
CN107122208A (en) * 2017-04-18 2017-09-01 深圳市金立通信设备有限公司 A kind of method and terminal of data transfer
CN107967324A (en) * 2017-11-24 2018-04-27 广州明动软件股份有限公司 Intellectual data conversion storage and Rapid input system and method
CN108133041A (en) * 2018-01-11 2018-06-08 四川九洲电器集团有限责任公司 Data collecting system and method based on web crawlers and data transfer technology
CN109688202A (en) * 2018-12-04 2019-04-26 北京腾云天下科技有限公司 A kind of processing method of interface data, calculates equipment and storage medium at device
CN110196844A (en) * 2018-04-16 2019-09-03 腾讯科技(深圳)有限公司 A kind of data migration method, system and storage medium
CN111078562A (en) * 2019-12-18 2020-04-28 广州唯品会研究院有限公司 Interface test method, terminal device and computer readable storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160378530A1 (en) * 2015-06-27 2016-12-29 Vmware, Inc. Remote-direct-memory-access-based virtual machine live migration
CN107122208A (en) * 2017-04-18 2017-09-01 深圳市金立通信设备有限公司 A kind of method and terminal of data transfer
CN107967324A (en) * 2017-11-24 2018-04-27 广州明动软件股份有限公司 Intellectual data conversion storage and Rapid input system and method
CN108133041A (en) * 2018-01-11 2018-06-08 四川九洲电器集团有限责任公司 Data collecting system and method based on web crawlers and data transfer technology
CN110196844A (en) * 2018-04-16 2019-09-03 腾讯科技(深圳)有限公司 A kind of data migration method, system and storage medium
CN109688202A (en) * 2018-12-04 2019-04-26 北京腾云天下科技有限公司 A kind of processing method of interface data, calculates equipment and storage medium at device
CN111078562A (en) * 2019-12-18 2020-04-28 广州唯品会研究院有限公司 Interface test method, terminal device and computer readable storage medium

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112486460A (en) * 2020-11-30 2021-03-12 携程旅游信息技术(上海)有限公司 Method, system, device and medium for automatically importing interface document
CN112632513A (en) * 2020-12-29 2021-04-09 光大兴陇信托有限责任公司 Identity authentication implementation method based on front-end and back-end separation
CN112632513B (en) * 2020-12-29 2024-01-12 光大兴陇信托有限责任公司 Front-end and back-end separation-based identity authentication implementation method

Also Published As

Publication number Publication date
CN111581098B (en) 2024-02-23

Similar Documents

Publication Publication Date Title
CN109302461B (en) Information display method, information processing method, information display medium, information processing system and computing equipment
CN109062563B (en) Method and device for generating page
CN109359194B (en) Method and apparatus for predicting information categories
CN111221572B (en) Method, device, medium and equipment for automatically adapting to running environment
CN110134869B (en) Information pushing method, device, equipment and storage medium
CN110929128A (en) Data crawling method, device, equipment and medium
CN111581098B (en) Method, device, server and storage medium for transferring and storing interface data
CN110110236B (en) Information pushing method, device, equipment and storage medium
CN111488386B (en) Data query method and device
CN113238739A (en) Plug-in development and data acquisition method, device, electronic equipment and medium
CN112035092A (en) Form processing method, device, equipment and readable medium
CN111125503B (en) Method and apparatus for generating information
CN110737861A (en) webpage data processing method, device, equipment and storage medium
CN112083982A (en) Information processing method and device
CN112384940A (en) Mechanism for WEB crawling of electronic business resource page
CN112506781B (en) Test monitoring method, device, electronic equipment, storage medium and program product
CN111400623B (en) Method and device for searching information
CN111596997B (en) UI information request method, device, terminal and storage medium
CN114218219A (en) Data processing method, device, equipment and storage medium
CN113448578A (en) Page data processing method, processing system, electronic device and readable storage medium
CN111240948A (en) Experience data processing method and device, computer equipment and storage medium
CN111061625A (en) Automatic testing method and device applied to out-of-order password keyboard
CN110968768B (en) Information generation method and device
CN113495498B (en) Simulation method, simulator, device and medium for hardware device
CN112037857B (en) Strain genome annotation query method and device, electronic equipment and storage medium

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
GR01 Patent grant
GR01 Patent grant