Movatterモバイル変換


[0]ホーム

URL:


CN114490244A - Network monitoring method, device, device, storage medium and computer program product - Google Patents

Network monitoring method, device, device, storage medium and computer program product
Download PDF

Info

Publication number
CN114490244A
CN114490244ACN202111630379.0ACN202111630379ACN114490244ACN 114490244 ACN114490244 ACN 114490244ACN 202111630379 ACN202111630379 ACN 202111630379ACN 114490244 ACN114490244 ACN 114490244A
Authority
CN
China
Prior art keywords
class
network monitoring
network
request process
network request
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111630379.0A
Other languages
Chinese (zh)
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.)
Shanghai Ruijia Information Technology Co ltd
Original Assignee
Shanghai Ruijia Information 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 Shanghai Ruijia Information Technology Co ltdfiledCriticalShanghai Ruijia Information Technology Co ltd
Priority to CN202111630379.0ApriorityCriticalpatent/CN114490244A/en
Publication of CN114490244ApublicationCriticalpatent/CN114490244A/en
Pendinglegal-statusCriticalCurrent

Links

Images

Classifications

Landscapes

Abstract

The embodiment of the application provides a network monitoring method, a network monitoring device, a network monitoring equipment, a storage medium and a computer program product. In the embodiment of the application, the element class of the method used in the network request process can be determined, and the element class method is replaced by the preset network monitoring method, so that the application program can utilize the preset network monitoring method to monitor the network request process in the network request process, and the network monitoring of the whole network request process is realized. The meta class is a class which comprises all classes corresponding to the methods used in all network request processes, so that the network monitoring mode does not need to traverse all classes corresponding to the methods used in the network request processes, and the network monitoring efficiency is improved.

Description

Translated fromChinese
网络监测方法、装置、设备、存储介质及计算机程序产品Network monitoring method, device, device, storage medium and computer program product

技术领域technical field

本申请涉及互联网技术领域,尤其涉及一种网络监测方法、装置、设备、存储介质及计算机程序产品。The present application relates to the field of Internet technologies, and in particular, to a network monitoring method, apparatus, device, storage medium and computer program product.

背景技术Background technique

随着互联网技术的发展和终端计算的不断普及,越来越多的应用程序(如APP)被广泛安装和使用。应用程序的性能极大地影响用户使用体验。对于应用程序开发人员,为了了解应用程序性能,经常利用应用性能监测(Application Performance Monitor,APM)技术监测应用程序的网络请求过程;通过对网络请求过程中产生的数据进行分析,确定网络性能。With the development of Internet technology and the continuous popularization of terminal computing, more and more application programs (such as APP) are widely installed and used. The performance of an application greatly affects the user experience. For application developers, in order to understand application performance, Application Performance Monitor (APM) technology is often used to monitor the network request process of the application; the network performance is determined by analyzing the data generated during the network request process.

为了监听整个网络请求过程,需要对网络请求过程中涉及到的类和方法进行监测。但是,由于应用程序多是模块化的,各个模块是解耦的,相当于黑盒,因此,网络请求过程监测时无法确定网络请求过程涉及的方法对应哪些类,因此,需要对应用程序所有的类进行遍历,导致网络监测效率低。In order to monitor the entire network request process, it is necessary to monitor the classes and methods involved in the network request process. However, since most applications are modular, each module is decoupled, which is equivalent to a black box. Therefore, when monitoring the network request process, it is impossible to determine which classes correspond to the methods involved in the network request process. Therefore, it is necessary to Classes are traversed, resulting in low network monitoring efficiency.

发明内容SUMMARY OF THE INVENTION

本申请的多个方面提供一种网络监测方法、装置、设备、存储介质及计算机程序产品,用以提高网络监测效率。Various aspects of the present application provide a network monitoring method, apparatus, device, storage medium and computer program product to improve network monitoring efficiency.

本申请实施例提供一种网络监测方法,包括:The embodiment of the present application provides a network monitoring method, including:

确定应用程序在网络请求过程使用的方法;Determine the method used by the application during the network request process;

确定所述网络请求过程使用的方法对应的类;Determine the class corresponding to the method used in the network request process;

根据所述方法对应的类,确定所述方法对应的类的元类;According to the class corresponding to the method, determine the metaclass of the class corresponding to the method;

将所述元类的方法替换为预设的网络监测方法,以使应用程序执行网络请求过程利用所述预设的网络监测方法进行网络监测;Replace the method of the metaclass with a preset network monitoring method, so that the application program executes the network request process and uses the preset network monitoring method to perform network monitoring;

其中,所述预设的网络监测方法进行网络监测后回调所述元类的方法。The method for calling back the metaclass after the preset network monitoring method performs network monitoring.

本申请实施例还提供一种网络监测装置,包括:The embodiment of the present application also provides a network monitoring device, including:

第一确定模块,用于确定应用程序在网络请求过程使用的方法;The first determination module is used to determine the method used by the application in the network request process;

第二确定模块,用于确定所述网络请求过程使用的方法对应的类;a second determining module, configured to determine the class corresponding to the method used in the network request process;

第三确定模块,用于根据所述方法对应的类,确定所述方法对应的类的元类;a third determining module, configured to determine the metaclass of the class corresponding to the method according to the class corresponding to the method;

替换模块,用于将所述元类的方法替换为预设的网络监测方法,以使应用程序执行网络请求执行过程利用所述预设的网络监测方法进行网络监测;其中,所述预设的网络监测方法进行网络监测后回调所述元类的方法。A replacement module, configured to replace the method of the metaclass with a preset network monitoring method, so that the application program executes the network request execution process and uses the preset network monitoring method to perform network monitoring; wherein the preset network monitoring method is used. The method of calling back the metaclass after the network monitoring method performs network monitoring.

本申请实施例还提供一种电子设备,包括:存储器和处理器;其中,所述存储器,用于存储计算机程序;Embodiments of the present application further provide an electronic device, including: a memory and a processor; wherein, the memory is used to store a computer program;

所述处理器耦合至所述存储器,用于执行所述计算机程序以用于执行上述网络监测方法中的步骤。The processor is coupled to the memory for executing the computer program for performing the steps in the network monitoring method described above.

本申请实施例还提供一种存储有计算机指令的计算机可读存储介质,当所述计算机指令被一个或多个处理器执行时,致使所述一个或多个处理器执行上述网络监测方法中的步骤。The embodiment of the present application further provides a computer-readable storage medium storing computer instructions, when the computer instructions are executed by one or more processors, the one or more processors are caused to execute the above network monitoring method. step.

本申请实施例还提供一种计算机程序产品,包括:计算机程序;当所述计算机程序被处理器执行时,致使所述处理器执行上述网络监测方法中的步骤。An embodiment of the present application further provides a computer program product, comprising: a computer program; when the computer program is executed by a processor, the processor is caused to execute the steps in the above network monitoring method.

在本申请实施例中,可通过确定网络请求过程使用的方法的类的元类,将元类的方法替换为预设的网络监测方法,这样应用程序在执行网络请求过程可利用预设的网络监测方法对网络请求过程进行网络监测,实现整个网络请求过程的网络监测。由于元类为类的类,包含所有网络请求过程使用的方法对应的所有类,因此该网络监测方式无需遍历网络请求过程使用的方法对应的所有类即可实现对应用程序进行网络监测,有助于提高网络监测效率。In this embodiment of the present application, the metaclass of the class of the method used in the network request process can be determined, and the method of the metaclass can be replaced with a preset network monitoring method, so that the application program can use the preset network when performing the network request process. The monitoring method performs network monitoring on the network request process, and realizes the network monitoring of the entire network request process. Since the metaclass is a class, including all classes corresponding to the methods used in all network request processes, this network monitoring method can implement network monitoring on applications without traversing all classes corresponding to methods used in network request processes, which is helpful for To improve the efficiency of network monitoring.

附图说明Description of drawings

此处所说明的附图用来提供对本申请的进一步理解,构成本申请的一部分,本申请的示意性实施例及其说明用于解释本申请,并不构成对本申请的不当限定。在附图中:The drawings described herein are used to provide further understanding of the present application and constitute a part of the present application. The schematic embodiments and descriptions of the present application are used to explain the present application and do not constitute an improper limitation of the present application. In the attached image:

图1为本申请实施例提供的网络监测方法的流程示意图;1 is a schematic flowchart of a network monitoring method provided by an embodiment of the present application;

图2为本申请实施例提供的网络请求过程示意图;2 is a schematic diagram of a network request process provided by an embodiment of the present application;

图3为本申请实施例提供的另一网络监测方法的流程示意图;3 is a schematic flowchart of another network monitoring method provided by an embodiment of the present application;

图4为本申请实施例提供的网络监测装置的结构示意图;FIG. 4 is a schematic structural diagram of a network monitoring apparatus provided by an embodiment of the present application;

图5为本申请实施例提供的电子设备的结构示意图。FIG. 5 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.

具体实施方式Detailed ways

为使本申请的目的、技术方案和优点更加清楚,下面将结合本申请具体实施例及相应的附图对本申请技术方案进行清楚、完整地描述。显然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。In order to make the objectives, technical solutions and advantages of the present application clearer, the technical solutions of the present application will be clearly and completely described below with reference to the specific embodiments of the present application and the corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.

针对现有网络监测效率低的技术问题,本申请实施例提供一种解决方案,基本思路是:通过确定网络请求过程使用的方法的类的元类,将元类的方法替换为预设的网络监测方法,这样应用程序在执行网络请求过程可利用预设的网络监测方法对网络请求过程进行网络监测,实现整个网络请求过程的网络监测。由于元类为类的类,包含所有网络请求过程使用的方法对应的所有类,因此该网络监测方式无需遍历网络请求过程使用的方法对应的所有类即可实现对应用程序进行网络监测,有助于提高网络监测效率。Aiming at the technical problem of low efficiency of existing network monitoring, the embodiment of the present application provides a solution. The basic idea is: by determining the metaclass of the class of the method used in the network request process, and replacing the method of the metaclass with a preset network The monitoring method, so that the application program can use the preset network monitoring method to monitor the network request process during the execution of the network request process, so as to realize the network monitoring of the entire network request process. Since the metaclass is a class, including all classes corresponding to the methods used in all network request processes, this network monitoring method can implement network monitoring on applications without traversing all classes corresponding to methods used in network request processes, which is helpful for To improve the efficiency of network monitoring.

以下结合附图,详细说明本申请各实施例提供的技术方案。The technical solutions provided by the embodiments of the present application will be described in detail below with reference to the accompanying drawings.

应注意到:相同的标号在下面的附图以及实施例中表示同一物体,因此,一旦某一物体在一个附图或实施例中被定义,则在随后的附图和实施例中不需要对其进行进一步讨论。It should be noted that the same reference numerals refer to the same object in the following figures and examples, so once an object is defined in one figure or example, it is not necessary to refer to the following figures and examples It is discussed further.

图1为本申请实施例提供的网络监测方法的流程示意图。如图1所示,该网络监测方法包括:FIG. 1 is a schematic flowchart of a network monitoring method provided by an embodiment of the present application. As shown in Figure 1, the network monitoring method includes:

101、确定应用程序在网络请求过程使用的方法。101. Determine a method used by the application in the network request process.

102、确定网络请求过程使用的方法对应的类。102. Determine a class corresponding to the method used in the network request process.

103、根据方法对应的类,确定方法对应的类的元类。103. Determine the metaclass of the class corresponding to the method according to the class corresponding to the method.

104、将元类的方法替换为预设的网络监测方法,以使应用程序执行网络请求过程利用预设的网络监测方法进行网络监测。其中,预设的网络监测方法进行网络监测后回调元类的方法。104. Replace the method of the metaclass with a preset network monitoring method, so that the application performs network monitoring using the preset network monitoring method during the network request process. The preset network monitoring method calls back the method of the metaclass after performing network monitoring.

在本申请实施例中,应用程序是指为完成某项或多项特定工作的计算机程序,它运行在用户模式,可以和用户进行交互,具有可视的用户界面。在本申请实施例中,不限定应用程序的具体实现形态。例如,应用程序可为APP、网页、小程序等,但不限于此。In this embodiment of the present application, an application program refers to a computer program for completing one or more specific tasks, it runs in a user mode, can interact with a user, and has a visual user interface. In the embodiments of the present application, the specific implementation form of the application is not limited. For example, the application program may be an APP, a web page, an applet, etc., but is not limited thereto.

由于应用程序多是模块化的,各个模块是解耦的,相当于黑盒,因此,网络请求过程监测时无法确定网络请求过程涉及的方法对应哪些类,因此,需要对应用程序所有的类进行遍历,导致网络监测效率低。Since most applications are modular, each module is decoupled, which is equivalent to a black box. Therefore, when monitoring the network request process, it is impossible to determine which classes the methods involved in the network request process correspond to. Therefore, all classes of the application need to be checked. Traversal, resulting in low network monitoring efficiency.

在本申请实施例中,网络监测是指对网络请求过程进行监测,可对网络请求整个过程进行监测,也可对网络请求的某个过程进行监测。在本申请实施例中,不限定网络请求的具体过程。在一些实施例中,如图2所示,网络请求过程可包括:从请求队列取网络请求阶段、域名(Domain Name Server,DNS)解析阶段、建立连接阶段、连接建立后发送网络请求阶段以及接收网络请求的响应报文阶段等。其中,建立连接阶段包括:安全连接阶段,即安全验证通过后建立连接。In the embodiment of the present application, the network monitoring refers to monitoring the network request process, and may monitor the entire network request process, and may also monitor a certain process of the network request. In this embodiment of the present application, the specific process of the network request is not limited. In some embodiments, as shown in FIG. 2 , the network request process may include: a network request stage from the request queue, a domain name (Domain Name Server, DNS) resolution stage, a connection establishment stage, a network request sending stage after the connection is established, and a receiving The response message phase of the network request, etc. The connection establishment phase includes: a secure connection phase, that is, the connection is established after the security verification is passed.

网络请求过程,针对当前执行的网络请求阶段,需要调用该阶段对应的方法来执行该阶段涉及的网络过程。例如,调用从请求队列取网络请求对应的方法,执行从请求队列取网络请求的过程等等。因此,为了实现网络请求过程的监测,在步骤101中,可确定应用程序在网络请求过程中至少一个阶段对应需调用的方法(用于执行该阶段涉及的网络过程)。In the network request process, for the currently executed network request stage, the method corresponding to this stage needs to be called to execute the network process involved in this stage. For example, calling the method corresponding to fetching network requests from the request queue, executing the process of fetching network requests from the request queue, and so on. Therefore, in order to monitor the network request process, instep 101, it may be determined that the application corresponds to the method to be called in at least one stage of the network request process (for executing the network process involved in this stage).

在本申请实施例中,不限定确定应用程序在网络请求过程使用的方法的具体实施方式。在一些实施例中,可由技术人员对应用程序进行梳理,得到应用程序在网络请求过程使用的方法。进一步,可由技术人员手动输入应用程序在网络请求过程使用的方法。对于计算设备,可确定技术人员输入的方法为应用程序在网络请求过程使用的方法。In the embodiments of the present application, the specific implementation of the method for determining the application program used in the network request process is not limited. In some embodiments, the technical personnel can sort out the application to obtain the method used by the application in the network request process. Further, the method used by the application in the network request process can be manually input by the technician. For computing devices, the method input by the technician may be determined to be the method used by the application during the network request process.

具体地,可提供人机交互界面。该交互界面设置有方法配置项,该方法配置项为技术人员提供网络请求过程使用的方法提供输入接口。技术人员可通过该方法配置项接口设置网络请求过程使用的方法。相应地,针对计算设备,可响应于针对网络请求过程对应的方法配置项的设置操作,确定设置操作关联的方法为应用程序在网络请求过程使用的方法。Specifically, a human-machine interface can be provided. The interactive interface is provided with a method configuration item, and the method configuration item provides an input interface for the technician to provide the method used in the network request process. Technicians can set the method used in the network request process through the method configuration item interface. Correspondingly, for the computing device, in response to the setting operation of the method configuration item corresponding to the network request process, it may be determined that the method associated with the setting operation is the method used by the application in the network request process.

在另一些实施例中,应用程序对应的方法分别对应有应用程序接口(ApplicationProgramming Interface,API),应用程序通过调用方法的API使用对应的方法。对于API,应用程序的开发人员可预先设置API的描述信息。每个API的描述信息可描述该API的用途,如在哪个阶段使用等等。相应地,可根据预先设置的API的描述信息,确定应用程序在网络请求过程使用的方法。In other embodiments, the methods corresponding to the application programs respectively correspond to application programming interfaces (Application Programming Interface, API), and the application programs use the corresponding methods by calling the APIs of the methods. For the API, the developer of the application can preset the description information of the API. The description information of each API can describe the purpose of the API, such as at which stage it is used, and so on. Correspondingly, the method used by the application in the network request process can be determined according to the preset description information of the API.

可选地,可对API的描述信息进行语义分析,以确定API对应方法的用途;并确定用于网络请求过程的方法为应用程序在网络请求过程使用的方法。Optionally, semantic analysis can be performed on the description information of the API to determine the purpose of the corresponding method of the API; and the method used in the network request process is determined as the method used by the application in the network request process.

由于类(class)为在面向对象编程中是一种面向对象计算机编程语言的构造,描述了所创建的对象共同的属性和方法。因此,为了实现对网络请求过程的监测,在步骤102中,还可确定网络请求过程使用的方法对应的类。具体地,可根据预设的方法与类之间的对应关系,确定网络请求过程使用的方法对应的类。例如,可将网络请求过程使用的方法在预设的方法与类之间的对应关系中进行匹配,确定网络请求过程使用的方法匹配中的类,即为网络请求过程使用的方法对应的类。Since a class is an object-oriented computer programming language construct in object-oriented programming, it describes the common properties and methods of the created objects. Therefore, in order to monitor the network request process, instep 102, the class corresponding to the method used in the network request process can also be determined. Specifically, the class corresponding to the method used in the network request process can be determined according to the preset correspondence between the method and the class. For example, the method used in the network request process can be matched in the preset correspondence between the method and the class, and the class in the matching method of the method used in the network request process is determined, that is, the class corresponding to the method used in the network request process.

考虑到元类(meta class)是类的类。普通的类(class)定义的是特定对象的行为,元类(meta class)定义的则是特定的类及其对象的行为,因此,在本申请实施例中,为了提高应用程序的网络监测效率,在步骤103中,可根据网络请求过程使用的方法对应的类,确定网络请求过程使用的方法对应的类的元类。Consider that a meta class is a class of classes. A common class (class) defines the behavior of a specific object, and a meta class (meta class) defines the behavior of a specific class and its objects. Therefore, in this embodiment of the present application, in order to improve the network monitoring efficiency of the application program , instep 103, the metaclass of the class corresponding to the method used in the network request process may be determined according to the class corresponding to the method used in the network request process.

由于类的方法存储在元类中,类通过Isa指针即可找到所属的元类。因此,可通过获取网络请求过程使用的方法对应的类中的Isa指针找到所属的元类。对于Objective-C语言编写的应用程序,由于Objective-C是基于C语言加入面向对象特性和消息转发机制的动态语言,即函数调用变成了消息发送,在编译期不能知道要调用哪个函数。因此,Objective-C不仅需要一个编译器,还需要运行时(Runtime)系统动态的创建类和对象,进行消息发送和转发。其中,运行时机制可解决如何在运行时期找到调用方法。Since the methods of the class are stored in the metaclass, the class can find the metaclass to which it belongs through the Isa pointer. Therefore, the metaclass to which it belongs can be found by obtaining the Isa pointer in the class corresponding to the method used in the network request process. For applications written in Objective-C language, since Objective-C is a dynamic language based on C language with object-oriented features and message forwarding mechanisms, that is, function calls become message sending, and it is impossible to know which function to call at compile time. Therefore, Objective-C not only requires a compiler, but also requires the runtime system to dynamically create classes and objects for message sending and forwarding. Among them, the runtime mechanism addresses how to find the calling method at runtime.

基于此,步骤103的一种实施方式为:可利用运行时机制运行网络请求过程使用的方法对应的类,以获取网络请求过程使用的方法对应的类中的Isa指针指向的类;并确定Isa指针指向的类为网络请求过程使用的方法对应的类的元类。Based on this, an implementation ofstep 103 is: the class corresponding to the method used by the network request process can be run by using the runtime mechanism to obtain the class pointed to by the Isa pointer in the class corresponding to the method used by the network request process; and determining the Isa The class pointed to by the pointer is the metaclass of the class corresponding to the method used by the network request process.

在确定出网络请求过程使用的方法对应的类的元类之后,在步骤104中,可将元类的方法替换为预设的网络监测方法,以使应用程序执行网络请求过程利用预设的网络监测方法进行网络监测。其中,预设的网络监测方法进行网络监测后可回调元类的方法,保证原有网络请求过程的闭环。After the metaclass of the class corresponding to the method used in the network request process is determined, instep 104, the method of the metaclass can be replaced with a preset network monitoring method, so that the application executes the network request process using the preset network Monitoring method for network monitoring. The preset network monitoring method can call back the method of the metaclass after performing network monitoring, so as to ensure the closed loop of the original network request process.

在本申请实施例中,通过确定网络请求过程使用的方法的类的元类,将元类的方法替换为预设的网络监测方法,这样应用程序在执行网络请求过程可利用预设的网络监测方法对网络请求过程进行网络监测,实现整个网络请求过程的网络监测。由于元类为类的类,包含所有网络请求过程使用的方法对应的所有类,因此该网络监测方式无需遍历网络请求过程使用的方法对应的所有类即可实现对应用程序进行网络监测,有助于提高网络监测效率。In the embodiment of the present application, by determining the metaclass of the class of the method used in the network request process, the method of the metaclass is replaced with a preset network monitoring method, so that the application program can use the preset network monitoring method when performing the network request process. The method performs network monitoring on the network request process, and realizes the network monitoring of the entire network request process. Since the metaclass is a class, including all classes corresponding to the methods used in all network request processes, this network monitoring method can implement network monitoring on applications without traversing all classes corresponding to methods used in network request processes, which is helpful for To improve the efficiency of network monitoring.

本实施例提供的网络监测方法,可在运行时动态地将代码切入到指定方法(即预设的网络监测方法)上,从而实现了面向切面编程(Aspect Oriented Programming,AOP)。The network monitoring method provided by this embodiment can dynamically switch code to a specified method (ie, a preset network monitoring method) at runtime, thereby realizing Aspect Oriented Programming (AOP).

在本申请实施例中,不限定将元类的方法替换为预设的网络监测方法的具体实施方式。在一些实施例中,如图3中步骤304所示,可利用钩子(HOOK)技术在应用程序中添加预设的网络监测方法。其中,图3中的步骤301-303的描述,可参见上述图1的相关内容,在此不再赘述。In the embodiments of the present application, the specific implementation of replacing the metaclass method with the preset network monitoring method is not limited. In some embodiments, as shown instep 304 in FIG. 3 , a preset network monitoring method may be added to the application by using a hook (HOOK) technology. For the description ofsteps 301 to 303 in FIG. 3 , reference may be made to the above-mentioned related content of FIG. 1 , which will not be repeated here.

进一步,在步骤305中,可将预设的网络监测方法注册至元类中;并在步骤306中,通过方法交互(method swizzling)方法交换元类的方法和预设的网络监测方法的函数体,从而使预设的网络监测方法替换元类的方法。其中,预设的网络监测方法可在执行完网络监测后回调元类的方法,实现原有网络请求过程的闭环,即实现原有网络请求过程的正常运行。Further, instep 305, the preset network monitoring method can be registered in the metaclass; and instep 306, the method of the metaclass and the function body of the preset network monitoring method are exchanged through a method swizzling method , so that the default network monitoring method replaces the metaclass method. The preset network monitoring method can call back the method of the metaclass after the network monitoring is performed, so as to realize the closed loop of the original network request process, that is, to realize the normal operation of the original network request process.

在一些实施例中,可通过method swizzling方法交换元类的方法和预设的网络监测方法的函数体对应的IMP指针,从而交换元类的方法和所述预设的网络监测方法的函数体。In some embodiments, the IMP pointer corresponding to the function body of the metaclass method and the preset network monitoring method can be exchanged through the method swizzling method, thereby exchanging the metaclass method and the function body of the preset network monitoring method.

在将元类的方法替换为预设的网络监测方法之后,应用程序执行网络请求过程可利用预设的网络请求方法进行网络监测。在本申请实施例中,不限定预设的网络监测方法的具体实现方法。在一些实施例中,预设的网络监测方法可实现为获取网络请求过程中每个网络请求阶段的执行时间,则预设的网络监测方法可实现为获取各网络请求阶段的开始时间和结束时间等等。在另一些实施例中,针对网络请求响应阶段的网络监测方法可实现为获取网络请求的响应数据,并对响应数据进行安全性校验等等。After replacing the method of the metaclass with the preset network monitoring method, the application program may use the preset network request method to perform network monitoring during the network request process. In the embodiments of the present application, the specific implementation method of the preset network monitoring method is not limited. In some embodiments, the preset network monitoring method may be implemented to obtain the execution time of each network request stage in the network request process, and the preset network monitoring method may be implemented to obtain the start time and end time of each network request stage and many more. In other embodiments, the network monitoring method for the network request response phase may be implemented as acquiring response data of the network request, performing security verification on the response data, and the like.

需要说明的是,上述实施例所提供方法的各步骤的执行主体均可以是同一设备,或者,该方法也由不同设备作为执行主体。比如,步骤101和102的执行主体可以为设备A;又比如,步骤101的执行主体可以为设备A,步骤102的执行主体可以为设备B;等等。It should be noted that, the execution subject of each step of the method provided in the above-mentioned embodiments may be the same device, or the method may also be executed by different devices. For example, the execution body ofsteps 101 and 102 may be device A; for another example, the execution body ofstep 101 may be device A, and the execution body ofstep 102 may be device B; and so on.

另外,在上述实施例及附图中的描述的一些流程中,包含了按照特定顺序出现的多个操作,但是应该清楚了解,这些操作可以不按照其在本文中出现的顺序来执行或并行执行,操作的序号如101、102等,仅仅是用于区分开各个不同的操作,序号本身不代表任何的执行顺序。另外,这些流程可以包括更多或更少的操作,并且这些操作可以按顺序执行或并行执行。In addition, in some of the processes described in the above embodiments and the accompanying drawings, multiple operations appearing in a specific order are included, but it should be clearly understood that these operations may be performed out of the order in which they appear in this document or performed in parallel , the sequence numbers of the operations, such as 101, 102, etc., are only used to distinguish different operations, and the sequence numbers themselves do not represent any execution order. Additionally, these flows may include more or fewer operations, and these operations may be performed sequentially or in parallel.

相应地,本申请实施例还提供一种存储有计算机指令的计算机可读存储介质,当计算机指令被一个或多个处理器执行时,致使一个或多个处理器执行上述网络监测方法中的步骤。Correspondingly, the embodiments of the present application also provide a computer-readable storage medium storing computer instructions. When the computer instructions are executed by one or more processors, one or more processors are caused to perform the steps in the above network monitoring method. .

本申请实施例还提供一种计算机程序产品,包括:计算机程序;当所述计算机程序被处理器执行时,致使所述处理器执行上述网络监测方法中的步骤。在本申请实施例中,不限定计算机程序产品的具体实现形态。在一些实施例中,计算机程序产品可实现为软件功能模块或插件等,该计算机程序产品可集成于应用程序中,对应用程序进行网络监测。其中,关于应用程序的实现形态,可参见上述实施例的相关内容,在此不再赘述。An embodiment of the present application further provides a computer program product, comprising: a computer program; when the computer program is executed by a processor, the processor is caused to execute the steps in the above network monitoring method. In the embodiments of the present application, the specific implementation form of the computer program product is not limited. In some embodiments, the computer program product may be implemented as a software function module or plug-in, etc., and the computer program product may be integrated into an application program to perform network monitoring on the application program. For the implementation form of the application program, reference may be made to the relevant content of the foregoing embodiment, and details are not described herein again.

图4为本申请实施例提供的网络监测装置的结构示意图。如图4所示,该网络监测装置可包括:第一确定模块40a、第二确定模块40b、第三确定模块40c及替换模块40d。FIG. 4 is a schematic structural diagram of a network monitoring apparatus according to an embodiment of the present application. As shown in FIG. 4 , the network monitoring apparatus may include: afirst determination module 40a, asecond determination module 40b, athird determination module 40c, and areplacement module 40d.

其中,第一确定模块40a,用于确定应用程序在网络请求过程使用的方法。Wherein, the first determiningmodule 40a is configured to determine the method used by the application in the network request process.

第二确定模块40b,用于确定网络请求过程使用的方法对应的类。Thesecond determination module 40b is configured to determine the class corresponding to the method used in the network request process.

第三确定模块40c,用于根据方法对应的类,确定方法对应的类的元类。The third determiningmodule 40c is configured to determine the metaclass of the class corresponding to the method according to the class corresponding to the method.

替换模块40d,用于将元类的方法替换为预设的网络监测方法,以使应用程序执行网络请求执行过程利用预设的网络监测方法进行网络监测;其中,预设的网络监测方法进行网络监测后回调元类的方法。Thereplacement module 40d is used to replace the metaclass method with a preset network monitoring method, so that the application program executes the network request execution process and uses the preset network monitoring method to perform network monitoring; wherein, the preset network monitoring method performs network monitoring. Method to call back metaclass after monitoring.

在一些实施例中,第一确定模块40a,在确定应用程序在网络请求过程使用的方法时,具体用于:根据预先设置的应用程序接口的描述信息,确定网络请求过程使用的方法;或者,响应于针对网络请求过程对应的方法配置项的设置操作,确定设置操作关联的方法为网络请求过程使用的方法。In some embodiments, the first determiningmodule 40a, when determining the method used by the application in the network request process, is specifically configured to: determine the method used in the network request process according to preset description information of the application program interface; or, In response to the setting operation for the method configuration item corresponding to the network request process, it is determined that the method associated with the setting operation is the method used by the network request process.

在另一些实施例中,第二确定模块40b在确定网络请求过程使用的方法对应的类时,具体用于:根据预设的方法与类之间的对应关系,确定网络请求过程使用的方法对应的类。In other embodiments, when determining the class corresponding to the method used in the network request process, the second determiningmodule 40b is specifically configured to: determine the corresponding relationship between the method used in the network request process according to the preset correspondence between the method and the class the type.

在又一些实施例中,第三确定模块40c在确定方法对应的类的元类时,具体用于:利用运行时机制运行方法对应的类,以获取方法对应的类中的Isa指针指向的类;并确定Isa指针指向的类为方法对应的类的元类。In still other embodiments, when determining the metaclass of the class corresponding to the method, the third determiningmodule 40c is specifically configured to: use the runtime mechanism to run the class corresponding to the method to obtain the class pointed to by the Isa pointer in the class corresponding to the method ; And determine that the class pointed to by the Isa pointer is the metaclass of the class corresponding to the method.

可选地,替换模块40d在将元类的方法替换为预设的网络监测方法时,具体用于:利用钩子技术在应用程序中添加预设的网络监测方法;将预设的网络监测方法注册至元类中;并通过方法交互方法交换元类的方法和预设的网络监测方法的函数体,以使预设的网络监测方法替换元类的方法。Optionally, when replacing the metaclass method with a preset network monitoring method, thereplacement module 40d is specifically used for: adding a preset network monitoring method in the application by using the hook technology; registering the preset network monitoring method; into the metaclass; and exchange the method of the metaclass and the function body of the preset network monitoring method through the method interaction method, so that the preset network monitoring method replaces the method of the metaclass.

进一步,替换模块40d在通过方法交互方法交换元类的方法和预设的网络监测方法的函数体时,具体用于:通过方法交互方法交换元类的方法和预设的网络监测方法的函数体对应的IMP指针,以交换元类的方法和预设的网络监测方法的函数体。Further, thereplacement module 40d is specifically used for exchanging the metaclass method and the function body of the preset network monitoring method through the method interaction method when exchanging the metaclass method and the function body of the preset network monitoring method through the method interaction method. The corresponding IMP pointer to exchange the metaclass method and the function body of the preset network monitoring method.

本申请实施例提供的网络监测装置,可通过确定网络请求过程使用的方法的类的元类,将元类的方法替换为预设的网络监测方法,这样应用程序在执行网络请求过程可利用预设的网络监测方法对网络请求过程进行网络监测,实现整个网络请求过程的网络监测。由于元类为类的类,包含所有网络请求过程使用的方法对应的所有类,因此该网络监测方式无需遍历网络请求过程使用的方法对应的所有类即可实现对应用程序进行网络监测,有助于提高网络监测效率。The network monitoring apparatus provided by the embodiment of the present application can replace the method of the metaclass with the preset network monitoring method by determining the metaclass of the class of the method used in the network request process, so that the application program can use the predetermined network monitoring method during the execution of the network request process. The designed network monitoring method performs network monitoring on the network request process, and realizes the network monitoring of the entire network request process. Since the metaclass is a class, including all classes corresponding to the methods used in all network request processes, this network monitoring method can implement network monitoring on applications without traversing all classes corresponding to methods used in network request processes, which is helpful for To improve the efficiency of network monitoring.

图5为本申请实施例提供的电子设备的结构示意图。在本申请实施例中,不限定电子设备的具体实现形态。在一些实施例中,电子设备可实现为电脑、手机、可穿戴设备等终端设备;也可实现为单一的服务器,或者云化的服务器阵列等等。FIG. 5 is a schematic structural diagram of an electronic device provided by an embodiment of the present application. In the embodiments of the present application, the specific implementation form of the electronic device is not limited. In some embodiments, the electronic device may be implemented as a terminal device such as a computer, a mobile phone, a wearable device, or the like; it may also be implemented as a single server, or a cloud-based server array, or the like.

如图5所示,该电子设备可包括:存储器50a和处理器50b。其中,存储器50a,用于存储计算机程序。As shown in FIG. 5, the electronic device may include: amemory 50a and aprocessor 50b. Among them, thememory 50a is used to store computer programs.

处理器50b耦合至存储器50a,用于执行计算机程序以用于:确定应用程序在网络请求过程使用的方法;确定网络请求过程使用的方法对应的类;根据方法对应的类,确定方法对应的类的元类;并将元类的方法替换为预设的网络监测方法,以使应用程序执行网络请求过程利用预设的网络监测方法进行网络监测;其中,预设的网络监测方法进行网络监测后回调元类的方法。Theprocessor 50b is coupled to thememory 50a for executing a computer program for: determining the method used by the application in the network request process; determining the class corresponding to the method used in the network request process; determining the class corresponding to the method according to the class corresponding to the method and replace the method of the metaclass with the preset network monitoring method, so that the application program performs the network request process and uses the preset network monitoring method to monitor the network; wherein, after the network monitoring is performed by the preset network monitoring method Callback method of the metaclass.

在一些实施例中,处理器50b在确定应用程序在网络请求过程使用的方法时,具体用于:根据预先设置的应用程序接口的描述信息,确定网络请求过程使用的方法;或者,响应于针对网络请求过程对应的方法配置项的设置操作,确定设置操作关联的方法为网络请求过程使用的方法。In some embodiments, when determining the method used by the application in the network request process, theprocessor 50b is specifically configured to: determine the method used in the network request process according to preset description information of the application program interface; The setting operation of the method configuration item corresponding to the network request process determines that the method associated with the setting operation is the method used by the network request process.

在另一些实施例中,处理器50b在确定网络请求过程使用的方法对应的类时,具体用于:根据预设的方法与类之间的对应关系,确定网络请求过程使用的方法对应的类。In other embodiments, when determining the class corresponding to the method used in the network request process, theprocessor 50b is specifically configured to: determine the class corresponding to the method used in the network request process according to a preset correspondence between methods and classes .

在又一些实施例中,处理器50b在确定方法对应的类的元类时,具体用于:利用运行时机制运行方法对应的类,以获取方法对应的类中的Isa指针指向的类;并确定Isa指针指向的类为方法对应的类的元类。In still other embodiments, when determining the metaclass of the class corresponding to the method, theprocessor 50b is specifically configured to: use the runtime mechanism to run the class corresponding to the method to obtain the class pointed to by the Isa pointer in the class corresponding to the method; and Determines that the class pointed to by the Isa pointer is the metaclass of the class corresponding to the method.

可选地,处理器50b在将元类的方法替换为预设的网络监测方法时,具体用于:利用钩子技术在应用程序中添加预设的网络监测方法;将预设的网络监测方法注册至元类中;并通过方法交互方法交换元类的方法和预设的网络监测方法的函数体,以使预设的网络监测方法替换元类的方法。Optionally, when replacing the metaclass method with a preset network monitoring method, theprocessor 50b is specifically configured to: use the hook technology to add a preset network monitoring method to the application; register the preset network monitoring method; into the metaclass; and exchange the method of the metaclass and the function body of the preset network monitoring method through the method interaction method, so that the preset network monitoring method replaces the method of the metaclass.

进一步,处理器50b在通过方法交互方法交换元类的方法和预设的网络监测方法的函数体时,具体用于:通过方法交互方法交换元类的方法和预设的网络监测方法的函数体对应的IMP指针,以交换元类的方法和预设的网络监测方法的函数体。Further, when exchanging the metaclass method and the function body of the preset network monitoring method through the method interaction method, theprocessor 50b is specifically used for: exchanging the metaclass method and the function body of the preset network monitoring method through the method interaction method The corresponding IMP pointer to exchange the metaclass method and the function body of the preset network monitoring method.

在一些可选实施方式中,如图5所示,该电子设备还可以包括:通信组件50c、电源组件50d、显示组件50e及音频组件50f等组件。图5中仅示意性给出部分组件,并不意味着电子设备必须包含图5所示全部组件,也不意味着电子设备只能包括图5所示组件。In some optional embodiments, as shown in FIG. 5 , the electronic device may further include: acommunication component 50c, apower supply component 50d, adisplay component 50e, anaudio component 50f and other components. Only some components are schematically shown in FIG. 5 , which does not mean that the electronic device must include all the components shown in FIG. 5 , nor does it mean that the electronic device can only include the components shown in FIG. 5 .

本申请实施例提供的电子设备,可通过确定网络请求过程使用的方法的类的元类,将元类的方法替换为预设的网络监测方法,这样应用程序在执行网络请求过程可利用预设的网络监测方法对网络请求过程进行网络监测,实现整个网络请求过程的网络监测。由于元类为类的类,包含所有网络请求过程使用的方法对应的所有类,因此该网络监测方式无需遍历网络请求过程使用的方法对应的所有类,有助于提高网络监测效率。In the electronic device provided by the embodiments of the present application, the metaclass of the class of the method used in the network request process can be determined, and the method of the metaclass can be replaced with a preset network monitoring method, so that the application program can use the preset network monitoring method during the network request process. The network monitoring method of the invention performs network monitoring on the network request process, and realizes the network monitoring of the entire network request process. Since the metaclass is a class, it includes all classes corresponding to methods used in all network request processes, so this network monitoring method does not need to traverse all classes corresponding to methods used in network request processes, which helps to improve network monitoring efficiency.

在本申请实施例中,存储器用于存储计算机程序,并可被配置为存储其它各种数据以支持在其所在设备上的操作。其中,处理器可执行存储器中存储的计算机程序,以实现相应控制逻辑。存储器可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。In this embodiment of the present application, the memory is used to store computer programs, and can be configured to store various other data to support operations on the device where it is located. Wherein, the processor can execute the computer program stored in the memory to realize the corresponding control logic. Memory can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, Flash Memory, Magnetic or Optical Disk.

在本申请实施例中,处理器可以为任意可执行上述方法逻辑的硬件处理设备。可选地,处理器可以为中央处理器(Central Processing Unit,CPU)、图形处理器(GraphicsProcessing Unit,GPU)或微控制单元(Microcontroller Unit,MCU);也可以为现场可编程门阵列(Field-Programmable Gate Array,FPGA)、可编程阵列逻辑器件(ProgrammableArray Logic,PAL)、通用阵列逻辑器件(General Array Logic,GAL)、复杂可编程逻辑器件(Complex Programmable Logic Device,CPLD)等可编程器件;或者为先进精简指令集(RISC)处理器(Advanced RISC Machines,ARM)或系统芯片(System on Chip,SOC)等等,但不限于此。In this embodiment of the present application, the processor may be any hardware processing device that can execute the logic of the foregoing method. Optionally, the processor may be a central processing unit (Central Processing Unit, CPU), a graphics processing unit (GraphicsProcessing Unit, GPU) or a microcontroller unit (Microcontroller Unit, MCU); it may also be a field programmable gate array (Field- Programmable Gate Array (FPGA), Programmable Array Logic (PAL), General Array Logic (GAL), Complex Programmable Logic Device (CPLD) and other programmable devices; or It is an Advanced Reduced Instruction Set (RISC) processor (Advanced RISC Machines, ARM) or a System on Chip (System on Chip, SOC), etc., but not limited thereto.

在本申请实施例中,通信组件被配置为便于其所在设备和其他设备之间有线或无线方式的通信。通信组件所在设备可以接入基于通信标准的无线网络,如WiFi,2G或3G,4G,5G或它们的组合。在一个示例性实施例中,通信组件经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件还可基于近场通信(NFC)技术、射频识别(RFID)技术、红外数据协会(IrDA)技术、超宽带(UWB)技术、蓝牙(BT)技术或其他技术来实现。In this embodiment of the present application, the communication component is configured to facilitate wired or wireless communication between the device where it is located and other devices. The device where the communication component is located can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, 4G, 5G or a combination thereof. In one exemplary embodiment, the communication component receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component may also be based on Near Field Communication (NFC) technology, Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology or other technologies.

在本申请实施例中,显示组件可以包括液晶显示器(LCD)和触摸面板(TP)。如果显示组件包括触摸面板,显示组件可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。In the embodiment of the present application, the display assembly may include a liquid crystal display (LCD) and a touch panel (TP). If the display assembly includes a touch panel, the display assembly may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touch, swipe, and gestures on the touch panel. The touch sensor may not only sense the boundaries of a touch or swipe action, but also detect the duration and pressure associated with the touch or swipe action.

在本申请实施例中,电源组件被配置为其所在设备的各种组件提供电力。电源组件可以包括电源管理系统,一个或多个电源,及其他与为电源组件所在设备生成、管理和分配电力相关联的组件。In the embodiment of the present application, the power supply component is configured to provide power to various components of the device in which it is located. A power supply assembly may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the equipment in which the power supply assembly is located.

在本申请实施例中,音频组件可被配置为输出和/或输入音频信号。例如,音频组件包括一个麦克风(MIC),当音频组件所在设备处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器或经由通信组件发送。在一些实施例中,音频组件还包括一个扬声器,用于输出音频信号。例如,对于具有语言交互功能的设备,可通过音频组件实现与用户的语音交互等。In the embodiments of the present application, the audio component may be configured to output and/or input audio signals. For example, the audio component includes a microphone (MIC) that is configured to receive external audio signals when the device in which the audio component is located is in operating modes, such as call mode, recording mode, and voice recognition mode. The received audio signal may be further stored in memory or transmitted via the communication component. In some embodiments, the audio assembly further includes a speaker for outputting audio signals. For example, for a device with a language interaction function, voice interaction with the user can be implemented through an audio component.

需要说明的是,本文中的“第一”、“第二”等描述,是用于区分不同的消息、设备、模块等,不代表先后顺序,也不限定“第一”和“第二”是不同的类型。It should be noted that the descriptions such as "first" and "second" in this document are used to distinguish different messages, devices, modules, etc., and do not represent a sequence, nor do they limit "first" and "second" are different types.

本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。As will be appreciated by those skilled in the art, the embodiments of the present application may be provided as a method, a system, or a computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.

本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the present application. It will be understood that each process and/or block in the flowchart illustrations and/or block diagrams, and combinations of processes and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to the processor of a general purpose computer, special purpose computer, embedded processor or other programmable data processing device to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing device produce Means for implementing the functions specified in a flow or flow of a flowchart and/or a block or blocks of a block diagram.

这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions The apparatus implements the functions specified in the flow or flow of the flowcharts and/or the block or blocks of the block diagrams.

这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded on a computer or other programmable data processing device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process such that The instructions provide steps for implementing the functions specified in the flow or blocks of the flowcharts and/or the block or blocks of the block diagrams.

在一个典型的配置中,计算设备包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.

内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。Memory may include non-persistent memory in computer readable media, random access memory (RAM) and/or non-volatile memory in the form of, for example, read only memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.

计算机的存储介质为可读存储介质,也可称为可读介质。可读存储介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(transitory media),如调制的数据信号和载波。A storage medium of a computer is a readable storage medium, which may also be referred to as a readable medium. Readable storage media includes both persistent and non-permanent, removable and non-removable media, and storage of information may be implemented by any method or technology. Information may be computer readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), Flash Memory or other memory technology, Compact Disc Read Only Memory (CD-ROM), Digital Versatile Disc (DVD) or other optical storage, Magnetic tape cartridges, magnetic disk storage or other magnetic storage devices or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media, such as modulated data signals and carrier waves.

还需要说明的是,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、商品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、商品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、商品或者设备中还存在另外的相同要素。It should also be noted that the terms "comprising", "comprising" or any other variation thereof are intended to encompass a non-exclusive inclusion such that a process, method, article or device comprising a series of elements includes not only those elements, but also Other elements not expressly listed, or which are inherent to such a process, method, article of manufacture, or apparatus are also included. Without further limitation, an element qualified by the phrase "comprising a..." does not preclude the presence of additional identical elements in the process, method, article of manufacture or device that includes the element.

以上所述仅为本申请的实施例而已,并不用于限制本申请。对于本领域技术人员来说,本申请可以有各种更改和变化。凡在本申请的精神和原理之内所作的任何修改、等同替换、改进等,均应包含在本申请的权利要求范围之内。The above descriptions are merely examples of the present application, and are not intended to limit the present application. Various modifications and variations of this application are possible for those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of this application shall be included within the scope of the claims of this application.

Claims (10)

CN202111630379.0A2021-12-282021-12-28 Network monitoring method, device, device, storage medium and computer program productPendingCN114490244A (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN202111630379.0ACN114490244A (en)2021-12-282021-12-28 Network monitoring method, device, device, storage medium and computer program product

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN202111630379.0ACN114490244A (en)2021-12-282021-12-28 Network monitoring method, device, device, storage medium and computer program product

Publications (1)

Publication NumberPublication Date
CN114490244Atrue CN114490244A (en)2022-05-13

Family

ID=81496494

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN202111630379.0APendingCN114490244A (en)2021-12-282021-12-28 Network monitoring method, device, device, storage medium and computer program product

Country Status (1)

CountryLink
CN (1)CN114490244A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN107291598A (en)*2017-08-072017-10-24腾讯科技(深圳)有限公司Monitoring method, supervising device, monitoring device and storage medium
CN108229152A (en)*2016-12-212018-06-29武汉安天信息技术有限责任公司Method and system based on ios platform dynamic monitoring
CN108809763A (en)*2018-06-142018-11-13武汉斗鱼网络科技有限公司A kind of network performance parameter acquisition method, terminal installation and storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN108229152A (en)*2016-12-212018-06-29武汉安天信息技术有限责任公司Method and system based on ios platform dynamic monitoring
CN107291598A (en)*2017-08-072017-10-24腾讯科技(深圳)有限公司Monitoring method, supervising device, monitoring device and storage medium
CN108809763A (en)*2018-06-142018-11-13武汉斗鱼网络科技有限公司A kind of network performance parameter acquisition method, terminal installation and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
YANGHUHU: ""Objective-C对象模型及应用"", pages 1 - 11, Retrieved from the Internet <URL:https://www.cnblogs.com/yanghuhu/p/3375585.html>*

Similar Documents

PublicationPublication DateTitle
US9092332B2 (en)Activity based sampling of diagnostics data
CN109669723B (en)Hardware access method, apparatus, device and machine readable medium
US10019298B2 (en)Middleware interface and middleware interface generator
US9529691B2 (en)Monitoring and correlating a binary process in a distributed business transaction
CN114385164A (en)Page generation and rendering method and device, electronic equipment and storage medium
WO2017049893A1 (en)Application program testing method, testing apparatus, and mobile terminal
CN111782525A (en) Java method remote debugging method and device
CN111459494A (en)Code processing method and device
CN114996134A (en)Containerized deployment method, electronic equipment and storage medium
CN114840214A (en) Program compilation and startup method, device and storage medium
CN113077340A (en)Performance monitoring method and device for financial transaction
CN111966508A (en) Method, device, computer equipment and storage medium for batch sending of messages
CN114327404B (en) A file processing method, device, electronic device and computer readable medium
CN115174659A (en)Vehicle-mounted service container, service calling method, device and medium
CN114490244A (en) Network monitoring method, device, device, storage medium and computer program product
CN111382057B (en)Test case generation method, test method and device, server and storage medium
CN117234464A (en)Multi-platform charging component service management method and device, electronic equipment and medium
CN117149476A (en) Fault reporting methods and related devices
CN114675786A (en)Large-capacity storage mounting method, device, terminal and medium
CN111382056B (en)Service testing method and device, server and storage medium
CN114528200A (en)Method and device for dynamically modifying instruction, electronic equipment and storage medium
CN116701320B (en) A log generation method and related device
US11381662B2 (en)Transition of business-object based application architecture via dynamic feature check
US20250251999A1 (en)Database connection management for integration flows in a cloud environment
CN117762658B (en) Inter-process data transmission method, device, electronic device and storage medium

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination

[8]ページ先頭

©2009-2025 Movatter.jp