WO2023116003A1 - Data processing method and apparatus, device, storage medium and computer program product - Google Patents

Data processing method and apparatus, device, storage medium and computer program product Download PDF

Info

Publication number
WO2023116003A1
WO2023116003A1 PCT/CN2022/113850 CN2022113850W WO2023116003A1 WO 2023116003 A1 WO2023116003 A1 WO 2023116003A1 CN 2022113850 W CN2022113850 W CN 2022113850W WO 2023116003 A1 WO2023116003 A1 WO 2023116003A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
component
global
subscription
target
Prior art date
Application number
PCT/CN2022/113850
Other languages
French (fr)
Chinese (zh)
Inventor
魏嘉汛
董敏
王鹏翔
田泽润
覃耀辉
Original Assignee
北京百度网讯科技有限公司
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 北京百度网讯科技有限公司 filed Critical 北京百度网讯科技有限公司
Publication of WO2023116003A1 publication Critical patent/WO2023116003A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design
    • G06F8/24Object-oriented
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/34Graphical or visual programming
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/36Software reuse
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/43Checking; Contextual analysis
    • G06F8/433Dependency analysis; Data or control flow analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Definitions

  • the present disclosure relates to the technical field of computer applications, in particular to the technical field of data processing of web front-end applications.
  • a specific state management tool matching the framework can be applied to analyze and manage the global data state, so as to obtain data on changes in the data state, track and locate the problems that occur in the application, and Perform correctness analysis on the data change process from model to view.
  • the present disclosure provides a data processing method, device, device, storage medium and computer program product.
  • a data processing method including:
  • a data processing device including:
  • a determination unit configured to determine the target data to be processed, and determine a data source of the target data; a processing unit, configured to perform instrumentation processing between the target data and the data source, to obtain the target data The global data in the process of accessing the data source; an output unit configured to determine and output the dependencies among the data in the global data.
  • an electronic device comprising:
  • the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute the above-mentioned method.
  • a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause the computer to execute the above-mentioned method.
  • a computer program product including a computer program, and the computer program implements the above-mentioned method when executed by a processor.
  • the stub processing is performed between the target data and the data source, and then the global data in the process of the target data accessing the data source can be obtained, so a more efficient data processing device can be provided.
  • FIG. 1 is a flow chart of a data processing method shown in an exemplary embodiment of the present disclosure
  • Fig. 2 shows a schematic diagram of a global data production and consumption relationship shown in an exemplary embodiment of the present disclosure
  • Fig. 3 shows a schematic diagram of instrumentation between producers and consumers according to an exemplary embodiment of the present disclosure
  • Fig. 4 is a flow chart of a data processing method shown in an exemplary embodiment according to the present disclosure
  • Fig. 5 is a block diagram of a data processing device provided according to the present disclosure.
  • FIG. 6 shows a schematic block diagram of an example electronic device 600 that may be used to implement embodiments of the present disclosure.
  • the data processing method provided in the present disclosure is applied to a scene of analyzing and processing data of web front-end applications. For example, it can be applied to data analysis and processing of modern web front-end applications based on the MVVM framework.
  • a front-end program analysis tool may be used to analyze the global data of the web front-end application.
  • the program analysis capabilities are mainly concentrated in a specific state management solution, and provide data change tracking capabilities for specific solutions.
  • This kind of data change tracking capability mainly starts from the change of a single data state itself, and analyzes the data change relationship involved in the data operation process through dynamic operation mode, so as to locate the problem of the program and analyze the correctness of the program.
  • this kind of solution only focuses on the tracking of data changes, and lacks analysis of data dependencies and consumption characteristics. Especially for data subscriptions and data dependencies, it lacks analysis capabilities and cannot completely solve business problems.
  • the problems encountered will affect the efficiency of research and development.
  • the solutions for managing the data state of global data in the related art only support the tracking of data changes, and do not involve analysis of dependencies between data, nor do they involve which view elements the data is consumed by.
  • the output result of data state management in the related art is a log with a linear structure, which cannot reflect the relationship between output results between components, that is, the interactive relationship between logs, the serial relationship of component operations, and the like.
  • the present disclosure provides a data processing method.
  • the global data involved in the process of accessing the data source of the data with consumption characteristics is obtained through the stub processing method, and the global data in the global data are determined.
  • the dependency relationship between data is output to realize the analysis of the dependence and consumption characteristics of each data in the global data.
  • Fig. 1 is a flowchart of a data processing method shown in an exemplary embodiment of the present disclosure.
  • the data processing method includes the following steps S101 to S103.
  • step S101 target data to be processed is determined, and a data source of the target data is determined.
  • step S102 instrumentation is performed between the target data and the data source, so as to obtain global data in the process of the target data accessing the data source.
  • step S103 determine and output the dependencies among the data in the global data.
  • the data involved in the present disclosure may be global data in the producer-consumer pattern.
  • the data in the producer-consumer mode includes producers and consumers. There is only one producer of global data, but usually there are multiple consumers. That is, a producer can correspond to multiple consumers, but a consumer can only correspond to one producer. Each producer and each consumer corresponds to an address, occupies a network node, and belongs to predetermined data.
  • Fig. 2 shows a schematic diagram of a global data production and consumption relationship according to an exemplary embodiment of the present disclosure. Referring to Figure 2, the producer's data can be consumed by consumer 1 and consumer 2.
  • the target data to be processed involved in the present disclosure may be a consumer in the producer-consumer pattern, for example, data with consumption characteristics such as view elements.
  • the target data to be processed can also be referred to as a consumer.
  • the data source of the target data may be a producer in the producer-consumer pattern.
  • the instrumentation process between the target data and the data source can be understood as adding instrumentation codes to the source code of the global data.
  • the instrumentation code Through the instrumentation code, the global data in the process of the target data accessing the data source can be obtained, and then the content information with data dependencies between the global data can be obtained.
  • a proxy may be inserted between a data source (producer) and target data to be processed (consumer).
  • Fig. 3 shows a schematic diagram of instrumentation between a producer and a consumer according to an exemplary embodiment of the present disclosure. As shown in Figure 3, a proxy is inserted between the data and consumer 1 and consumer 2, where the consumer needs to access and modify the data of the data source through the proxy and save it in the access library. Among them, consumers cannot directly access the real data in the data source, but access it through an agent.
  • global data in the process of target data accessing a data source can be obtained by obtaining access to data by any consumer through a proxy.
  • information such as the path of the component to which the current consumer belongs, the name of the component, and the data content of the current data are calculated, and then the dependencies between the data are determined.
  • the dependency relationship between the data in the global data is determined, and the dependency relationship between the data in the global data can be output, so as to realize the monitoring of the dependency relationship between the data and reflect the correlation relationship between the data.
  • the dependency relationship among the data in the global data can be stored in the data access library.
  • the data processing method provided by this disclosure through the stub processing between the target data to be processed and the data source, the global data in the process of accessing the data source from the target data can be obtained through the stub, and each data in the global data can be obtained.
  • the content information of the dependency relationship between the data outputs the dependency relationship between the data in the global data, which can realize the analysis of the dependency relationship between the global data.
  • the global data when the global data is obtained through the instrumentation code added in the source code of the data source, the statement of the data, the update of the data, the subscription method of the data to the component, etc. can be obtained, so that the obtained global data depends on relationship, which can cover the data state of a more comprehensive global data.
  • Fig. 4 is a flow chart of a data processing method shown in an exemplary embodiment of the present disclosure.
  • the data processing method includes the following steps S201 to S203.
  • step S201 the data structure returned by the data declaration API (Application Programming Interface, application programming interface) is obtained, so as to obtain the global data declaration information of the target data access data source.
  • the data declaration API Application Programming Interface, application programming interface
  • step S202 the subscription information of calling the data subscription API for data subscription is obtained, so as to obtain the global data subscription information of the target data access data source.
  • step S203 the update information for calling the data update API to update the data is obtained, so as to obtain the global data update information of the target data access data source.
  • the functions provided by the APIs are the same in terms of data declaration, update, and subscription.
  • the functions provided by createStore in the Redux (React) framework, atom in the Recoil (React) framework, and Class@observable in the Mobx (React/Vue) framework are all data declaration API functions.
  • the functions provided by dispatchAction in the Redux (React) framework, useRecoilState/getter in the Recoil (React) framework, and Property accessor in the Mobx (React/Vue) framework are all data update API functions.
  • the functions provided by useSelector in the Redux (React) framework, useRecoilState/setter in the Recoil (React) framework, and Property setter in the Mobx (React/Vue) framework are all data subscription API functions. Therefore, in this disclosure, by obtaining the data declaration API, data update API, and data subscription API through stub insertion, relevant information of applications applied to different front-end MVVM frameworks at runtime can be obtained, and more comprehensive global data data can be covered state.
  • the present disclosure uses the Redux framework as an example to illustrate acquiring global data and determining dependencies between the global data.
  • the data structure finally returned by the data declaration API of the framework is obtained.
  • the store object returned by createStore is obtained through instrumentation. This object holds the global data of the web front-end application, so the statement information of all global data can be obtained in the instrumented agent.
  • the relevant calls to the data subscription API in the component are hijacked.
  • the access information of the selector function to the object properties is obtained in the access library of the proxy by means of stub insertion, and then the connection between the global data state and the subscription state component can be established, and It can clearly determine the object properties specifically accessed inside the component.
  • the update API is hijacked by instrumentation.
  • the global data updated by a component is updated by calling the dispatchAction method to dispatch an action to update the global data. Therefore, by getting the dispatchAction call through the stub, you can get the changes made by any component to the global data, and then you can use it before and after the call. Changes in global data determine which components trigger which data updates, and then clearly record the status of data updates throughout the process.
  • the data declaration API, data update API, and data subscription API are hijacked by instrumentation, and then the complete dependency relationship between data and components during application operation can be constructed, and the update process of components can be clearly described, which can help Developers understand the project and make technical decisions.
  • the data dependency involved in the present disclosure includes at least one of the following: data status, data status change information, and subscription relationship between data and components.
  • the consumer's access to data is obtained from the proxy, and whenever a consumer accesses data, the current consumer's component path, component ID, and current data data are calculated content and other information. Save the obtained component path, component ID, data content, etc. Further, in this disclosure, it is possible to compare the component paths, component identifiers, data content and other information corresponding to each consumer access data to determine the changed and updated content, store the changed and updated content, and the reasons for the changed and updated content. In turn, the data status, the update of changes in the data status, and the subscription relationship between data components can be determined.
  • the dependency relationship between data it is possible to determine the component identifier of the component to which each data belongs in the obtained global data, and determine the data dependency associated with the component identifier, and assemble the data dependency associated with the component identifier.
  • the relationship can connect the data states of each component in series to obtain the dependency relationship between the data.
  • the data dependencies associated with the component identifiers are assembled to record the data status and the reasons for the data status changes. Compared with the data status analysis results of the linear structure log method in the traditional technology, it is possible to clarify the relationship between components. The correlation between the output results is more conducive to the subscription analysis of the data status of the global data.
  • developers can use the global data subscription analysis to easily understand which components consume the global data, obtain the dependencies of different components, and target components with the same dependencies Encapsulation is possible, and the encapsulated components can be reused.
  • components with the same data dependency may be determined and encapsulated.
  • the same dependency includes at least one of the following: the same component path, the same component identifier, and the same data content. Encapsulating the same data dependencies in the present disclosure can facilitate developers to reuse the encapsulated data dependencies, perform code reconstruction, and improve code reuse.
  • developers can use global data subscription analysis, based on recorded component identifiers, and the propagation links between component identifiers, to determine the relatively stable propagation links corresponding to Component ID, as cacheable data.
  • a cacheable component identifier may be determined, and based on the component identifier, it is determined that there is component-dependent data.
  • the data with component dependencies may be the data with the same component path, or it may be understood as the data with the same propagation links involved in the data propagation process.
  • the component identifiers corresponding to the data with component dependencies can be cached, and then the cached component identifiers can be directly used to determine the corresponding component paths and improve Component performance optimization.
  • caching can quickly locate whether the data that the component depends on is cacheable, and the transmission link of the cacheable data, so as to improve the performance by increasing the cache.
  • the output data is a subscription relationship distribution graph subscribed by components.
  • the subscription relationship distribution diagram represents the subscription relationship between data and components, constructs a complete data-component dependency relationship graph during application operation, and can clearly describe the update process of components. Therefore, object attributes and nesting levels between objects can be determined through the subscription relationship distribution diagram provided in this disclosure, and based on the nesting level, it can be judged whether the module division is accurate, and then the code maintainability can be judged.
  • the subscription relationship distribution diagram of data subscribed by components
  • developers can further observe the depth of data subscriptions, and then analyze whether the current module division is reasonable.
  • the subscription relationship distribution diagram involves the writing of the global data model in the comment area of the global data. Since the comment area can only be subscribed and cannot be divided, the developer can conclude that it is unreasonable to divide the comment area into modules in this case.
  • the embodiment of the present disclosure also provides a data processing device.
  • the data processing apparatus includes corresponding hardware structures and/or software modules for performing various functions.
  • the embodiments of the present disclosure can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software drives hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the technical solutions of the embodiments of the present disclosure.
  • Fig. 5 is a block diagram of a data processing device provided according to the present disclosure.
  • a data processing apparatus 500 provided in the present disclosure includes a determination unit 501 , a processing unit 502 and an output unit 503 .
  • the determination unit 501 is used to determine the target data to be processed, and determine the data source of the target data; the processing unit 502 is used to perform stub processing between the target data and the data source, so as to obtain the target data in the process of accessing the data source Global data; an output unit 503, configured to determine and output the dependency relationship among the data in the global data.
  • processing unit 502 is used to: obtain the data structure returned by the data declaration API to obtain the global data declaration information of the target data access data source; obtain the subscription information for calling the data subscription API for data subscription to obtain the target data Access the global data subscription information of the data source; obtain the update information of calling the data update application program interface for data update, so as to obtain the global data update information of the target data access data source.
  • the output unit 503 is used to: determine the component identification of the component to which each data in the global data belongs; determine the data dependency relationship associated with the component identification, and the data dependency relationship includes at least one of the following: data status, data status change information, and data Subscription relationship with components;
  • Assembling components identifies associated data dependencies.
  • the output unit 503 is further configured to: determine the same data dependency, the same dependency includes at least one of the following: the same component path, the same component identifier, and the same data content; encapsulation Same data dependencies.
  • the output unit 503 is further configured to: based on the component identifier, determine that there is component-dependent data, and the component-dependent data includes the same component path to which the data belongs; and cache the component identifier corresponding to the component-dependent data.
  • the output unit 503 is further configured to: output a subscription relationship distribution graph, where the subscription relationship distribution graph is used to represent the subscription relationship between data and components.
  • the acquisition, storage and application of the user's personal information involved are in compliance with relevant laws and regulations, and do not violate public order and good customs.
  • the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.
  • FIG. 6 shows a schematic block diagram of an example electronic device 600 that may be used to implement embodiments of the present disclosure.
  • Electronic device is intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other suitable computers.
  • Electronic devices may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices.
  • the components shown herein, their connections and relationships, and their functions, are by way of example only, and are not intended to limit implementations of the disclosure described and/or claimed herein.
  • the device 600 includes a computing unit 601 that can execute according to a computer program stored in a read-only memory (ROM) 602 or loaded from a storage unit 608 into a random-access memory (RAM) 603. Various appropriate actions and treatments. In the RAM 603, various programs and data necessary for the operation of the device 600 can also be stored.
  • the computing unit 601, ROM 602, and RAM 603 are connected to each other through a bus 604.
  • An input/output (I/O) interface 605 is also connected to the bus 604 .
  • the I/O interface 605 includes: an input unit 606, such as a keyboard, a mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a magnetic disk, an optical disk, etc. ; and a communication unit 609, such as a network card, a modem, a wireless communication transceiver, and the like.
  • the communication unit 609 allows the device 600 to exchange information/data with other devices over a computer network such as the Internet and/or various telecommunication networks.
  • the computing unit 601 may be various general-purpose and/or special-purpose processing components having processing and computing capabilities. Some examples of computing units 601 include, but are not limited to, central processing units (CPUs), graphics processing units (GPUs), various dedicated artificial intelligence (AI) computing chips, various computing units that run machine learning model algorithms, digital signal processing processor (DSP), and any suitable processor, controller, microcontroller, etc.
  • the computing unit 601 executes various methods and processes described above, such as data processing methods.
  • the data processing method may be implemented as a computer software program tangibly embodied on a machine-readable medium, such as the storage unit 608 .
  • part or all of the computer program may be loaded and/or installed on the device 600 via the ROM 602 and/or the communication unit 609.
  • the computer program When the computer program is loaded into RAM 603 and executed by computing unit 601, one or more steps of the data processing method described above may be performed.
  • the computing unit 601 may be configured to execute the data processing method in any other suitable manner (for example, by means of firmware).
  • Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips Implemented in a system of systems (SOC), load programmable logic device (CPLD), computer hardware, firmware, software, and/or combinations thereof.
  • FPGAs field programmable gate arrays
  • ASICs application specific integrated circuits
  • ASSPs application specific standard products
  • SOC system of systems
  • CPLD load programmable logic device
  • computer hardware firmware, software, and/or combinations thereof.
  • programmable processor can be special-purpose or general-purpose programmable processor, can receive data and instruction from storage system, at least one input device, and at least one output device, and transmit data and instruction to this storage system, this at least one input device, and this at least one output device an output device.
  • Program codes for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special purpose computer, or other programmable data processing devices, so that the program codes, when executed by the processor or controller, make the functions/functions specified in the flow diagrams and/or block diagrams Action is implemented.
  • the program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
  • a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device.
  • a machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium.
  • a machine-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing.
  • machine-readable storage media would include one or more wire-based electrical connections, portable computer discs, hard drives, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, compact disk read only memory (CD-ROM), optical storage, magnetic storage, or any suitable combination of the foregoing.
  • RAM random access memory
  • ROM read only memory
  • EPROM or flash memory erasable programmable read only memory
  • CD-ROM compact disk read only memory
  • magnetic storage or any suitable combination of the foregoing.
  • the systems and techniques described herein can be implemented on a computer having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user. ); and a keyboard and pointing device (eg, a mouse or a trackball) through which a user can provide input to the computer.
  • a display device e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor
  • a keyboard and pointing device eg, a mouse or a trackball
  • Other kinds of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and can be in any form (including Acoustic input, speech input or, tactile input) to receive input from the user.
  • the systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., as a a user computer having a graphical user interface or web browser through which a user can interact with embodiments of the systems and techniques described herein), or including such backend components, middleware components, Or any combination of front-end components in a computing system.
  • the components of the system can be interconnected by any form or medium of digital data communication, eg, a communication network. Examples of communication networks include: Local Area Network (LAN), Wide Area Network (WAN) and the Internet.
  • a computer system may include clients and servers.
  • Clients and servers are generally remote from each other and typically interact through a communication network.
  • the relationship of client and server arises by computer programs running on the respective computers and having a client-server relationship to each other.
  • the server can be a cloud server, a server of a distributed system, or a server combined with a blockchain.
  • steps may be reordered, added or deleted using the various forms of flow shown above.
  • each step described in the present disclosure may be executed in parallel, sequentially, or in a different order, as long as the desired result of the technical solution disclosed in the present disclosure can be achieved, no limitation is imposed herein.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Stored Programmes (AREA)

Abstract

A data processing method and apparatus, a device, a storage medium and a computer program product, relating to the technical field of computer application, and in particular to the technical field of data processing for a web front-end application. The specific implementation solution comprises: determining target data to be processed, and determining a data source of the target data (S101); performing instrumentation processing between the target data and the data source to obtain global data in the process of accessing the data source by the target data (S102); and determining and outputting a dependency relationship among all data in the global data (S103). Therefore, the dependency relationship among all the data in the global data can be determined and outputted, so that the dependency relationship between the global data is analyzed.

Description

数据处理方法、装置、设备、存储介质及计算机程序产品Data processing method, device, device, storage medium and computer program product 技术领域technical field
本公开涉及计算机应用技术领域,尤其涉及web前端应用的数据处理技术领域。The present disclosure relates to the technical field of computer applications, in particular to the technical field of data processing of web front-end applications.
背景技术Background technique
针对MVVM(Model-View-View Model,模型-视图-视图模型)框架下的web前端应用,可以通过采用数据驱动的方法,将视图变化的细节进行隐藏,让开发者只需专注在数据变化相关的处理中,而不需要关心视图变化更新的细节。For web front-end applications under the MVVM (Model-View-View Model) framework, the details of view changes can be hidden by adopting a data-driven approach, so that developers only need to focus on data changes In the process of processing, you don't need to care about the details of view change updates.
相关技术中,对于web前端应用的代码数据,可以应用匹配框架的特定状态管理工具进行全局数据状态分析以及管理,以获取数据状态发生变化的数据,对应用发生的问题进行追踪定位,并对应用的数据从模型至视图变化过程进行正确性分析。In related technologies, for the code data of the web front-end application, a specific state management tool matching the framework can be applied to analyze and manage the global data state, so as to obtain data on changes in the data state, track and locate the problems that occur in the application, and Perform correctness analysis on the data change process from model to view.
发明内容Contents of the invention
本公开提供了一种用于数据处理方法、装置、设备、存储介质及计算机程序产品。The present disclosure provides a data processing method, device, device, storage medium and computer program product.
根据本公开的一方面,提供了一种数据处理方法,包括:According to an aspect of the present disclosure, a data processing method is provided, including:
确定待处理的目标数据,并确定所述目标数据的数据源;在所述目标数据与所述数据源之间进行插桩处理,以获取所述目标数据访问所述数据源过程中的全局数据;确定并输出所述全局数据中各数据之间的依赖关系。Determine the target data to be processed, and determine the data source of the target data; perform stub processing between the target data and the data source, so as to obtain the global data in the process of the target data accessing the data source ; Determine and output the dependencies among the data in the global data.
根据本公开的另一方面,提供了一种数据处理装置,包括:According to another aspect of the present disclosure, a data processing device is provided, including:
确定单元,用于确定待处理的目标数据,并确定所述目标数据的数据源;处理单元,用于在所述目标数据与所述数据源之间进行插桩处理,以获取所述目标数据访问所述数据源过程中的全局数据;输出单元,用于确定并输出所述全局数据中各数据之间的依赖关系。A determination unit, configured to determine the target data to be processed, and determine a data source of the target data; a processing unit, configured to perform instrumentation processing between the target data and the data source, to obtain the target data The global data in the process of accessing the data source; an output unit configured to determine and output the dependencies among the data in the global data.
根据本公开的又一方面,提供一种电子设备,包括:According to yet another aspect of the present disclosure, an electronic device is provided, comprising:
至少一个处理器;以及与所述至少一个处理器通信连接的存储器;其 中,at least one processor; and a memory communicatively coupled to the at least one processor; wherein,
所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行上述涉及的方法。The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute the above-mentioned method.
根据本公开的又一方面,提供一种存储有计算机指令的非瞬时计算机可读存储介质,其中,所述计算机指令用于使所述计算机执行上述涉及的方法。According to yet another aspect of the present disclosure, there is provided a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause the computer to execute the above-mentioned method.
根据本公开的又一方面,提供一种计算机程序产品,包括计算机程序,所述计算机程序在被处理器执行时实现上述涉及的方法。According to yet another aspect of the present disclosure, a computer program product is provided, including a computer program, and the computer program implements the above-mentioned method when executed by a processor.
通过本公开在目标数据与数据源之间进行插桩处理,进而能够获取到目标数据访问数据源过程中的全局数据,故可以提供一种效率更高的数据处理设备。Through the present disclosure, the stub processing is performed between the target data and the data source, and then the global data in the process of the target data accessing the data source can be obtained, so a more efficient data processing device can be provided.
应当理解,本部分所描述的内容并非旨在标识本公开的实施例的关键或重要特征,也不用于限制本公开的范围。本公开的其它特征将通过以下的说明书而变得容易理解。It should be understood that what is described in this section is not intended to identify key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will be readily understood through the following description.
附图说明Description of drawings
附图用于更好地理解本方案,不构成对本公开的限定。其中:The accompanying drawings are used to better understand the present solution, and do not constitute a limitation to the present disclosure. in:
图1是根据本公开一示例性实施方式中示出的一种数据处理方法流程图;FIG. 1 is a flow chart of a data processing method shown in an exemplary embodiment of the present disclosure;
图2示出了本公开一示例性实施方式中示出的全局数据生产消费关系示意图;Fig. 2 shows a schematic diagram of a global data production and consumption relationship shown in an exemplary embodiment of the present disclosure;
图3示出了根据本公开一示例性实施方式中示出的在生产者和消费者之间进行插桩的示意图;Fig. 3 shows a schematic diagram of instrumentation between producers and consumers according to an exemplary embodiment of the present disclosure;
图4是根据本公开一示例性实施方式中示出的一种数据处理方法流程图;Fig. 4 is a flow chart of a data processing method shown in an exemplary embodiment according to the present disclosure;
图5是根据本公开提供的一种数据处理装置的框图;Fig. 5 is a block diagram of a data processing device provided according to the present disclosure;
图6示出了可以用来实施本公开的实施例的示例电子设备600的示意性框图。FIG. 6 shows a schematic block diagram of an example electronic device 600 that may be used to implement embodiments of the present disclosure.
具体实施方式Detailed ways
以下结合附图对本公开的示范性实施例做出说明,其中包括本公开实施例的各种细节以助于理解,应当将它们认为仅仅是示范性的。因此,本领域普通技术人员应当认识到,可以对这里描述的实施例做出各种改变和修改,而不会背离本公开的范围和精神。同样,为了清楚和简明,以下的描述中省略了对公知功能和结构的描述。Exemplary embodiments of the present disclosure are described below in conjunction with the accompanying drawings, which include various details of the embodiments of the present disclosure to facilitate understanding, and they should be regarded as exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
本公开提供的数据处理方法,应用于对web前端应用的数据进行分析处理的场景中。例如可以应用于基于MVVM框架的现代web前端应用的数据分析处理中。The data processing method provided in the present disclosure is applied to a scene of analyzing and processing data of web front-end applications. For example, it can be applied to data analysis and processing of modern web front-end applications based on the MVVM framework.
相关技术中,可以使用前端程序分析工具,对web前端应用的全局数据进行分析。目前各种对web前端应用全局数据进行分析的分析工具,程序分析能力主要集中在某一具体状态管理方案中,提供针对特定方案的数据变更追踪能力。此种数据变更追踪能力主要从单一数据状态的变化本身入手,通过动态运行方式对数据运行过程中涉及的数据变化关系进行分析,以用于程序的问题定位以及程序正确性分析。然而,此种方案仅关注数据变更的追踪,针对数据之间的依赖和消费特性的分析比较匮乏,尤其对于数据订阅、数据依赖关系相关的部分,缺乏分析能力,并不能完整解决业务中所遇到的问题,进而影响研发效率。换言之,相关技术中对全局数据的数据状态进行管理的方案中,仅支持数据变更的追踪,不涉及数据间的依赖关系分析,也不会涉及数据被哪些视图元素消费。并且,相关技术中数据状态管理的输出结果为线性结构的日志,不能体现组件之间输出结果之间的关联关系,即不能体现日志之间的交互关系,组件操作的串联关系等。In related technologies, a front-end program analysis tool may be used to analyze the global data of the web front-end application. At present, various analysis tools for analyzing the global data of web front-end applications, the program analysis capabilities are mainly concentrated in a specific state management solution, and provide data change tracking capabilities for specific solutions. This kind of data change tracking capability mainly starts from the change of a single data state itself, and analyzes the data change relationship involved in the data operation process through dynamic operation mode, so as to locate the problem of the program and analyze the correctness of the program. However, this kind of solution only focuses on the tracking of data changes, and lacks analysis of data dependencies and consumption characteristics. Especially for data subscriptions and data dependencies, it lacks analysis capabilities and cannot completely solve business problems. The problems encountered will affect the efficiency of research and development. In other words, the solutions for managing the data state of global data in the related art only support the tracking of data changes, and do not involve analysis of dependencies between data, nor do they involve which view elements the data is consumed by. Moreover, the output result of data state management in the related art is a log with a linear structure, which cannot reflect the relationship between output results between components, that is, the interactive relationship between logs, the serial relationship of component operations, and the like.
有鉴于此,本公开提供一种数据处理方法,在该方法中,通过插桩处理方式,获取具有消费特性的数据访问该数据的数据源过程中涉及的全局数据,并确定该全局数据中各数据之间的依赖关系进行输出,以实现对全局数据中各数据之间的依赖和消费特性进行分析。In view of this, the present disclosure provides a data processing method. In this method, the global data involved in the process of accessing the data source of the data with consumption characteristics is obtained through the stub processing method, and the global data in the global data are determined. The dependency relationship between data is output to realize the analysis of the dependence and consumption characteristics of each data in the global data.
图1是根据本公开一示例性实施方式中示出的一种数据处理方法流程图。参阅图1所示,该数据处理方法包括如下步骤S101至步骤S103。Fig. 1 is a flowchart of a data processing method shown in an exemplary embodiment of the present disclosure. Referring to FIG. 1, the data processing method includes the following steps S101 to S103.
在步骤S101中,确定待处理的目标数据,并确定目标数据的数据源。In step S101, target data to be processed is determined, and a data source of the target data is determined.
在步骤S102中,在目标数据与数据源之间进行插桩处理,以获取目标数据访问数据源过程中的全局数据。In step S102, instrumentation is performed between the target data and the data source, so as to obtain global data in the process of the target data accessing the data source.
在步骤S103中,确定并输出全局数据中各数据之间的依赖关系。In step S103, determine and output the dependencies among the data in the global data.
本公开中涉及的数据可以是生产者消费者模式中的全局数据。其中,生产者消费者模式中的数据包括生产者和消费者。全局数据的生产者只有一个,但通常会存在多个消费者。即,一个生产者可以对应多个消费者,但是一个消费者只能对应一个生产者。每个生产者以及每个消费者对应一个地址,占一个网络节点,属于预定性数据。图2示出了根据本公开一示例性实施方式中示出的全局数据生产消费关系示意图。参阅图2所示,生产者的数据,可以被消费者1和消费者2消费。本公开涉及的待处理的目标数据可以是生产者消费者模式中的消费者,例如可以是视图元素等具有消费特性的数据。该待处理的目标数据也可以称为是消费者。本公开中,目标数据的数据源可以生产者消费者模式中的生产者。The data involved in the present disclosure may be global data in the producer-consumer pattern. Among them, the data in the producer-consumer mode includes producers and consumers. There is only one producer of global data, but usually there are multiple consumers. That is, a producer can correspond to multiple consumers, but a consumer can only correspond to one producer. Each producer and each consumer corresponds to an address, occupies a network node, and belongs to predetermined data. Fig. 2 shows a schematic diagram of a global data production and consumption relationship according to an exemplary embodiment of the present disclosure. Referring to Figure 2, the producer's data can be consumed by consumer 1 and consumer 2. The target data to be processed involved in the present disclosure may be a consumer in the producer-consumer pattern, for example, data with consumption characteristics such as view elements. The target data to be processed can also be referred to as a consumer. In the present disclosure, the data source of the target data may be a producer in the producer-consumer pattern.
本公开中,在目标数据与数据源之间进行插桩处理可以理解为是在全局数据的源代码中加入插桩代码。通过该插桩代码可以获取到目标数据对数据源访问过程中的全局数据,进而可以获取全局数据之间具有数据依赖关系的内容信息。In the present disclosure, the instrumentation process between the target data and the data source can be understood as adding instrumentation codes to the source code of the global data. Through the instrumentation code, the global data in the process of the target data accessing the data source can be obtained, and then the content information with data dependencies between the global data can be obtained.
本公开一示例性实施方式中,可以在数据源(生产者)和待处理目标数据(消费者)之间插入代理。图3示出了根据本公开一示例性实施方式中示出的在生产者和消费者之间进行插桩的示意图。参阅图3所示,在数据与消费者1和消费者2之间插入代理,其中,对于数据源的数据,消费者需要通过代理进行访问和修改,并保存至访问库中。其中,消费者不能直接接触到数据源中的真实数据,而是通过代理进行访问。In an exemplary embodiment of the present disclosure, a proxy may be inserted between a data source (producer) and target data to be processed (consumer). Fig. 3 shows a schematic diagram of instrumentation between a producer and a consumer according to an exemplary embodiment of the present disclosure. As shown in Figure 3, a proxy is inserted between the data and consumer 1 and consumer 2, where the consumer needs to access and modify the data of the data source through the proxy and save it in the access library. Among them, consumers cannot directly access the real data in the data source, but access it through an agent.
本公开中,通过代理获取任何消费者对数据的访问,可以获取目标数据访问数据源过程中的全局数据。本公开中,每当有消费者访问数据时,计算出当前消费者的所属组件路径、组件名称、当前数据的数据内容等信息,进而确定数据间的依赖关系。In the present disclosure, global data in the process of target data accessing a data source can be obtained by obtaining access to data by any consumer through a proxy. In the present disclosure, whenever a consumer accesses data, information such as the path of the component to which the current consumer belongs, the name of the component, and the data content of the current data are calculated, and then the dependencies between the data are determined.
本公开中,确定了全局数据中各数据之间的依赖关系,可以输出全局数据中各数据之间的依赖关系,以实现对数据间依赖关系的监测,体现各数据之间的关联关系。例如,本公开中可以将全局数据中各数据之间的依 赖关系存储于数据访问库中。In the present disclosure, the dependency relationship between the data in the global data is determined, and the dependency relationship between the data in the global data can be output, so as to realize the monitoring of the dependency relationship between the data and reflect the correlation relationship between the data. For example, in the present disclosure, the dependency relationship among the data in the global data can be stored in the data access library.
本公开提供的数据处理方法,通过在待处理的目标数据与数据源之间进行插桩处理,可以通过该插桩获取目标数据访问数据源过程中的全局数据,并可以获取到全局数据中各数据之间具有依赖关系的内容信息,输出全局数据中各数据之间的依赖关系,可以实现对全局数据之间的依赖关系进行分析。The data processing method provided by this disclosure, through the stub processing between the target data to be processed and the data source, the global data in the process of accessing the data source from the target data can be obtained through the stub, and each data in the global data can be obtained. The content information of the dependency relationship between the data outputs the dependency relationship between the data in the global data, which can realize the analysis of the dependency relationship between the global data.
本公开中,通过在数据源的源代码中加入的插桩代码进行全局数据获取时,可以获取数据的声明、数据的更新、数据到组件的订阅方式等,以使获取到的全局数据的依赖关系,可以覆盖较为全面的全局数据的数据状态。In this disclosure, when the global data is obtained through the instrumentation code added in the source code of the data source, the statement of the data, the update of the data, the subscription method of the data to the component, etc. can be obtained, so that the obtained global data depends on relationship, which can cover the data state of a more comprehensive global data.
图4是根据本公开一示例性实施方式中示出的一种数据处理方法流程图。参阅图4所示,该数据处理方法包括如下步骤S201至步骤S203。Fig. 4 is a flow chart of a data processing method shown in an exemplary embodiment of the present disclosure. Referring to FIG. 4, the data processing method includes the following steps S201 to S203.
在步骤S201中,获取数据声明API(Application Programming Interface,应用程序接口)返回的数据结构,以获取目标数据访问数据源的全局数据声明信息。In step S201, the data structure returned by the data declaration API (Application Programming Interface, application programming interface) is obtained, so as to obtain the global data declaration information of the target data access data source.
在步骤S202中,获取调用数据订阅API进行数据订阅的订阅信息,以获取目标数据访问数据源的全局数据订阅信息。In step S202, the subscription information of calling the data subscription API for data subscription is obtained, so as to obtain the global data subscription information of the target data access data source.
在步骤S203中,获取调用数据更新API进行数据更新的更新信息,以获取目标数据访问数据源的全局数据更新信息。In step S203, the update information for calling the data update API to update the data is obtained, so as to obtain the global data update information of the target data access data source.
可以理解的是,本公开并不限定步骤S201、步骤S202以及步骤S203的执行先后顺序,能够获取到数据的声明、数据的更新、数据到组件的订阅方式等即可。It can be understood that the present disclosure does not limit the order of execution of steps S201, S202, and S203, as long as the statement of data, update of data, subscription method of data to components, etc. can be obtained.
相关技术中,应用于不同的前端MVVM的视图层框架提供的API,虽然形式不同,但在数据声明、更新、订阅的维度上,API提供的功能是相同的。例如,Redux(React)框架中的createStore、Recoil(React)框架中的atom、以及Mobx(React/Vue)框架中的Class@observable,提供的功能都是数据声明API的功能。Redux(React)框架中的dispatchAction、Recoil(React)框架中的useRecoilState/getter、以及Mobx(React/Vue)框架中的Property accessor,提供的功能都是数据更新API的功能。Redux(React)框架中的useSelector、Recoil(React)框架中的useRecoilState/setter、 以及Mobx(React/Vue)框架中的Property setter,提供的功能都是数据订阅API的功能。故,本公开中,通过插桩方式获取数据声明API、数据更新API以及数据订阅API,可以获取到应用于不同前端MVVM框架的应用在运行时的相关信息,并覆盖较为全面的全局数据的数据状态。In related technologies, although the APIs provided by the view layer frameworks applied to different front-end MVVMs have different forms, the functions provided by the APIs are the same in terms of data declaration, update, and subscription. For example, the functions provided by createStore in the Redux (React) framework, atom in the Recoil (React) framework, and Class@observable in the Mobx (React/Vue) framework are all data declaration API functions. The functions provided by dispatchAction in the Redux (React) framework, useRecoilState/getter in the Recoil (React) framework, and Property accessor in the Mobx (React/Vue) framework are all data update API functions. The functions provided by useSelector in the Redux (React) framework, useRecoilState/setter in the Recoil (React) framework, and Property setter in the Mobx (React/Vue) framework are all data subscription API functions. Therefore, in this disclosure, by obtaining the data declaration API, data update API, and data subscription API through stub insertion, relevant information of applications applied to different front-end MVVM frameworks at runtime can be obtained, and more comprehensive global data data can be covered state.
一示例性实施方式中,本公开以Redux框架为例对获取全局数据并确定全局数据之间的依赖关系进行说明。In an exemplary implementation, the present disclosure uses the Redux framework as an example to illustrate acquiring global data and determining dependencies between the global data.
本公开中,在需要获取全局数据声明的相关信息的情况下,基于上述实施例涉及的插桩方案,获取框架的数据声明API最终返回的数据结构。Redux框架下,通过插桩的方式获取createStore返回的store对象,该对象持有web前端应用的全局数据,因此可以在插桩的代理中获取到所有全局数据的声明信息。In the present disclosure, when it is necessary to acquire the relevant information of the global data declaration, based on the instrumentation scheme involved in the above embodiment, the data structure finally returned by the data declaration API of the framework is obtained. Under the Redux framework, the store object returned by createStore is obtained through instrumentation. This object holds the global data of the web front-end application, so the statement information of all global data can be obtained in the instrumented agent.
本公开中,在需要获取组件中对数据的订阅关系的情况下,基于上述实施例涉及的插桩方案,劫持组件中对数据订阅API的相关调用。Redux框架下,在进行useSelector调用时,通过插桩的方式,在代理的访问库中获取到selector函数对对象属性的访问信息,进而能够建立起全局数据状态和订阅状态组件之间的联系,并且能够清晰的确定组件内部具体访问的对象属性。In the present disclosure, when it is necessary to acquire the subscription relationship to data in the component, based on the instrumentation scheme involved in the above-mentioned embodiments, the relevant calls to the data subscription API in the component are hijacked. Under the Redux framework, when using the useSelector call, the access information of the selector function to the object properties is obtained in the access library of the proxy by means of stub insertion, and then the connection between the global data state and the subscription state component can be established, and It can clearly determine the object properties specifically accessed inside the component.
本公开中,在需要获取到数据的更新关系的情况下,基于上述实施例涉及的插桩方案,通过插桩的方式对更新API进行劫持。Redux框架下,组件更新的全局数据都是通过调用dispatchAction方法派发action来更新全局数据的,故,通过插桩获取dispatchAction的调用,就能获取到任何组件对全局数据的改动,进而可以根据调用前后全局数据的变化,确定哪些组件触发了何种数据的更新,进而将整个过程中数据更新状态,清晰的记录下来。In the present disclosure, in the case where the update relationship of the data needs to be acquired, based on the instrumentation solution involved in the above embodiments, the update API is hijacked by instrumentation. Under the Redux framework, the global data updated by a component is updated by calling the dispatchAction method to dispatch an action to update the global data. Therefore, by getting the dispatchAction call through the stub, you can get the changes made by any component to the global data, and then you can use it before and after the call. Changes in global data determine which components trigger which data updates, and then clearly record the status of data updates throughout the process.
本公开中通过插桩方式,对数据声明API、数据更新API以及数据订阅API进行劫持,进而可以构造应用运行期间完整的数据与组件之间的依赖关系,清晰的描述组件的更新过程,能够帮助开发者了解项目并进行技术决策。In this disclosure, the data declaration API, data update API, and data subscription API are hijacked by instrumentation, and then the complete dependency relationship between data and components during application operation can be constructed, and the update process of components can be clearly described, which can help Developers understand the project and make technical decisions.
本公开中涉及的数据依赖关系包括以下至少一项:数据状态、数据状态变化信息、以及数据与组件之间的订阅关系。The data dependency involved in the present disclosure includes at least one of the following: data status, data status change information, and subscription relationship between data and components.
本公开中,基于插桩方式获取全局数据时,从代理中获取消费者对数据的访问,每当有消费者访问数据时,计算出当前消费者的所属组件路径、组件标识、当前数据的数据内容等信息。保存获取到的组件路径、组件标识以及数据内容等。进一步的,本公开中可以对比各次消费者访问数据对应的组件路径、组件标识、数据内容等信息,确定发生变化更新的内容,存储该变化更新的内容,以及产生该变化更新内容的原因,进而可以确定数据状态,数据状态发生的变化更新,以及数据组件间的订阅关系。In this disclosure, when global data is obtained based on stub insertion, the consumer's access to data is obtained from the proxy, and whenever a consumer accesses data, the current consumer's component path, component ID, and current data data are calculated content and other information. Save the obtained component path, component ID, data content, etc. Further, in this disclosure, it is possible to compare the component paths, component identifiers, data content and other information corresponding to each consumer access data to determine the changed and updated content, store the changed and updated content, and the reasons for the changed and updated content. In turn, the data status, the update of changes in the data status, and the subscription relationship between data components can be determined.
本公开中,在确定数据之间的依赖关系时,可以确定获取到的全局数据中各数据所属组件的组件标识,并确定该组件标识相关联的数据依赖关系,组装组件标识所关联的数据依赖关系,能够将各组件的数据状态进行串联,得出数据之间的依赖关系。In the present disclosure, when determining the dependency relationship between data, it is possible to determine the component identifier of the component to which each data belongs in the obtained global data, and determine the data dependency associated with the component identifier, and assemble the data dependency associated with the component identifier. The relationship can connect the data states of each component in series to obtain the dependency relationship between the data.
本公开中对组件标识所关联的数据依赖关系进行组装,实现对数据状态进行记录,并记录发生数据状态变化的原因,相对传统技术中线性结构日志方式的数据状态分析结果,可以明确组件之间输出结果之间的关联关系,更有利于对全局数据的数据状态进行订阅分析。In this disclosure, the data dependencies associated with the component identifiers are assembled to record the data status and the reasons for the data status changes. Compared with the data status analysis results of the linear structure log method in the traditional technology, it is possible to clarify the relationship between components. The correlation between the output results is more conducive to the subscription analysis of the data status of the global data.
进一步的,本公开中基于输出的数据间的数据依赖关系,开发者可以利用全局数据订阅分析,方便的了解到全局数据被哪些组件消费,得到不同组件的依赖关系,针对具有相同依赖关系的组件可以进行封装,该封装的组件可以被复用。Furthermore, based on the data dependencies between the output data in this disclosure, developers can use the global data subscription analysis to easily understand which components consume the global data, obtain the dependencies of different components, and target components with the same dependencies Encapsulation is possible, and the encapsulated components can be reused.
本公开中,可以确定具有相同数据依赖关系的组件,封装该相同的数据依赖关系,相同的依赖关系包括以下至少一项:相同的组件路径、相同的组件标识、以及相同的数据内容。本公开中对相同数据依赖关系进行封装,能够便于开发者复用该封装的数据依赖关系,进行代码重构,提升代码复用度。In the present disclosure, components with the same data dependency may be determined and encapsulated. The same dependency includes at least one of the following: the same component path, the same component identifier, and the same data content. Encapsulating the same data dependencies in the present disclosure can facilitate developers to reuse the encapsulated data dependencies, perform code reconstruction, and improve code reuse.
进一步的,本公开中基于输出的数据间的数据依赖关系,开发者可以利用全局数据订阅分析,基于记录的组件标识,以及组件标识之间的传播链路,确定相对稳定的传播链路对应的组件标识,作为可缓存的数据。Furthermore, based on the data dependencies between output data in this disclosure, developers can use global data subscription analysis, based on recorded component identifiers, and the propagation links between component identifiers, to determine the relatively stable propagation links corresponding to Component ID, as cacheable data.
本公开中,可以确定具备缓存性的组件标识,基于该组件标识确定存在组件依赖的数据。其中,存在组件依赖的数据可以是组件路径相同的数据,也可以理解为是数据进行传播过程中,涉及到的传播链路相同的数据。In the present disclosure, a cacheable component identifier may be determined, and based on the component identifier, it is determined that there is component-dependent data. Among them, the data with component dependencies may be the data with the same component path, or it may be understood as the data with the same propagation links involved in the data propagation process.
本公开中,对于存在组件依赖的数据,可以缓存该存在组件依赖的数据对应的组件标识,进而可以在后续再进行性能优化时,可以直接利用该缓存的组件标识,确定对应的组件路径,提升组件性能优化。换言之,通过本公开可以进行缓存快速定位到组件依赖的数据是否具备可缓存性,以及可缓存数据的传播链路,从而通过增加缓存的手段提升性能。In this disclosure, for data with component dependencies, the component identifiers corresponding to the data with component dependencies can be cached, and then the cached component identifiers can be directly used to determine the corresponding component paths and improve Component performance optimization. In other words, through the present disclosure, caching can quickly locate whether the data that the component depends on is cacheable, and the transmission link of the cacheable data, so as to improve the performance by increasing the cache.
进一步的,本公开中基于输出的数据间的数据依赖关系,输出数据被组件订阅的订阅关系分布图。该订阅关系分布图表征数据与组件之间的订阅关系,构造了应用运行期间完整的数据-组件依赖关系图,能够清晰的描述组件的更新过程。故,通过本公开提供的订阅关系分布图可以确定对象属性以及对象之间的嵌套层次,基于嵌套层次可以判别模块划分是否准确,进而进行代码可维护性评判。Further, in the present disclosure, based on the data dependency relationship between the output data, the output data is a subscription relationship distribution graph subscribed by components. The subscription relationship distribution diagram represents the subscription relationship between data and components, constructs a complete data-component dependency relationship graph during application operation, and can clearly describe the update process of components. Therefore, object attributes and nesting levels between objects can be determined through the subscription relationship distribution diagram provided in this disclosure, and based on the nesting level, it can be judged whether the module division is accurate, and then the code maintainability can be judged.
例如,通过数据被组件订阅的订阅关系分布图,开发者可以进一步观测到数据订阅的深度,进而分析当前模块的划分是否合理。比如,订阅关系分布图中涉及了在全局数据的评论区中进行了全局数据模型的编写。由于评论区只能订阅,不能进行划分,故开发者针对此种情况可以给出评论区进行模块划分不合理的结论。For example, through the subscription relationship distribution diagram of data subscribed by components, developers can further observe the depth of data subscriptions, and then analyze whether the current module division is reasonable. For example, the subscription relationship distribution diagram involves the writing of the global data model in the comment area of the global data. Since the comment area can only be subscribed and cannot be divided, the developer can conclude that it is unreasonable to divide the comment area into modules in this case.
基于相同的构思,本公开实施例还提供一种数据处理装置。Based on the same idea, the embodiment of the present disclosure also provides a data processing device.
可以理解的是,本公开实施例提供的数据处理装置为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。结合本公开实施例中所公开的各示例的单元及算法步骤,本公开实施例能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。本领域技术人员可以对每个特定的应用来使用不同的方法来实现所描述的功能,但是这种实现不应认为超出本公开实施例的技术方案的范围。It can be understood that, in order to realize the above-mentioned functions, the data processing apparatus provided by the embodiments of the present disclosure includes corresponding hardware structures and/or software modules for performing various functions. Combining the units and algorithm steps of each example disclosed in the embodiments of the present disclosure, the embodiments of the present disclosure can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software drives hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the technical solutions of the embodiments of the present disclosure.
作为示例性的实施方式,图5是根据本公开提供的一种数据处理装置的框图。参阅图5所示,本公开提供的数据处理装置500包括确定单元501、处理单元502和输出单元503。As an exemplary implementation, Fig. 5 is a block diagram of a data processing device provided according to the present disclosure. Referring to FIG. 5 , a data processing apparatus 500 provided in the present disclosure includes a determination unit 501 , a processing unit 502 and an output unit 503 .
确定单元501,用于确定待处理的目标数据,并确定目标数据的数据源;处理单元502,用于在目标数据与数据源之间进行插桩处理,以获取 目标数据访问数据源过程中的全局数据;输出单元503,用于确定并输出全局数据中各数据之间的依赖关系。The determination unit 501 is used to determine the target data to be processed, and determine the data source of the target data; the processing unit 502 is used to perform stub processing between the target data and the data source, so as to obtain the target data in the process of accessing the data source Global data; an output unit 503, configured to determine and output the dependency relationship among the data in the global data.
其中,处理单元502用于:获取数据声明应用程序接口返回的数据结构,以获取目标数据访问数据源的全局数据声明信息;获取调用数据订阅应用程序接口进行数据订阅的订阅信息,以获取目标数据访问数据源的全局数据订阅信息;获取调用数据更新应用程序接口进行数据更新的更新信息,以获取目标数据访问数据源的全局数据更新信息。Wherein, the processing unit 502 is used to: obtain the data structure returned by the data declaration API to obtain the global data declaration information of the target data access data source; obtain the subscription information for calling the data subscription API for data subscription to obtain the target data Access the global data subscription information of the data source; obtain the update information of calling the data update application program interface for data update, so as to obtain the global data update information of the target data access data source.
其中,输出单元503用于:确定全局数据中各数据所属组件的组件标识;确定与组件标识相关联的数据依赖关系,数据依赖关系包括以下至少一项:数据状态、数据状态变化信息、以及数据与组件之间的订阅关系;Wherein, the output unit 503 is used to: determine the component identification of the component to which each data in the global data belongs; determine the data dependency relationship associated with the component identification, and the data dependency relationship includes at least one of the following: data status, data status change information, and data Subscription relationship with components;
组装组件标识所关联的数据依赖关系。Assembling components identifies associated data dependencies.
本公开一示例性实施方式中,输出单元503还用于:确定相同的数据依赖关系,相同的依赖关系包括以下至少一项:相同的组件路径、相同的组件标识、以及相同的数据内容;封装相同的数据依赖关系。In an exemplary embodiment of the present disclosure, the output unit 503 is further configured to: determine the same data dependency, the same dependency includes at least one of the following: the same component path, the same component identifier, and the same data content; encapsulation Same data dependencies.
本公开一示例性实施方式中,输出单元503还用于:基于组件标识,确定存在组件依赖的数据,组件依赖的数据包括数据所属的组件路径相同;缓存存在组件依赖的数据对应的组件标识。In an exemplary embodiment of the present disclosure, the output unit 503 is further configured to: based on the component identifier, determine that there is component-dependent data, and the component-dependent data includes the same component path to which the data belongs; and cache the component identifier corresponding to the component-dependent data.
本公开一示例性实施方式中,输出单元503还用于:输出订阅关系分布图,订阅关系分布图用于表征数据与组件之间的订阅关系。In an exemplary embodiment of the present disclosure, the output unit 503 is further configured to: output a subscription relationship distribution graph, where the subscription relationship distribution graph is used to represent the subscription relationship between data and components.
关于本公开上述涉及的装置,其中各个模块执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。Regarding the above-mentioned apparatus of the present disclosure, the specific manner in which each module executes operations has been described in detail in the embodiment of the method, and will not be described in detail here.
本公开的技术方案中,所涉及的用户个人信息的获取,存储和应用等,均符合相关法律法规的规定,且不违背公序良俗。In the technical solution of the present disclosure, the acquisition, storage and application of the user's personal information involved are in compliance with relevant laws and regulations, and do not violate public order and good customs.
根据本公开的实施例,本公开还提供了一种电子设备、一种可读存储介质和一种计算机程序产品。According to the embodiments of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.
图6示出了可以用来实施本公开的实施例的示例电子设备600的示意性框图。电子设备旨在表示各种形式的数字计算机,诸如,膝上型计算机、台式计算机、工作台、个人数字助理、服务器、刀片式服务器、大型计算机、和其它适合的计算机。电子设备还可以表示各种形式的移动装置,诸如,个人数字处理、蜂窝电话、智能电话、可穿戴设备和其它类似的计算 装置。本文所示的部件、它们的连接和关系、以及它们的功能仅仅作为示例,并且不意在限制本文中描述的和/或者要求的本公开的实现。FIG. 6 shows a schematic block diagram of an example electronic device 600 that may be used to implement embodiments of the present disclosure. Electronic device is intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other suitable computers. Electronic devices may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are by way of example only, and are not intended to limit implementations of the disclosure described and/or claimed herein.
如图6所示,设备600包括计算单元601,其可以根据存储在只读存储器(ROM)602中的计算机程序或者从存储单元608加载到随机访问存储器(RAM)603中的计算机程序,来执行各种适当的动作和处理。在RAM603中,还可存储设备600操作所需的各种程序和数据。计算单元601、ROM 602以及RAM 603通过总线604彼此相连。输入/输出(I/O)接口605也连接至总线604。As shown in FIG. 6, the device 600 includes a computing unit 601 that can execute according to a computer program stored in a read-only memory (ROM) 602 or loaded from a storage unit 608 into a random-access memory (RAM) 603. Various appropriate actions and treatments. In the RAM 603, various programs and data necessary for the operation of the device 600 can also be stored. The computing unit 601, ROM 602, and RAM 603 are connected to each other through a bus 604. An input/output (I/O) interface 605 is also connected to the bus 604 .
设备600中的多个部件连接至I/O接口605,包括:输入单元606,例如键盘、鼠标等;输出单元607,例如各种类型的显示器、扬声器等;存储单元608,例如磁盘、光盘等;以及通信单元609,例如网卡、调制解调器、无线通信收发机等。通信单元609允许设备600通过诸如因特网的计算机网络和/或各种电信网络与其他设备交换信息/数据。Multiple components in the device 600 are connected to the I/O interface 605, including: an input unit 606, such as a keyboard, a mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a magnetic disk, an optical disk, etc. ; and a communication unit 609, such as a network card, a modem, a wireless communication transceiver, and the like. The communication unit 609 allows the device 600 to exchange information/data with other devices over a computer network such as the Internet and/or various telecommunication networks.
计算单元601可以是各种具有处理和计算能力的通用和/或专用处理组件。计算单元601的一些示例包括但不限于中央处理单元(CPU)、图形处理单元(GPU)、各种专用的人工智能(AI)计算芯片、各种运行机器学习模型算法的计算单元、数字信号处理器(DSP)、以及任何适当的处理器、控制器、微控制器等。计算单元601执行上文所描述的各个方法和处理,例如数据处理方法。例如,在一些实施例中,数据处理方法可被实现为计算机软件程序,其被有形地包含于机器可读介质,例如存储单元608。在一些实施例中,计算机程序的部分或者全部可以经由ROM 602和/或通信单元609而被载入和/或安装到设备600上。当计算机程序加载到RAM 603并由计算单元601执行时,可以执行上文描述的数据处理方法的一个或多个步骤。备选地,在其他实施例中,计算单元601可以通过其他任何适当的方式(例如,借助于固件)而被配置为执行数据处理方法。The computing unit 601 may be various general-purpose and/or special-purpose processing components having processing and computing capabilities. Some examples of computing units 601 include, but are not limited to, central processing units (CPUs), graphics processing units (GPUs), various dedicated artificial intelligence (AI) computing chips, various computing units that run machine learning model algorithms, digital signal processing processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 executes various methods and processes described above, such as data processing methods. For example, in some embodiments, the data processing method may be implemented as a computer software program tangibly embodied on a machine-readable medium, such as the storage unit 608 . In some embodiments, part or all of the computer program may be loaded and/or installed on the device 600 via the ROM 602 and/or the communication unit 609. When the computer program is loaded into RAM 603 and executed by computing unit 601, one or more steps of the data processing method described above may be performed. Alternatively, in other embodiments, the computing unit 601 may be configured to execute the data processing method in any other suitable manner (for example, by means of firmware).
本文中以上描述的系统和技术的各种实施方式可以在数字电子电路系统、集成电路系统、场可编程门阵列(FPGA)、专用集成电路(ASIC)、专用标准产品(ASSP)、芯片上系统的系统(SOC)、负载可编程逻辑设备(CPLD)、计算机硬件、固件、软件、和/或它们的组合中实现。这些各种实施方式可以包括:实施在一个或者多个计算机程序中,该一个或者 多个计算机程序可在包括至少一个可编程处理器的可编程系统上执行和/或解释,该可编程处理器可以是专用或者通用可编程处理器,可以从存储系统、至少一个输入装置、和至少一个输出装置接收数据和指令,并且将数据和指令传输至该存储系统、该至少一个输入装置、和该至少一个输出装置。Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips Implemented in a system of systems (SOC), load programmable logic device (CPLD), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include being implemented in one or more computer programs executable and/or interpreted on a programmable system including at least one programmable processor, the programmable processor Can be special-purpose or general-purpose programmable processor, can receive data and instruction from storage system, at least one input device, and at least one output device, and transmit data and instruction to this storage system, this at least one input device, and this at least one output device an output device.
用于实施本公开的方法的程序代码可以采用一个或多个编程语言的任何组合来编写。这些程序代码可以提供给通用计算机、专用计算机或其他可编程数据处理装置的处理器或控制器,使得程序代码当由处理器或控制器执行时使流程图和/或框图中所规定的功能/操作被实施。程序代码可以完全在机器上执行、部分地在机器上执行,作为独立软件包部分地在机器上执行且部分地在远程机器上执行或完全在远程机器或服务器上执行。Program codes for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special purpose computer, or other programmable data processing devices, so that the program codes, when executed by the processor or controller, make the functions/functions specified in the flow diagrams and/or block diagrams Action is implemented. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
在本公开的上下文中,机器可读介质可以是有形的介质,其可以包含或存储以供指令执行系统、装置或设备使用或与指令执行系统、装置或设备结合地使用的程序。机器可读介质可以是机器可读信号介质或机器可读储存介质。机器可读介质可以包括但不限于电子的、磁性的、光学的、电磁的、红外的、或半导体系统、装置或设备,或者上述内容的任何合适组合。机器可读存储介质的更具体示例会包括基于一个或多个线的电气连接、便携式计算机盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM或快闪存储器)、光纤、便捷式紧凑盘只读存储器(CD-ROM)、光学储存设备、磁储存设备、或上述内容的任何合适组合。In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media would include one or more wire-based electrical connections, portable computer discs, hard drives, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, compact disk read only memory (CD-ROM), optical storage, magnetic storage, or any suitable combination of the foregoing.
为了提供与用户的交互,可以在计算机上实施此处描述的系统和技术,该计算机具有:用于向用户显示信息的显示装置(例如,CRT(阴极射线管)或者LCD(液晶显示器)监视器);以及键盘和指向装置(例如,鼠标或者轨迹球),用户可以通过该键盘和该指向装置来将输入提供给计算机。其它种类的装置还可以用于提供与用户的交互;例如,提供给用户的反馈可以是任何形式的传感反馈(例如,视觉反馈、听觉反馈、或者触觉反馈);并且可以用任何形式(包括声输入、语音输入或者、触觉输入)来接收来自用户的输入。To provide for interaction with the user, the systems and techniques described herein can be implemented on a computer having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user. ); and a keyboard and pointing device (eg, a mouse or a trackball) through which a user can provide input to the computer. Other kinds of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and can be in any form (including Acoustic input, speech input or, tactile input) to receive input from the user.
可以将此处描述的系统和技术实施在包括后台部件的计算系统(例如, 作为数据服务器)、或者包括中间件部件的计算系统(例如,应用服务器)、或者包括前端部件的计算系统(例如,具有图形用户界面或者网络浏览器的用户计算机,用户可以通过该图形用户界面或者该网络浏览器来与此处描述的系统和技术的实施方式交互)、或者包括这种后台部件、中间件部件、或者前端部件的任何组合的计算系统中。可以通过任何形式或者介质的数字数据通信(例如,通信网络)来将系统的部件相互连接。通信网络的示例包括:局域网(LAN)、广域网(WAN)和互联网。The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., as a a user computer having a graphical user interface or web browser through which a user can interact with embodiments of the systems and techniques described herein), or including such backend components, middleware components, Or any combination of front-end components in a computing system. The components of the system can be interconnected by any form or medium of digital data communication, eg, a communication network. Examples of communication networks include: Local Area Network (LAN), Wide Area Network (WAN) and the Internet.
计算机系统可以包括客户端和服务器。客户端和服务器一般远离彼此并且通常通过通信网络进行交互。通过在相应的计算机上运行并且彼此具有客户端-服务器关系的计算机程序来产生客户端和服务器的关系。服务器可以是云服务器,也可以为分布式系统的服务器,或者是结合了区块链的服务器。A computer system may include clients and servers. Clients and servers are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, a server of a distributed system, or a server combined with a blockchain.
应该理解,可以使用上面所示的各种形式的流程,重新排序、增加或删除步骤。例如,本发公开中记载的各步骤可以并行地执行也可以顺序地执行也可以不同的次序执行,只要能够实现本公开公开的技术方案所期望的结果,本文在此不进行限制。It should be understood that steps may be reordered, added or deleted using the various forms of flow shown above. For example, each step described in the present disclosure may be executed in parallel, sequentially, or in a different order, as long as the desired result of the technical solution disclosed in the present disclosure can be achieved, no limitation is imposed herein.
上述具体实施方式,并不构成对本公开保护范围的限制。本领域技术人员应该明白的是,根据设计要求和其他因素,可以进行各种修改、组合、子组合和替代。任何在本公开的精神和原则之内所作的修改、等同替换和改进等,均应包含在本公开保护范围之内。The specific implementation manners described above do not limit the protection scope of the present disclosure. It should be apparent to those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made depending on design requirements and other factors. Any modifications, equivalent replacements and improvements made within the spirit and principles of the present disclosure shall be included within the protection scope of the present disclosure.

Claims (15)

  1. 一种数据处理方法,包括:A data processing method, comprising:
    确定待处理的目标数据,并确定所述目标数据的数据源;Determine the target data to be processed, and determine the data source of the target data;
    在所述目标数据与所述数据源之间进行插桩处理,以获取所述目标数据访问所述数据源过程中的全局数据;Perform stub insertion between the target data and the data source to obtain global data in the process of the target data accessing the data source;
    确定并输出所述全局数据中各数据之间的依赖关系。Determine and output the dependencies among the data in the global data.
  2. 根据权利要求1所述的方法,其中,所述获取所述目标数据访问所述数据源过程中的全局数据,包括:The method according to claim 1, wherein said obtaining the global data in the process of accessing the target data to the data source comprises:
    获取数据声明应用程序接口返回的数据结构,以获取所述目标数据访问所述数据源的全局数据声明信息;Acquiring the data structure returned by the data declaration application program interface, so as to obtain the global data declaration information for the target data to access the data source;
    获取调用数据订阅应用程序接口进行数据订阅的订阅信息,以获取所述目标数据访问所述数据源的全局数据订阅信息;Obtain subscription information for calling a data subscription application program interface for data subscription, so as to obtain global data subscription information for the target data to access the data source;
    获取调用数据更新应用程序接口进行数据更新的更新信息,以获取所述目标数据访问所述数据源的全局数据更新信息。Obtain update information for calling a data update application program interface to perform data update, so as to acquire global data update information for the target data to access the data source.
  3. 根据权利要求1或2所述的方法,其中,所述确定并输出所述全局数据中各数据之间的依赖关系,包括:The method according to claim 1 or 2, wherein said determining and outputting the dependencies among the data in the global data comprises:
    确定所述全局数据中各数据所属组件的组件标识;Determine the component identifier of the component to which each data in the global data belongs;
    确定与所述组件标识相关联的数据依赖关系,所述数据依赖关系包括以下至少一项:数据状态、数据状态变化信息、以及数据与组件之间的订阅关系;Determine a data dependency relationship associated with the component identifier, the data dependency relationship includes at least one of the following: data status, data status change information, and a subscription relationship between data and components;
    组装组件标识所关联的数据依赖关系。Assembling components identifies associated data dependencies.
  4. 根据权利要求3所述的方法,还包括:The method according to claim 3, further comprising:
    确定相同的数据依赖关系,所述相同的依赖关系包括以下至少一项:相同的组件路径、相同的组件标识、以及相同的数据内容;Determine the same data dependency, the same dependency includes at least one of the following: the same component path, the same component identifier, and the same data content;
    封装所述相同的数据依赖关系。Encapsulates the same data dependencies as described.
  5. 根据权利要求3所述的方法,还包括:The method according to claim 3, further comprising:
    基于所述组件标识,确定存在组件依赖的数据,所述组件依赖的数据包括数据所属的组件路径相同;Based on the component identification, it is determined that there is component-dependent data, and the component-dependent data includes that the components to which the data belong have the same path;
    缓存所述存在组件依赖的数据对应的组件标识。The component identifier corresponding to the data on which the component depends is cached.
  6. 根据权利要求3所述的方法,还包括:The method according to claim 3, further comprising:
    输出订阅关系分布图,所述订阅关系分布图用于表征数据与组件之间的订阅关系。A subscription relationship distribution graph is output, and the subscription relationship distribution graph is used to represent the subscription relationship between data and components.
  7. 一种数据处理装置,包括:A data processing device, comprising:
    确定单元,用于确定待处理的目标数据,并确定所述目标数据的数据源;a determining unit, configured to determine target data to be processed, and determine a data source of the target data;
    处理单元,用于在所述目标数据与所述数据源之间进行插桩处理,以获取所述目标数据访问所述数据源过程中的全局数据;a processing unit, configured to perform instrumentation processing between the target data and the data source, so as to obtain global data in the process of the target data accessing the data source;
    输出单元,用于确定并输出所述全局数据中各数据之间的依赖关系。The output unit is configured to determine and output the dependency relationship among the data in the global data.
  8. 根据权利要求7所述的装置,其中,所述处理单元用于:The device according to claim 7, wherein the processing unit is configured to:
    获取数据声明应用程序接口返回的数据结构,以获取所述目标数据访问所述数据源的全局数据声明信息;Acquiring the data structure returned by the data declaration application program interface, so as to obtain the global data declaration information for the target data to access the data source;
    获取调用数据订阅应用程序接口进行数据订阅的订阅信息,以获取所述目标数据访问所述数据源的全局数据订阅信息;Obtain subscription information for calling a data subscription application program interface for data subscription, so as to obtain global data subscription information for the target data to access the data source;
    获取调用数据更新应用程序接口进行数据更新的更新信息,以获取所述目标数据访问所述数据源的全局数据更新信息。Obtain update information for calling a data update application program interface to perform data update, so as to acquire global data update information for the target data to access the data source.
  9. 根据权利要求7或8所述的装置,其中,所述输出单元用于:The device according to claim 7 or 8, wherein the output unit is used for:
    确定所述全局数据中各数据所属组件的组件标识;Determine the component identifier of the component to which each data in the global data belongs;
    确定与所述组件标识相关联的数据依赖关系,所述数据依赖关系包括以下至少一项:数据状态、数据状态变化信息、以及数据与组件之间的订阅关系;Determine a data dependency relationship associated with the component identifier, the data dependency relationship includes at least one of the following: data status, data status change information, and a subscription relationship between data and components;
    组装组件标识所关联的数据依赖关系。Assembling components identifies associated data dependencies.
  10. 根据权利要求9所述的装置,所述输出单元还用于:The device according to claim 9, the output unit is further used for:
    确定相同的数据依赖关系,所述相同的依赖关系包括以下至少一项:相同的组件路径、相同的组件标识、以及相同的数据内容;Determine the same data dependency, the same dependency includes at least one of the following: the same component path, the same component identifier, and the same data content;
    封装所述相同的数据依赖关系。Encapsulates the same data dependencies as described.
  11. 根据权利要求9所述的装置,所述输出单元还用于:The device according to claim 9, the output unit is further used for:
    基于所述组件标识,确定存在组件依赖的数据,所述组件依赖的数据包括数据所属的组件路径相同;Based on the component identification, it is determined that there is component-dependent data, and the component-dependent data includes that the components to which the data belong have the same path;
    缓存所述存在组件依赖的数据对应的组件标识。The component identifier corresponding to the data on which the component depends is cached.
  12. 根据权利要求9所述的装置,所述输出单元还用于:The device according to claim 9, the output unit is further used for:
    输出订阅关系分布图,所述订阅关系分布图用于表征数据与组件之间的订阅关系。A subscription relationship distribution graph is output, and the subscription relationship distribution graph is used to represent the subscription relationship between data and components.
  13. 一种电子设备,包括:An electronic device comprising:
    至少一个处理器;以及at least one processor; and
    与所述至少一个处理器通信连接的存储器;其中,a memory communicatively coupled to the at least one processor; wherein,
    所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行权利要求1-6中任一项所述的方法。The memory stores instructions executable by the at least one processor, the instructions are executed by the at least one processor, so that the at least one processor can perform any one of claims 1-6. Methods.
  14. 一种存储有计算机指令的非瞬时计算机可读存储介质,其中,所述计算机指令用于使所述计算机执行根据权利要求1-6中任一项所述的方法。A non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause the computer to execute the method according to any one of claims 1-6.
  15. 一种计算机程序产品,包括计算机程序,所述计算机程序在被处理器执行时实现根据权利要求1-6中任一项所述的方法。A computer program product comprising a computer program which, when executed by a processor, implements the method according to any one of claims 1-6.
PCT/CN2022/113850 2021-12-24 2022-08-22 Data processing method and apparatus, device, storage medium and computer program product WO2023116003A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111601053.5 2021-12-24
CN202111601053.5A CN114416029A (en) 2021-12-24 2021-12-24 Data processing method, device, equipment, storage medium and computer program product

Publications (1)

Publication Number Publication Date
WO2023116003A1 true WO2023116003A1 (en) 2023-06-29

Family

ID=81268898

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/113850 WO2023116003A1 (en) 2021-12-24 2022-08-22 Data processing method and apparatus, device, storage medium and computer program product

Country Status (2)

Country Link
CN (1) CN114416029A (en)
WO (1) WO2023116003A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114416029A (en) * 2021-12-24 2022-04-29 北京百度网讯科技有限公司 Data processing method, device, equipment, storage medium and computer program product

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106155897A (en) * 2015-04-16 2016-11-23 腾讯科技(深圳)有限公司 A kind of method for processing business and device
US9690553B1 (en) * 2016-09-26 2017-06-27 International Business Machines Corporation Identifying software dependency relationships
CN110334302A (en) * 2019-05-24 2019-10-15 北京因特睿软件有限公司 Complicated Web application front end motion time analyses method
CN114416029A (en) * 2021-12-24 2022-04-29 北京百度网讯科技有限公司 Data processing method, device, equipment, storage medium and computer program product

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106155897A (en) * 2015-04-16 2016-11-23 腾讯科技(深圳)有限公司 A kind of method for processing business and device
US9690553B1 (en) * 2016-09-26 2017-06-27 International Business Machines Corporation Identifying software dependency relationships
CN110334302A (en) * 2019-05-24 2019-10-15 北京因特睿软件有限公司 Complicated Web application front end motion time analyses method
CN114416029A (en) * 2021-12-24 2022-04-29 北京百度网讯科技有限公司 Data processing method, device, equipment, storage medium and computer program product

Also Published As

Publication number Publication date
CN114416029A (en) 2022-04-29

Similar Documents

Publication Publication Date Title
US9852015B2 (en) Automatic discovery of a JavaScript API
EP2992431B1 (en) Activity based sampling of diagnostics data
JP2022137193A (en) Distributed training method and device of deep learning model, electronic apparatus, storage medium and computer program
US20150121401A1 (en) Graph based data model for api ecosystem insights
US9374417B1 (en) Dynamic specification auditing for a distributed system
WO2023116003A1 (en) Data processing method and apparatus, device, storage medium and computer program product
WO2023221416A1 (en) Information generation method and apparatus, and device and storage medium
CN110109983B (en) Method and device for operating Redis database
CN112860356A (en) API call control method and device, electronic equipment and storage medium
WO2022179070A1 (en) Dependency graph generation method and apparatus, device, storage medium, and program product
CN116360735A (en) Form generation method, device, equipment and medium
US9116713B1 (en) System and method for expression evaluation in a distributed networking environment
EP3923155A2 (en) Method and apparatus for processing snapshot, device, medium and product
CN112970011A (en) Recording pedigrees in query optimization
CN113778849A (en) Method, apparatus, device and storage medium for testing code
CN116541069A (en) Key function evaluation method, device, electronic equipment, medium and program product
US11615061B1 (en) Evaluating workload for database migration recommendations
WO2023103432A1 (en) Code file editing method and apparatus, electronic device, and storage medium
CN113242148B (en) Method, device, medium and electronic equipment for generating monitoring alarm related information
CN113762702A (en) Workflow deployment method, device, computer system and readable storage medium
CN115168358A (en) Database access method and device, electronic equipment and storage medium
CN114780361A (en) Log generation method, device, computer system and readable storage medium
CN114547106A (en) Data query method and device, storage medium and computer system
US20200175402A1 (en) In-database predictive pipeline incremental engine
US20220391182A1 (en) Method and system for model production

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22909330

Country of ref document: EP

Kind code of ref document: A1