CN115185665A - Link data acquisition method and device, electronic equipment and storage medium - Google Patents

Link data acquisition method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN115185665A
CN115185665A CN202210926545.XA CN202210926545A CN115185665A CN 115185665 A CN115185665 A CN 115185665A CN 202210926545 A CN202210926545 A CN 202210926545A CN 115185665 A CN115185665 A CN 115185665A
Authority
CN
China
Prior art keywords
data
service
node
link
link data
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
CN202210926545.XA
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.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet 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 Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202210926545.XA priority Critical patent/CN115185665A/en
Publication of CN115185665A publication Critical patent/CN115185665A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • G06Q30/0601Electronic shopping [e-shopping]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/544Remote

Abstract

The disclosure relates to a link data acquisition method, a link data acquisition device, an electronic device and a storage medium, which are applied to resource replacement activities in a live broadcast scene, wherein the link data acquisition method comprises the following steps: aiming at least one calling node related to service data, acquiring node data corresponding to each calling node; and combining the acquired node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data, wherein the link data comprises at least one node data related to at least one type of service. According to the link data acquisition method and device, the electronic equipment and the storage medium, the carding efficiency, the accuracy and the comprehensiveness of the calling link can be greatly improved.

Description

Link data acquisition method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a link data obtaining method and apparatus, an electronic device, and a storage medium.
Background
The rapid development of the internet technology provides a development basis for the live broadcast e-commerce industry, the live broadcast e-commerce relates to a plurality of services, the calling links related to each service are various, the dependency relationship among the links is complex, and in order to guarantee the stability of the services, the complete calling links of each service need to be organized and clearly presented.
At present, the sorting work of the call links of each service is mainly carried out by manually combing service codes, the efficiency is low, and part of the call links are easy to miss.
Disclosure of Invention
The present disclosure provides a data processing method, an apparatus, an electronic device, and a storage medium to at least solve the above-mentioned problems in the related art.
According to a first aspect of the embodiments of the present disclosure, there is provided a link data acquisition method, including: aiming at least one calling node related to service data, acquiring node data corresponding to each calling node; and combining the acquired node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data, wherein the link data comprises at least one node data related to at least one type of service.
Optionally, before the obtaining node data corresponding to each of the calling nodes, the link data obtaining method further includes: and acquiring a link identifier corresponding to the service data, wherein the link identifier is used for identifying a link corresponding to the service data.
Optionally, the mounting an AOP listener in the at least one type of service, and acquiring, for at least one calling node to which business data relates, node data corresponding to each calling node, includes: and aiming at least one calling node related to the service data, acquiring node data corresponding to the calling node related to each type of service through the AOP monitor.
Optionally, the combining the obtained node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data includes: and for each calling node, setting the acquired node data to a link context corresponding to the service data according to the context node sequence when acquiring a group of node data, so as to obtain the link data corresponding to the service data.
Optionally, after obtaining the link data corresponding to the service data, the link data obtaining method further includes: and storing the obtained link data, and labeling the auxiliary information of the stored link data.
According to a second aspect of the embodiments of the present disclosure, there is provided a link data acquisition apparatus including: a node data acquisition unit configured to: aiming at least one calling node related to service data, acquiring node data corresponding to each calling node; a link data acquisition unit configured to: and combining the acquired node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data, wherein the link data comprises at least one node data related to at least one type of service.
Optionally, the link data obtaining unit further includes a link identifier obtaining unit, where the link identifier obtaining unit may be configured to obtain a link identifier corresponding to the service data before obtaining the node data corresponding to each of the calling nodes, where the link identifier is used to identify a link corresponding to the service data.
Optionally, an AOP listener is piggybacked in the at least one type of service, and the node data obtaining unit may be configured to obtain, for at least one calling node to which the service data relates, node data corresponding to the calling node to which each type of service relates, through the AOP listener.
Optionally, the link data obtaining unit may be configured to, for each call node, set the obtained node data to a link context corresponding to the service data according to a context node sequence every time a group of node data is obtained, so as to obtain the link data corresponding to the service data.
Optionally, the link data obtaining unit further includes a data saving and labeling unit, where the data saving and labeling unit may be configured to, after obtaining the link data corresponding to the service data, save the obtained link data, and label the saved link data with the auxiliary information.
According to a third aspect of an embodiment of the present disclosure, there is provided an electronic apparatus including: at least one processor; at least one memory storing computer-executable instructions, wherein the computer-executable instructions, when executed by the at least one processor, cause the at least one processor to perform a link data acquisition method according to the present disclosure.
According to a fourth aspect of embodiments of the present disclosure, there is provided a computer-readable storage medium storing instructions that, when executed by at least one processor, cause the at least one processor to perform a link data acquisition method according to the present disclosure.
According to a fifth aspect of embodiments of the present disclosure, there is provided a computer program product, instructions in which are executable by a processor of a computer device to perform a link data acquisition method according to the present disclosure.
The technical scheme provided by the embodiment of the disclosure at least brings the following beneficial effects:
according to the link data acquisition method, the link data acquisition device, the electronic equipment and the storage medium, node data corresponding to at least one calling node under a plurality of types of services related to the business data are acquired, the acquired node data are combined according to a preset sequence, link data corresponding to the business data can be acquired, and the carding efficiency, accuracy and comprehensiveness of the calling link can be greatly improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure and are not to be construed as limiting the disclosure.
Fig. 1 is a call diagram illustrating an RPC framework according to an exemplary embodiment of the present disclosure.
Fig. 2 is an overall schematic diagram illustrating a link data acquisition framework according to an exemplary embodiment of the present disclosure.
Fig. 3 is a flowchart illustrating a link data acquisition method according to an exemplary embodiment of the present disclosure.
Fig. 4 (a) is a schematic diagram of an interceptor in a GRPC service according to an exemplary embodiment of the present disclosure.
Fig. 4 (b) is a schematic diagram of an interceptor in a Spring Bean service according to an exemplary embodiment of the present disclosure.
Fig. 4 (c) is a schematic diagram of an interceptor in an internal JAVA customization service according to an exemplary embodiment of the present disclosure.
Fig. 5 is a block diagram illustrating a link data acquisition apparatus according to an exemplary embodiment of the present disclosure.
Fig. 6 is a block diagram illustrating an electronic device 600 according to an example embodiment of the present disclosure.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in sequences other than those illustrated or otherwise described herein. The embodiments described in the following examples do not represent all embodiments consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
In this case, the expression "at least one of the items" in the present disclosure means a case where three types of parallel expressions "any one of the items", "a combination of any plural ones of the items", and "the entirety of the items" are included. For example, "include at least one of a and B" includes the following three cases in parallel: (1) comprises A; (2) comprises B; and (3) comprises A and B. For another example, "at least one of step one and step two is performed", which means the following three parallel cases: (1) executing the step one; (2) executing the step two; and (3) executing the step one and the step two.
For example, for a service of placing an order, when a client side responds to a request of a user for purchasing a currently live item, the corresponding server side verifies and starts to execute a specific service logic after receiving the request, and finally sends a processing result to the client side. Here, the interaction between the client and the server may be implemented by using an RPC (Remote Procedure Call Protocol), and the RPC frame may shield a Transmission mode (TCP (Transmission Control Protocol) or UDP (User Datagram Protocol)) of a bottom layer, a serialization mode (XML (eXtensible Markup Language)/Json (JavaScript Object Notation)/binary) and communication details, so that a service caller may Call a Remote service provider as a local interface, without considering underlying communication details and calling procedures, thereby making the Call of the Remote service simpler and more transparent.
Fig. 1 is a call diagram illustrating an RPC framework according to an exemplary embodiment of the present disclosure.
Referring to fig. 1, in a process of calling a remote service, a micro service consumer generates an RPC Client Stub (Client Stub) by using a micro service dynamic proxy technology, the RPC Client Stub (Client Stub) serializes a request message after receiving a call request, finds a remote service address, sends the serialized message to a Server through a network, performs deserialization operation after receiving the message to obtain a deserialized message, calls a local service (micro service provider) to perform related processing according to the deserialized message, the local service (micro service provider) executes specific service logic and returns a processing result to the Server Stub, the Server Stub repackages the returned result into a message (serialization) and sends the message to the consumer through the network, and the Client Stub performs deserialization after receiving the message, so that the micro service consumer obtains a response result.
For a service, in the process of executing specific service logic by a micro service provider, a plurality of different types of services may be involved, for example, GRPC service, spring Bean service and internal JAVA custom service, each type of service involving at least one calling node. In the process of executing specific service logic by the micro-service provider, the node data related to each type of service is acquired through a data acquisition tool, and the node data are combined according to the sequence of the service logic to obtain the link data corresponding to the service. Based on this idea, fig. 2 shows an overall schematic diagram of a link data acquisition framework according to an exemplary embodiment of the present disclosure.
Referring to fig. 2, based on a bottom-layer open source framework JVM-SANDBOX, a GRPC cut plane module, a Spring object (Spring Bean) cut plane module, and an internal JAVA Custom (Custom JAVA) cut plane module are respectively developed, and node data corresponding to each calling node under GRPC service, spring Bean service, and internal JAVA Custom service involved in the execution process of a service can be respectively collected through the GRPC cut plane module, the Spring object cut plane module, and the internal JAVA Custom cut plane module. Specifically, the bottom open source framework JVM-SANDBOX (JVM SANDBOX container) is a flexible, non-intrusive code AOP (Aspect Oriented Programming) framework implemented by using instrumentation instead of proxy based on JVM (JAVA virtual machine tool interface) technical specification, using dynamic bytecode enhancement technology, and is programmed in a certain step or phase of the business process, which is called a "section" and aims to reduce coupling between parts of business logic. After a group of node data of a service is collected through a section module, the collected node data can be assembled and managed through a context management module, a trace management module and a model management module, when the service execution is completed, link data corresponding to the service is automatically generated, and finally, the generated link data can be output to a server side for storage through HTTP (Hypertext Transfer Protocol), GRPC (GRPC) or MetaQ (distributed message middleware of a queue model).
According to the link data acquisition framework, calling links corresponding to various services in the live broadcast process can be automatically combed, and the efficiency, accuracy and comprehensiveness of the calling link combing are improved; moreover, when the link is changed due to the change of the demand (for example, a single coupon is temporarily provided for a certain sold article), the manual maintenance is not needed, and the manual input in the link carding work can be reduced.
Fig. 3 is a flowchart illustrating a link data acquisition method according to an exemplary embodiment of the present disclosure. The link data acquisition method can be used for combing the links corresponding to various services in a live scene.
Referring to fig. 3, in step 301, node data corresponding to each calling node may be obtained for at least one calling node involved in service data.
In step 302, the obtained node data corresponding to each calling node may be combined according to a preset sequence to obtain link data corresponding to the service data, where the link data includes at least one node data related to at least one type of service.
Here, the service data refers to all data generated by executing a certain service, and at least one type of service includes at least one of a GRPC service, a Spring Bean service, and an internal JAVA custom service, and includes at least one calling node under each type of service. For example, for a ordering service in a live broadcasting process, the service execution flow may include: GRPC (Google Remote Procedure Calls, HTTP/2 protocol transport-based) service queries commodity information- > GRPC service queries buyer account information- > GRPC service queries seller account information- > GRPC service queries store information- > GRPC service computes commodity benefits- > GRPC service queries address information- > GRPC service computes freight-Spring Bean service computes order price- > GRPC service deducts inventory information- > Spring Bean service saves orders. In addition, for each service, the start service starts from the GRPC service and ends with the GRPC service, and the Spring Bean service or the internal JAVA custom service exists as an intermediate service in the whole service flow.
According to the exemplary embodiment of the disclosure, before the node data corresponding to each calling node is acquired, a link identifier corresponding to the service data may be acquired, where the link identifier is used to identify a link corresponding to the service data. In the process of acquiring the node data corresponding to each calling node, for each calling node, each group of node data is acquired, and the acquired node data can be set to the link context corresponding to the service data according to the context node sequence to obtain the link data corresponding to the service. Here, the context node order may be a number index in a predefined context data structure, which indicates that each group of node data is numbered in order starting from 0, and the number of each group of node data is increased by 1 each time one group of node data is acquired.
According to the exemplary embodiment of the disclosure, an AOP listener is mounted in at least one type of service, and node data corresponding to a calling node involved in each type of service can be acquired through the AOP listener for at least one calling node involved in traffic data.
In one embodiment, the loading of AOP listeners into each type of service may be achieved by making a cut-plane to the interceptors of each type of service separately. Specifically, the interceptor includes a client interceptor ClientInterceptor and a server interceptor, and is configured to perform message interception before the service request is executed, to implement verification authorization, record a call behavior in a service execution flow, insert other logic, and the like. The location of the interceptor in each type of service can refer to fig. 4, where fig. 4 (a) is a schematic diagram of the interceptor in the GRPC service according to an exemplary embodiment of the present disclosure, fig. 4 (b) is a schematic diagram of the interceptor in the Spring Bean service according to an exemplary embodiment of the present disclosure, and fig. 4 (c) is a schematic diagram of the interceptor in the internal JAVA custom service according to an exemplary embodiment of the present disclosure. Referring to fig. 4 (a), (b) and (c), a client interceptor clientinterpolator and a server interceptor serverinterpolator are provided in each type of service, and it should be further understood that the execution of a service always starts with a GRPC service and ends with the GRPC service, and the Spring Bean service and the internal JAVA custom service are only intermediate nodes of the execution flow, so that the start node and the end node are both GRPC services in fig. 4 (b) and fig. 4 (c).
According to an exemplary embodiment of the present disclosure, the AOP listener is an enhanced code based on JVM-SANDBOX and used for link data acquisition, and specifically, for a GRPC service, the enhanced code includes enhanced codes of a client and a server, for the GRPC client, a JVM-SANDBOX listener may be created to listen to a newCall method of GRPC interception class io, GRPC, internal. Aiming at a GRPC server, firstly creating a JVM-SANDBOX monitor to monitor an onHalfClose method of an interception class io, GRPC, stub, serverCalls, unnaryServerCallHandler, unnaryServerCallLister of the GRPC, and as the GRPC server is equipment which firstly receives a service invocation request of a client and performs service processing, firstly obtaining a unique identifier traceId of a link corresponding to the service invocation request before a GRPC interceptor of the server performs method interception, then obtaining a service name and a method name of an interception class by using a JAVA reflection technology, and setting the obtained service name and method name on the link according to a context node sequence. Here, since a service always ends with the GRPC service, after the service processing ends, all contexts of a link corresponding to a service can be obtained at the GRPC service end, all method signatures of the invoked service can be taken out from all the contexts obtained at the GRPC service end, and deduplication processing is performed through the Md5 signature, for example, for the service of placing a bill, there may be a case where a user in the same area purchases the same article in the same live broadcast room to generate a duplicate link, and at this time, the duplicate link can be removed through the Md5 signature, so as to obtain a complete link data corresponding to a service.
For the Spring Bean service, the logic of its enhanced code, for example, but not limited to, may be: the method comprises the steps of firstly creating a JVM-SANDBOX monitor, monitoring a getBean method of an interception class of Spring beans, namely Spring frame work, bean, factor, support, defaultListableBeanFactory, acquiring a Spring factory class by using a JAVA reflection technology before the interceptor of the Spring beans performs method interception, acquiring all registered Spring Bean classes by using the Spring factory class, setting the Spring Bean classes into Spring Bean factor variables, then creating a JVM-SANDBOX monitor for each Spring Bean in the Spring Bean factor variables, monitoring classes and methods related to the Spring beans, and setting the acquired class name and method name into a link context.
For internal JAVA custom services, the logic that enhances the code, for example, but not limited to, may be: firstly, acquiring a class and a method to be monitored according to user defined configuration, creating a JVM-SANDBOX monitor, monitoring the class and the method specified by the user configuration, acquiring a service name and a method name of an interception class by using a JAVA reflection technology before the method interception is carried out by an interceptor of an internal JAVA defined service, and setting the acquired service name and method name into a link context.
In another embodiment, the AOP listener can also be implemented based on using Spring AOP, which is not limited by this disclosure.
According to the exemplary embodiment of the disclosure, after the link data corresponding to the service data is obtained, the obtained link data may be saved, and the saved auxiliary information may be labeled.
Here, the obtained link data may be transmitted to the server side via HTTP, GRPC, or MetaQ for storage, or may be transmitted to the server side for other processing. Here, the link data structure sent to the server is predefined, and the defined link data structure may include, for example and without limitation, a node order index, a service type serviceType (e.g., GRPC service, etc.), a service name serviceName, a method name, and a link identification serviceLinkId in the link data, where serviceLinkId is used to identify the uniqueness of the link, and the index identifies the node order in the link. In addition, ip, a timestamp and a serial number can be added into the serviceLinkId generation algorithm, so that the uniqueness of the link identification is ensured.
In addition, auxiliary information labeling may be performed on the link data stored in the server to provide service guidance for stabilization of each service in a live broadcast scenario, where the labeled auxiliary information may include at least one of a service name corresponding to the link data (e.g., a query recharging record, a query electronic voucher list, and the like), a fault level corresponding to the link data, and a degree of correlation between node data of the link data. Specifically, each group of node data in each group of link data can be labeled with a fault level for indicating the probability of the node corresponding to the group of node data failing, the correlation degree between the node data of the link data refers to the influence degree of the node corresponding to a certain group of node data on other nodes in the link, and the node which is easy to fail and the node which has important influence on the link can be timely concerned by labeling the link data with auxiliary information, so that the stability of live broadcast is guaranteed.
Fig. 5 is a block diagram illustrating a link data acquisition apparatus according to an exemplary embodiment of the present disclosure.
Referring to fig. 5, a link data acquisition apparatus 500 according to an exemplary embodiment of the present disclosure may include a node data acquisition unit 501 and a link data acquisition unit 502. The link data acquiring apparatus 500 may be used to comb links corresponding to various services in a live scene.
The node data obtaining unit 501 may obtain, for at least one calling node related to the service data, node data corresponding to each calling node.
The link data obtaining unit 502 may combine the obtained node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data, where the link data includes at least one node data related to at least one type of service.
Here, the service data refers to all data generated by executing a certain service, and at least one type of service includes at least one of a GRPC service, a Spring Bean service, and an internal JAVA custom service, and includes at least one calling node under each type of service. For example, for a ordering service in a live broadcasting process, the service execution flow may include: GRPC (Google Remote Procedure Calls, HTTP/2 protocol transport-based) service queries commodity information- > GRPC service queries buyer account information- > GRPC service queries seller account information- > GRPC service queries store information- > GRPC service computes commodity benefits- > GRPC service queries address information- > GRPC service computes freight-Spring Bean service computes order price- > GRPC service deducts inventory information- > Spring Bean service saves orders. In addition, for each service, the start service starts from the GRPC service and ends with the GRPC service, and the Spring Bean service or the internal JAVA custom service exists as an intermediate service in the whole service flow.
According to an exemplary embodiment of the disclosure, the link data obtaining apparatus 500 further includes a link identifier obtaining unit 503 (not shown in fig. 5), and the link identifier obtaining unit 503 may obtain a link identifier corresponding to the service data before obtaining the node data corresponding to each calling node, where the link identifier is used to identify a link corresponding to the service data. The link data obtaining unit 502 may set, for each calling node, each group of node data obtained in the process of obtaining the node data corresponding to each calling node, to the link context corresponding to the service data according to the context node sequence, so as to obtain the link data corresponding to the service. Here, the context node order may be a number index in a predefined context data structure, which indicates that each group of node data is numbered in order starting from 0, and the number of each group of node data is increased by 1 each time one group of node data is acquired.
According to an exemplary embodiment of the present disclosure, an AOP listener is hung in at least one type of service, and the node data obtaining unit 501 may obtain, for at least one calling node to which business data relates, node data corresponding to the calling node to which each type of service relates, through the AOP listener.
In one embodiment, the loading of AOP listeners into each type of service may be accomplished by making a cut through to the interceptors for each type of service. Specifically, the interceptor includes a client interceptor ClientInterceptor and a server interceptor, and is configured to perform message interception before the service request is executed, to implement verification authorization, record a call behavior in a service execution flow, insert other logic, and the like. The positions of the interceptors in the various types of services can be referred to the above description of fig. 4, and are not described herein again.
According to an exemplary embodiment of the present disclosure, the AOP listener is an enhanced code based on JVM-SANDBOX and used for link data acquisition, and specifically, for a GRPC service, a Spring Bean service and an internal JAVA custom service involved in the execution process of a service, the enhanced code based on JVM-SANDBOX and used for link data acquisition may be set separately, wherein the enhanced code set for each type of service may refer to the description of the foregoing relevant parts, and will not be described herein again.
According to an exemplary embodiment of the disclosure, the link data obtaining unit 500 further includes a data saving and labeling unit 504 (not shown in fig. 5), and the data saving and labeling unit 504 may save the obtained link data and label the saved link data with the auxiliary information after obtaining the link data corresponding to the service data.
Here, the data saving and labeling unit 504 may transmit at least one set of obtained link data to the server for saving through HTTP, GRPC, or MetaQ, or to the server for other processing. Here, the link data structure sent to the server is predefined, and the defined link data structure may include, for example and without limitation, a node order index, a service type serviceType (e.g., GRPC service, etc.), a service name serviceName, a method name, and a link identification serviceLinkId in the link data, where serviceLinkId is used to identify the uniqueness of the link, and the index identifies the node order in the link. In addition, ip, a timestamp and a serial number can be added into the serviceLinkId generation algorithm, so that the uniqueness of the link identification is ensured.
In addition, the data saving and labeling unit 504 may label auxiliary information of the link data saved in the server to provide service guidance for stability of each service in the live broadcast scenario, where the labeled auxiliary information may include at least one of a service name corresponding to the link data (e.g., query recharging record, query electronic voucher list, etc.), a fault level corresponding to the link data, and a degree of correlation between node data of the link data. Specifically, each group of node data in each group of link data can be labeled with a fault level for indicating the probability of the node corresponding to the group of node data failing, the correlation degree between the node data of the link data refers to the influence degree of the node corresponding to a certain group of node data on other nodes in the link, and the node which is easy to fail and the node which has important influence on the link can be timely concerned by labeling the link data with auxiliary information, so that the stability of live broadcast is guaranteed.
Fig. 6 is a block diagram of an electronic device 600 according to an example embodiment of the present disclosure.
Referring to fig. 6, the electronic device 600 includes at least one memory 601 and at least one processor 602, the at least one memory 601 having stored therein a set of computer-executable instructions that, when executed by the at least one processor 602, perform a link data acquisition method according to an exemplary embodiment of the present disclosure.
By way of example, the electronic device 600 may be a PC computer, tablet device, personal digital assistant, smartphone, or other device capable of executing the set of instructions described above. Here, the electronic device 600 need not be a single electronic device, but can be any arrangement or collection of circuits capable of executing the above-described instructions (or sets of instructions), either individually or in combination. The electronic device 600 may also be part of an integrated control system or system manager, or may be configured as a portable electronic device that interfaces with local or remote (e.g., via wireless transmission).
In the electronic device 600, the processor 602 may include a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), a programmable logic device, a special purpose processor system, a microcontroller, or a microprocessor. By way of example, and not limitation, processors may also include analog processors, digital processors, microprocessors, multi-core processors, processor arrays, network processors, and the like.
The processor 602 may execute instructions or code stored in the memory 601, wherein the memory 601 may also store data. The instructions and data may also be transmitted or received over a network via a network interface device, which may employ any known transmission protocol.
The memory 601 may be integrated with the processor 602, for example, with RAM or flash memory disposed within an integrated circuit microprocessor or the like. Further, memory 601 may comprise a stand-alone device, such as an external disk drive, storage array, or any other storage device usable by a database system. The memory 601 and the processor 602 may be operatively coupled or may communicate with each other, e.g., through I/O ports, network connections, etc., such that the processor 602 can read files stored in the memory.
Further, the electronic device 600 may also include a video display (such as a liquid crystal display) and a user interaction interface (such as a keyboard, mouse, touch input device, etc.). All components of the electronic device 600 may be connected to each other via a bus and/or a network.
According to an exemplary embodiment of the present disclosure, there may also be provided a computer-readable storage medium storing instructions, which when executed by at least one processor, cause the at least one processor to perform a link data acquisition method according to the present disclosure. Examples of the computer-readable storage medium herein include: read-only memory (ROM), random-access programmable read-only memory (PROM), electrically erasable programmable read-only memory (EEPROM), random-access memory (RAM), dynamic random-access memory (DRAM), static random-access memory (SRAM), flash memory, non-volatile memory, CD-ROM, CD-R, CD + R, CD-RW, CD + RW, DVD-ROM, DVD-R, DVD + R, DVD-RW, DVD + RW, DVD-RAM, BD-ROM, BD-R, BD-RLTH, BD-RE, blu-ray or optical disk memory, hard Disk Drives (HDDs), solid-state hard disks (SSDs), card type memory (such as a multimedia card, a Secure Digital (SD) card or an extreme digital (XD) card), magnetic tape, a floppy disk, a magneto-optical data storage device, an optical data storage device, a hard disk, a solid-state disk, and any other device configured to store and provide a computer program and any associated data, data file and data processing structure to enable execution of the computer program or data processing device. The computer program in the computer-readable storage medium described above can be run in an environment deployed in a computer apparatus, such as a client, a host, a proxy device, a server, and the like, and further, in one example, the computer program and any associated data, data files, and data structures are distributed across a networked computer system such that the computer program and any associated data, data files, and data structures are stored, accessed, and executed in a distributed fashion by one or more processors or computers.
According to an exemplary embodiment of the present disclosure, there may also be provided a computer program product, instructions in which are executable by a processor of a computer device to perform a link data acquisition method according to an exemplary embodiment of the present disclosure.
According to the link data acquisition method, the link data acquisition device, the electronic equipment and the storage medium, node data corresponding to at least one calling node under a plurality of types of services related to business data are acquired, the acquired node data are combined according to a preset sequence, link data corresponding to the business data can be acquired, and the carding efficiency, accuracy and comprehensiveness of the calling link can be greatly improved.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A link data acquisition method, comprising:
aiming at least one calling node related to service data, acquiring node data corresponding to each calling node;
and combining the acquired node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data, wherein the link data comprises at least one node data related to at least one type of service.
2. The link data obtaining method according to claim 1, wherein before obtaining the node data corresponding to each of the calling nodes, the link data obtaining method further includes:
and acquiring a link identifier corresponding to the service data, wherein the link identifier is used for identifying a link corresponding to the service data.
3. The link data acquiring method according to claim 1, wherein an AOP listener is mounted in the at least one type of service, and the acquiring, for at least one calling node to which service data relates, node data corresponding to each of the calling nodes includes:
and aiming at least one calling node related to the service data, acquiring node data corresponding to the calling node related to each type of service through the AOP monitor.
4. The method for acquiring link data according to claim 1, wherein the step of combining the acquired node data corresponding to each calling node according to a preset sequence to obtain the link data corresponding to the service data includes:
and for each calling node, setting the acquired node data to a link context corresponding to the service data according to the context node sequence when acquiring a group of node data, so as to obtain the link data corresponding to the service data.
5. The link data obtaining method according to claim 1, wherein after obtaining the link data corresponding to the service data, the link data obtaining method further includes:
and storing the obtained link data, and labeling auxiliary information of the stored link data.
6. A link data acquisition apparatus, comprising:
a node data acquisition unit configured to: aiming at least one calling node related to service data, acquiring node data corresponding to each calling node;
a link data acquisition unit configured to: and combining the acquired node data corresponding to each calling node according to a preset sequence to obtain link data corresponding to the service data, wherein the link data comprises at least one node data related to at least one type of service.
7. The link data acquisition apparatus according to claim 6, further comprising a link identification acquisition unit configured to:
and acquiring a link identifier corresponding to the service data before acquiring the node data corresponding to each calling node, wherein the link identifier is used for identifying a link corresponding to the service data.
8. An electronic device, comprising:
at least one processor;
at least one memory storing computer-executable instructions,
wherein the computer-executable instructions, when executed by the at least one processor, cause the at least one processor to perform the link data acquisition method of any one of claims 1 to 5.
9. A computer-readable storage medium storing instructions that, when executed by at least one processor, cause the at least one processor to perform the link data acquisition method of any one of claims 1 to 5.
10. A computer program product comprising computer instructions, characterized in that the computer instructions, when executed by at least one processor, implement the link data acquisition method according to any one of claims 1 to 5.
CN202210926545.XA 2022-08-03 2022-08-03 Link data acquisition method and device, electronic equipment and storage medium Pending CN115185665A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210926545.XA CN115185665A (en) 2022-08-03 2022-08-03 Link data acquisition method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210926545.XA CN115185665A (en) 2022-08-03 2022-08-03 Link data acquisition method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115185665A true CN115185665A (en) 2022-10-14

Family

ID=83522254

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210926545.XA Pending CN115185665A (en) 2022-08-03 2022-08-03 Link data acquisition method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115185665A (en)

Similar Documents

Publication Publication Date Title
US10606565B2 (en) Visual devops systems and methods
US8607200B2 (en) Executing a web application at different stages in the application life cycle
US9712410B1 (en) Local metrics in a service provider environment
US10182129B1 (en) Global optimization of a service-oriented system
US7996820B2 (en) Determining proportionate use of system resources by applications executing in a shared hosting environment
AU2021203955B2 (en) Dynamic component performance monitoring
JP2019179575A (en) Dynamic graph performance monitoring
US10078579B1 (en) Metrics-based analysis for testing a service
CA2829915C (en) Method and system for dynamically tagging metrics data
US10091061B1 (en) Service-oriented system optimization using static analysis
CN113495797B (en) Message queue and consumer dynamic creation method and system
US10951540B1 (en) Capture and execution of provider network tasks
US11526501B2 (en) Materialized views assistant
US20210342309A1 (en) Methods, systems, and computer readable mediums for performing metadata-driven data collection
CN112187509A (en) Multi-architecture cloud platform execution log management method, system, terminal and storage medium
US9998330B1 (en) Service-oriented system optimization using edge relocation
CN115185665A (en) Link data acquisition method and device, electronic equipment and storage medium
US9037815B2 (en) Analyzing and reducing dump data
JP2015045901A (en) Business processing system, method for generating process pertaining business, and program
CN114372059A (en) Resource data acquisition method and device, electronic equipment and storage medium
CN115729784A (en) Middle platform service model monitoring system
US9998328B1 (en) Service-oriented system optimization using client device relocation
CN115268931A (en) Data acquisition system, method, device and medium based on cloud native scene
CN114296778A (en) Message notification method and device
WO2023154679A1 (en) Associating capabilities and alarms

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination