CN116993503A - Method and device for automatically determining transaction flow direction - Google Patents

Method and device for automatically determining transaction flow direction Download PDF

Info

Publication number
CN116993503A
CN116993503A CN202311102424.4A CN202311102424A CN116993503A CN 116993503 A CN116993503 A CN 116993503A CN 202311102424 A CN202311102424 A CN 202311102424A CN 116993503 A CN116993503 A CN 116993503A
Authority
CN
China
Prior art keywords
service
address list
transaction
address
information
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
CN202311102424.4A
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.)
China Construction Bank Corp
CCB Finetech Co Ltd
Original Assignee
China Construction Bank Corp
CCB Finetech 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 China Construction Bank Corp, CCB Finetech Co Ltd filed Critical China Construction Bank Corp
Priority to CN202311102424.4A priority Critical patent/CN116993503A/en
Publication of CN116993503A publication Critical patent/CN116993503A/en
Pending legal-status Critical Current

Links

Classifications

    • 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
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor

Abstract

The present invention relates to the field of financial science and technology, and provides a method and a device for automatically determining a transaction flow direction, wherein the method comprises the following steps: after each response transaction, the service judges whether the service calls other services or not; if not, generating an address list according to the address information of the node of the service response transaction, and sending the address list to a caller of the service; if so, waiting for address lists returned by other services, adding address information of nodes of the service responding to the transaction to the received address list, if a caller exists, sending the added address list to the caller of the service, and if no caller exists, determining the added address list as the transaction address list; comparing the transaction address list with the address list in the database, and if the same address list does not exist, updating the transaction address list into the database. The method and the device can acquire the transaction address list capable of reflecting the service calling relationship in real time, and ensure the validity of information in the database.

Description

Method and device for automatically determining transaction flow direction
Technical Field
The present disclosure relates to the field of financial science and technology, and in particular, to a method and apparatus for automatically determining a transaction flow direction.
Background
In the financial industry, different institutions and business scenarios correspond to a plurality of different transaction codes. Different transaction codes may call out other services. Numerous transaction codes are commonly seen in financial services management platforms, as well as associated outbound services. Specifically, a transaction code can provide multiple services according to different configurations, and when the transaction code is actually applied, some transaction requests are not completed by one transaction code, for example, the request calls a transaction code A, and the transaction code A also calls a transaction code B. Furthermore, each service is typically not a node, and typically a service has multiple nodes, each with different IP addresses and resources.
In the prior art, the complex calling relation of the transaction is realized by adopting a manual maintenance mode, and the mode has the problems of manpower waste, large error, poor real-time performance and incapability of automatically displaying the transaction flow direction.
Disclosure of Invention
The method is used for solving the problems that in the prior art, manual maintenance is adopted, labor is wasted, error is large, instantaneity is poor, and automatic display of transaction flow direction cannot be achieved.
To solve the above technical problem, in one aspect, the present disclosure provides a method for automatically determining a transaction flow direction, which is applied to an agent in each service, and the method includes:
after each response transaction, the service judges whether the service calls other services or not;
if not, generating an address list according to the address information of the node of the service response transaction, and sending the address list to a caller of the service;
if so, waiting for address lists returned by other services, adding address information of nodes of the service responding to the transaction to the received address list, if a caller exists in the service, sending the added address list to the caller of the service, and if the caller does not exist in the service, determining the added address list as the transaction address list;
comparing the transaction address list with the address list in the database, discarding the transaction address list if the same address list exists, and otherwise, updating the transaction address list into the database.
In a further embodiment, when updating the transaction address list to the database, the update time of the transaction address list is also recorded;
the method further comprises the steps of: and sending the transaction address list to a display device for display.
In a further embodiment, the agent is activated when a service is first requested or when a service is changed, and is deactivated after a predetermined amount of response transactions are processed by the service.
In a further embodiment, when generating the address list or modifying the address list, the method further includes: recording time information of adding the address information to the address list;
and carrying out slow call alarming according to the time information of the adjacent address information in the address list.
In a further embodiment, the address information includes: IP address and port information.
In a further embodiment, after determining that the service invokes other services, waiting for a predetermined time interval, and after the predetermined time interval expires, adding address information of a node of the service responding to the transaction to the received address list; or (b)
And judging whether the number of address lists returned by other services is equal to the number of other services called by the service, if so, adding the address information of the node of the service responding to the transaction into the received address list.
In a further embodiment, before updating the transaction address list to the database, further comprises: and numbering the address information according to the sequence from front to back of the address information in the transaction address list, so that the display equipment generates and displays the service calling relation according to the number information.
In a further embodiment, before generating the address list, setting a calling sequence number of the service, and generating the address list according to the address information of the service is further: generating an address list according to the calling sequence number of the service and the address information of the service;
the method further comprises the steps of generating a calling sequence number of the service according to the calling sequence number in the received address list before modifying the address list, and further comprises the steps of: and adding the calling sequence number of the service to the received address list.
In a further embodiment, de-overlapping and processing are performed on a plurality of newly added address lists determined by the service, and the processed address list is used as a final newly added address list;
and in the de-duplication merging process, the address information of the nodes called by the address information of the same node is used as parallel address information.
A second aspect herein provides an apparatus for automatically determining a transaction flow direction for use by an agent in each service, the apparatus comprising:
the judging unit is used for judging whether the service calls other services after responding to the transaction each time;
an address list generating unit, configured to generate an address list according to address information of a node that responds to the transaction by the service if not, and send the address list to a caller of the service;
the address list modifying unit is used for waiting for address lists returned by other services if the address list is yes, after the address information of the node of the service response transaction is newly added to the received address list, if a caller exists in the service, the newly added address list is sent to the caller of the service, and if the caller does not exist in the service, the newly added address list is determined to be the transaction address list;
and the warehousing unit is used for comparing the transaction address list with the address list in the database, discarding the transaction address list if the same address list exists, and otherwise, updating the transaction address list into the database.
A third aspect herein provides a computer apparatus comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the method of any of the preceding embodiments when the computer program is executed.
A fourth aspect herein provides a computer storage medium having stored thereon a computer program which, when executed by a processor of a computer device, implements a method as described in any of the previous embodiments.
A fifth aspect herein provides a computer program product comprising a computer program which, when executed by a processor of a computer device, implements a method as described in any of the preceding embodiments.
The method and the device for automatically determining the transaction flow direction provided by the invention are characterized in that the agent is pre-embedded in each service, and the agent judges whether other services are called after the service where the agent is located responds to the transaction; if not, generating an address list according to the address information of the node of the service response transaction, and sending the address list to a caller of the service; if so, waiting for address lists returned by other services, adding address information of nodes of the service responding to the transaction to the received address list, if a caller exists in the service, sending the added address list to the caller of the service, and if the caller does not exist in the service, determining the added address list as the transaction address list; and comparing the transaction address list with the address list in the database, discarding the transaction address list if the same address list exists, otherwise, updating the transaction address list into the database, so that the transaction address list capable of reflecting the service call relationship can be ensured to be accurately and automatically acquired in real time, the transaction address list in the database is ensured to be effective information, and a basis is provided for real-time display of the subsequent transaction call relationship.
The foregoing and other objects, features and advantages will be apparent from the following more particular description of preferred embodiments, as illustrated in the accompanying drawings.
Drawings
In order to more clearly illustrate the embodiments herein or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described below, it being obvious that the drawings in the following description are only some embodiments herein and that other drawings may be obtained according to these drawings without inventive effort to a person skilled in the art.
FIG. 1 illustrates a block diagram of a system for automatically determining transaction flow according to embodiments herein;
FIG. 2 illustrates a flow chart of a method of automatically determining transaction flow according to embodiments herein;
FIG. 3A illustrates a schematic diagram of a service invocation relationship of embodiments herein;
FIG. 3B illustrates a service invocation relationship diagram of an embodiment herein;
FIG. 4 illustrates another schematic diagram of a service invocation relationship of embodiments herein;
FIG. 5 illustrates a block diagram of an apparatus for automatically determining transaction flow according to embodiments herein;
FIG. 6 illustrates a block diagram of a computer device of embodiments herein.
Description of the drawings:
101. a configuration end;
102. a server;
103. a database;
501. a judging unit;
502. a first address list unit;
503. a second address list unit;
504. a warehouse-in unit;
602. a computer device;
604. a processor;
606. a memory;
608. a driving mechanism;
610. an input/output module;
612. an input device;
614. an output device;
616. a presentation device;
618. a graphical user interface;
620. a network interface;
622. a communication link;
624. a communication bus.
Detailed Description
The following description of the embodiments of the present disclosure will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are only some, but not all embodiments of the disclosure. All other embodiments, based on the embodiments herein, which a person of ordinary skill in the art would obtain without undue burden, are within the scope of protection herein.
It should be noted that the terms "first," "second," and the like in the description and claims herein and in the foregoing figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments described herein may be capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, apparatus, article, or device that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed or inherent to such process, method, article, or device.
The present specification provides method operational steps as described in the examples or flowcharts, but may include more or fewer operational steps based on conventional or non-inventive labor. The order of steps recited in the embodiments is merely one way of performing the order of steps and does not represent a unique order of execution. When a system or apparatus product in practice is executed, it may be executed sequentially or in parallel according to the method shown in the embodiments or the drawings.
It should be noted that the method and the device for automatically determining the transaction flow direction herein may be used in the financial field, and may also be used in any field other than the financial field, and the application field of the method and the device for automatically determining the transaction flow direction herein is not limited.
In an embodiment of the present disclosure, a system for automatically determining a transaction flow direction is provided, which is used for solving the problems in the prior art that manual maintenance is adopted, and the method is wasteful in manpower, has large error, has poor real-time performance, and cannot automatically display the transaction flow direction. Specifically, as shown in fig. 1, the method includes: configuration end 101, service end 102 and database 103.
The configuration end 101 is configured to enable the user to initiate a transaction flow direction redetermination instruction to the service end 102 after a service is newly added or changed.
After receiving the transaction flow direction redetermining instruction sent by the configuration end 101, the service end 102 starts the agent in the service, so that the agent in the service executes the following flow: after each response transaction, the service judges whether the service calls other services or not; if not, generating an address list according to the address information of the node of the service response transaction, and sending the address list to a caller of the service; if so, waiting for address lists returned by other services, adding address information of nodes of the service responding to the transaction to the received address list, if a caller exists in the service, sending the added address list to the caller of the service, and if the caller does not exist in the service, determining the added address list as the transaction address list; comparing the transaction address list with the address list in the database, discarding the transaction address list if the same address list exists, and otherwise, updating the transaction address list into the database 103.
In detail, the configuration terminal 101 may be a desktop computer, a tablet computer, a notebook computer, a smart phone, a digital assistant, an intelligent wearable device, etc. Wherein, intelligent wearable equipment can include intelligent bracelet, intelligent wrist-watch, intelligent glasses, intelligent helmet etc.. Of course, the client is not limited to the electronic device with a certain entity, and may also be software running in the electronic device.
The server 102 is a background server, and can control agents in each service. The agent may be referred to as an agent, and is an application program embedded in a service, and is used to automatically collect a transaction address list representing a transaction flow direction, and it is known to those skilled in the art that the agent program may be obtained by encoding using an existing programming language after knowing the agent execution logic, which is not specifically limited herein.
The transactions described herein are accomplished by invoking a plurality of services, each having a plurality of nodes, each node being capable of being viewed as a computer device having a different IP address, different ports of each node being used to implement different functions.
The embodiment can accurately and automatically acquire the transaction address list reflecting the service call relationship in real time, ensures that the transaction address list in the database is effective information, and provides basis for real-time display of the subsequent transaction call relationship.
In one embodiment, a method for automatically determining a transaction flow direction is provided, and the method is applied to an agent in each service, as shown in fig. 2, and includes:
step 201, after each response transaction, the service judges whether the service calls other services; if not, go to step 202, if yes, go to step 203.
The service herein refers to a service where an agent is located, i.e. a service where the agent is installed. In the implementation, a flag bit can be set in the last service called by each transaction, each service judges whether the flag bit corresponding to the transaction exists or not, if not, the service is determined to not call other services, and if so, the service is determined to call other services.
Step 202, generating an address list according to address information of the node of the service response transaction, and sending the address list to the caller of the service.
If the service does not call other services, the service is an end service, and an address list is formed by address information of nodes of the service responding to the transaction.
In detail, address information of the node includes: IP address and port information, such as ip_c1: port C1. The node in service responding to the transaction can be determined by the IP address, and the specific function provided by the node can be determined by the port.
Step 203, wait for the address list returned by other services, add the address information of the node of the service response transaction to the received address list, if the service has a caller, send the newly added address list to the caller of the service, if the service does not have a caller, determine that the newly added address list is the transaction address list.
For example, as shown in fig. 3A, solid arrows in fig. 3A indicate a service call direction, and broken arrows indicate an address list return direction. In fig. 3A, a transaction calls service B through service a, service B calls service C1, and service C2. For service B, which calls service C1 and service C2, service B needs to wait for the address list ip_c1 returned by service C1: port C1, address list ip_c2 returned by service C2: port C2, in the received address list ip_c1: ports C1, ip_c2: after port C2, address information of service B is newly added, and the newly added address list is:
ip_c1: a port C1;
ip_c2: port C2;
ip_b: port B.
The service B has a caller service A, the newly added address list is sent to the service A, and after the service A newly adds the address information of the response transaction to the address list, the newly added address list is obtained as follows:
ip_c1: a port C1;
ip_c2: port C2;
ip_b: a port B;
ip_a: port a.
For service a, there is no caller, then the address list is a transaction address list.
The call relationship can be hierarchically determined by step 203, and the caller at the uppermost layer will receive address information of all service providers.
Step 204, comparing the transaction address list with the address list in the database, if the same address list exists, discarding the transaction address list, otherwise, updating the transaction address list into the database.
In this step, the transaction address list determined in step 203 is compared with the address list in the database, so that the transaction address list with the changed call link can be determined, and the latest transaction address list is updated to the database, so that the validity of the transaction address list in the database can be ensured.
In a further embodiment, the method for automatically determining the transaction flow direction includes, in addition to the steps 201 to 204, the following steps:
recording the updating time of the transaction address list, and sending the transaction address list newly added into the database to display equipment for display. In particular implementations, the update time information includes time of year, month, day, minute, and second, such as 2023-06-07 16:16:16.
In some embodiments, in order to increase the readability of the call link reflected by the list in the transaction address, when the display device displays the transaction address list, the node detail information corresponding to the IP address in the transaction address list is also acquired and displayed beside the IP address in the display device.
The embodiment is helpful for the analysis of subsequent system faults by recording the updating time of the transaction address list.
In one embodiment herein, the agents in each service are activated when a service is first requested or when a service is changed, and are deactivated after the service processes a predetermined amount of response transactions.
The specific implementation is that the predetermined amount is 1000 pens, for example, which is not limited herein, and may be set according to practical situations. By setting the preset quantity, the problem of inaccurate determination of the calling link caused by incomplete data acquisition can be avoided.
The service change is performed by the service upgrade, and the change content includes, but is not limited to, the connection of the node in the service, and the change of the calling link, for example, the original service A calls the service B, and the service A calls the service C instead.
By limiting the starting time of the agent, the agent can be prevented from being in a starting state all the time when the calling link of the transaction is unchanged, and therefore the computing resources are wasted.
Furthermore, when the service is changed or the service is requested for the first time, the transaction address list recorded in the database is subjected to zero clearing processing, so that the latest and effective transaction link is recorded in the database through zero clearing processing, and more redundant information is prevented from being stored in the database.
In the implementation, considering that the frequency of generating partial transaction is lower, when the service is changed or when the service is requested for the first time, the difference between the update time of the transaction address list in the database and the current time can be calculated, the difference is used as the update frequency of related transaction, the transaction address list with the difference smaller than a preset value is deleted, and the transaction address list with the difference larger than the preset value is reserved.
In one embodiment, when the address list is generated in the step 202 and when the address list is modified in the step 203, the method further includes: recording time information of adding the address information to the address list; and carrying out slow call alarming according to the time information of the adjacent address information in the address list.
In the specific implementation, calculating the difference value of the time information of the address information of the two adjacent services with the calling relation in the address list, judging whether the difference value is larger than a preset threshold value, if so, determining that the two adjacent services are called to have the problem of slow calling, and alarming the problem. The alarm mode includes, but is not limited to, sending a short message, sending a mail, and performing special display (such as highlighting, thickening, changing color, etc.) on the service with slow call problem when the call relation is displayed.
In one embodiment, the step 203 is performed by waiting for a predetermined time interval, and after the predetermined time interval expires, adding the address information of the node that is responding to the transaction to the received address list.
The embodiment can ensure that each service obtains the full address list by setting the preset time interval, and avoids the subsequent duplicate removal processing. The predetermined time interval may be determined by analyzing a minimum response time between adjacent services, and the specific value thereof is not limited herein.
In some embodiments, when the step 203 is implemented, it may also be determined whether the number of address lists returned by other services is equal to the number of other services called by the service, and if yes, the address information of the node of the service responding to the transaction is newly added to the received address list.
The embodiment can also ensure that each service obtains a full address list.
In one embodiment, the updating the transaction address list to the database in step 204 further includes: and numbering the address information according to the sequence from front to back of the address information in the transaction address list, so that the display equipment generates and displays the service calling relation according to the number information.
Taking fig. 3A as an example, the transaction address list determined by the service a is:
list 1:
ip_c1: a port C1;
ip_b: a port B;
ip_a: port a.
List 2:
ip_c2: port C2;
ip_b: a port B;
ip_a: port a.
Numbering the address information in the list 1 and the list 2 to obtain:
list 1:
1, ip_c1: a port C1;
2, ip_b: a port B;
3, ip_a: port a.
List 2:
1, ip_c2: port C2;
2, ip_b: a port B;
3, ip_a: port a.
The calling relation displayed by the display device according to the numbering result is shown in fig. 3B, and the arrow direction indicates the calling direction, for example, ip_a points to ip_b, which indicates that service a calls service B. The calling relation and the calling sequence can be intuitively seen through the display information.
In an embodiment of the present invention, before generating the address list in the step 202, setting a calling sequence number of the service, and generating the address list according to the address information of the service further includes: and generating an address list according to the calling sequence number of the service and the address information of the service. In general, the call sequence number is set to be 1, and the address list is in the form of: 1, ip_c2: port C2.
Step 203 further comprises generating a call sequence number of the service according to the call sequence number in the received address list before modifying the address list, and further comprises the following steps after adding the address information of the service to the received address list: and adding the calling sequence number of the service to the received address list.
In specific implementation, the call sequence number of the service is set to the next sequence number in the call sequence numbers in the received address list, for example, in fig. 3A, if the call sequence numbers of the service C1 and the service C2 are both 1, the call sequence number of the service B is 2, and the call sequence number of the service a is 3. In the specific implementation, other modes can be adopted to generate the calling sequence number, so long as the service calling sequence relationship can be correctly reflected.
In the embodiment, the calling sequence is determined from the small sequence to the large sequence, the calling sequence can be reflected by the calling sequence, the node with the large sequence is an upper layer service consumer, and the node with the relatively small sequence is a service provider.
In an embodiment herein, for a case where a service in the same transaction link invokes multiple services, multiple address lists are obtained, as shown in fig. 4, where the address list determined by the service B includes:
list 1
Ip_c1: a port C1;
ip_b: port B.
List 2:
ip_d: a port D;
ip_c2: port C2;
ip_b: port B.
If the list is directly stored in the database, more storage space is occupied, based on the fact that the list occupies more storage space, a plurality of newly added address lists determined by the service are de-overlapped and processed, and the processed address list is used as a final newly added address list;
and in the de-duplication merging process, the address information of the nodes called by the address information of the same node is used as parallel address information. Taking the list determined by service B in fig. 4 as an example, list 1 and list 2 have duplicate address information ip_b: port B, based on which the list after deduplication is:
ip_d: a port D;
ip_c1: a port C1;
ip_c2: port C2;
ip_b: port B.
When the embodiment is implemented, the lists are renumbered, and when the embodiment is implemented, the number of the lists can be added in the new number, for example, the first bit in the number represents the number of the list, the second bit represents the calling sequence number in the list, and the first bit and the second bit can be separated by a special symbol; and then merging the renumbered address list. And regarding the non-repeated address information, taking the renumbered serial number as a calling serial number, and regarding the repeated address information, taking all the renumbered serial numbers corresponding to the repeated address information as the calling serial numbers.
Based on the same inventive concept, there is also provided herein an apparatus for automatically determining a transaction flow direction, as described in the following embodiments. Since the principle of the automatic determination of the transaction flow direction device to solve the problem is similar to that of the automatic determination of the transaction flow direction method, the implementation of the automatic determination of the transaction flow direction device can refer to the automatic determination of the transaction flow direction method, and the repetition is not repeated. Specifically, as shown in fig. 5, the automatic determination of the transaction flow direction device includes:
the judging unit 501 is configured to judge whether the service invokes other services after the service responds to the transaction.
And a first address list unit 502, configured to generate an address list according to address information of a node of the service response transaction when the determination unit 501 determines that the determination result is negative, and send the address list to a caller of the service.
And a second address list unit 503, configured to wait for the address list returned by the other service when the determination result of the determination unit 501 is yes, and after the address information of the node of the service response transaction is newly added to the received address list, if the service has a caller, send the newly added address list to the caller of the service, and if the service does not have a caller, determine that the newly added address list is the transaction address list.
And a warehousing unit 504, configured to compare the transaction address list with the address list in the database, discard the transaction address list if the same address list exists, and otherwise update the transaction address list to the database.
Further, a client side for user interaction is provided, the user can send out a request for inquiring the transaction link through the client side, and according to the request for inquiring the transaction link sent by the user, a related transaction address list is called from the database to the client side, and the existing client side displays the transaction address list.
The embodiment can acquire the transaction address list capable of reflecting the service call relationship in real time, ensures that the transaction address list in the database is effective information, and provides basis for real-time display of the follow-up transaction call relationship. In a scene, when a system fails or is abnormal, after the calling relation is automatically switched, the technical scheme can sense the change of the calling link in real time, and truly embody the calling link.
In an embodiment herein, a computer device is also provided, as shown in fig. 6, the computer device 602 may include one or more processors 604, such as one or more Central Processing Units (CPUs), each of which may implement one or more hardware threads. The computer device 602 may also include any memory 606 for storing any kind of information, such as code, settings, data, etc. For example, and without limitation, memory 606 may include any one or more of the following combinations: any type of RAM, any type of ROM, flash memory devices, hard disks, optical disks, etc. More generally, any memory may store information using any technique. Further, any memory may provide volatile or non-volatile retention of information. Further, any memory may represent fixed or removable components of computer device 602. In one case, when the processor 604 executes associated instructions stored in any memory or combination of memories, the computer device 602 can perform any of the operations of the associated instructions. The computer device 602 also includes one or more drive mechanisms 608, such as a hard disk drive mechanism, an optical disk drive mechanism, and the like, for interacting with any memory.
The computer device 602 may also include an input/output module 610 (I/O) for receiving various inputs (via an input device 612) and for providing various outputs (via an output device 614). One particular output mechanism may include a presentation device 616 and an associated graphical user interface 618 (GUI). In other embodiments, input/output module 610 (I/O), input device 612, and output device 614 may not be included, but may be implemented as a single computer device in a network. The computer device 602 may also include one or more network interfaces 620 for exchanging data with other devices via one or more communication links 622. One or more communication buses 624 couple the above-described components together.
The communication link 622 may be implemented in any manner, for example, through a local area network, a wide area network (e.g., the internet), a point-to-point connection, etc., or any combination thereof. Communication link 622 may include any combination of hardwired links, wireless links, routers, gateway functions, name servers, etc., governed by any protocol or combination of protocols.
Embodiments herein also provide a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the above method.
Embodiments herein also provide a computer readable instruction, wherein the program therein causes a processor to perform the method of any of the preceding embodiments when the processor executes the instruction.
It should be understood that, in the various embodiments herein, the sequence number of each process described above does not mean the sequence of execution, and the execution sequence of each process should be determined by its functions and internal logic, and should not constitute any limitation on the implementation process of the embodiments herein.
It should also be understood that in embodiments herein, the term "and/or" is merely one relationship that describes an associated object, meaning that three relationships may exist. For example, a and/or B may represent: a exists alone, A and B exist together, and B exists alone. In addition, the character "/" herein generally indicates that the front and rear associated objects are an "or" relationship.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps described in connection with the embodiments disclosed herein may be embodied in electronic hardware, in computer software, or in a combination of the two, and that the elements and steps of the examples have been generally described in terms of function in the foregoing description to clearly illustrate the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present disclosure.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses and units may refer to corresponding procedures in the foregoing method embodiments, and are not repeated herein.
In the several embodiments provided herein, it should be understood that the disclosed systems, devices, and methods may be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of the units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. In addition, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices, or elements, or may be an electrical, mechanical, or other form of connection.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the elements may be selected according to actual needs to achieve the objectives of the embodiments herein.
In addition, each functional unit in the embodiments herein may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solutions herein are essentially or portions contributing to the prior art, or all or portions of the technical solutions may be embodied in the form of a software product stored in a storage medium, including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the embodiments herein. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Specific examples are set forth herein to illustrate the principles and embodiments herein and are merely illustrative of the methods herein and their core ideas; also, as will be apparent to those of ordinary skill in the art in light of the teachings herein, many variations are possible in the specific embodiments and in the scope of use, and nothing in this specification should be construed as a limitation on the invention.

Claims (13)

1. A method for automatically determining transaction flow direction for an agent in each service, the method comprising:
after each response transaction, the service judges whether the service calls other services or not;
if not, generating an address list according to the address information of the node of the service response transaction, and sending the address list to a caller of the service;
if so, waiting for address lists returned by other services, adding address information of nodes of the service responding to the transaction to the received address list, if a caller exists in the service, sending the added address list to the caller of the service, and if the caller does not exist in the service, determining the added address list as the transaction address list;
comparing the transaction address list with the address list in the database, discarding the transaction address list if the same address list exists, and otherwise, updating the transaction address list into the database.
2. The method of claim 1, wherein the update time of the transaction address list is also recorded when the transaction address list is updated to the database;
the method further comprises the steps of: and sending the transaction address list to a display device for display.
3. The method of claim 1, wherein the agent is activated when a service is first requested or when a service is changed, and is deactivated after a predetermined amount of response transactions are processed by the service.
4. The method of claim 1, wherein generating the address list or modifying the address list further comprises: recording time information of adding the address information to the address list;
and carrying out slow call alarming according to the time information of the adjacent address information in the address list.
5. The method of claim 1, wherein the address information comprises: IP address and port information.
6. The method of claim 1, wherein after determining that the service invokes other services, waiting a predetermined time interval, and after the predetermined time interval expires, adding address information of a node of the service responsive to the transaction to the received address list; or (b)
And judging whether the number of address lists returned by other services is equal to the number of other services called by the service, if so, adding the address information of the node of the service responding to the transaction into the received address list.
7. The method of claim 1, wherein prior to updating the transaction address list to the database further comprises: and numbering the address information according to the sequence from front to back of the address information in the transaction address list, so that the display equipment generates and displays the service calling relation according to the number information.
8. The method of claim 1, wherein generating the address list further comprises setting a call sequence number of the service, and generating the address list based on address information of the service is further: generating an address list according to the calling sequence number of the service and the address information of the service;
the method further comprises the steps of generating a calling sequence number of the service according to the calling sequence number in the received address list before modifying the address list, and further comprises the steps of: and adding the calling sequence number of the service to the received address list.
9. The method of claim 1, wherein the plurality of newly added address lists determined by the service are de-registered and processed, and the processed address list is used as a final newly added address list;
and in the de-duplication merging process, the address information of the nodes called by the address information of the same node is used as parallel address information.
10. An apparatus for automatically determining a transaction flow direction for use with an agent in each service, the apparatus comprising:
the judging unit is used for judging whether the service calls other services after responding to the transaction each time;
the first address list unit is used for generating an address list according to the address information of the node of the service response transaction if not, and sending the address list to a caller of the service;
the second address list unit is used for waiting for address lists returned by other services if the service exists, and after the address information of the node of the service response transaction is newly added to the received address list, if the service exists a caller, the newly added address list is sent to the caller of the service, and if the service does not exist the caller, the newly added address list is determined to be the transaction address list;
and the warehousing unit is used for comparing the transaction address list with the address list in the database, discarding the transaction address list if the same address list exists, and otherwise, updating the transaction address list into the database.
11. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method of any one of claims 1 to 9 when executing the computer program.
12. A computer storage medium having stored thereon a computer program, which when executed by a processor of a computer device implements the method of any of claims 1 to 9.
13. A computer program product, characterized in that the computer program product comprises a computer program which, when executed by a processor of a computer device, implements the method of any one of claims 1 to 9.
CN202311102424.4A 2023-08-29 2023-08-29 Method and device for automatically determining transaction flow direction Pending CN116993503A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311102424.4A CN116993503A (en) 2023-08-29 2023-08-29 Method and device for automatically determining transaction flow direction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311102424.4A CN116993503A (en) 2023-08-29 2023-08-29 Method and device for automatically determining transaction flow direction

Publications (1)

Publication Number Publication Date
CN116993503A true CN116993503A (en) 2023-11-03

Family

ID=88526763

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311102424.4A Pending CN116993503A (en) 2023-08-29 2023-08-29 Method and device for automatically determining transaction flow direction

Country Status (1)

Country Link
CN (1) CN116993503A (en)

Similar Documents

Publication Publication Date Title
CN110036600B (en) Network health data convergence service
CN110224899B (en) TCP application call chain acquisition method and device
CN113220540B (en) Service management method, device, computer equipment and storage medium
CN114706827A (en) Automatic generation method and device for transaction link topology
US8924343B2 (en) Method and system for using confidence factors in forming a system
US10838650B2 (en) Heat map transfer in space-efficient storage
CN111125106A (en) Batch running task execution method, device, server and storage medium
CN109997337B (en) Visualization of network health information
CN111651494A (en) Data processing method, device, equipment and computer readable storage medium
CN116993503A (en) Method and device for automatically determining transaction flow direction
CN113191901B (en) Transaction service processing method, device, equipment and storage medium
CN115729786A (en) Monitoring method, device, equipment and storage medium applied to multiple systems
CN112052016B (en) Gray scale release method and information system for transaction link
CN114049065A (en) Data processing method, device and system
CN112818204A (en) Service processing method, device, equipment and storage medium
CN114979143B (en) Distributed service implementation method and distributed service system
CN113271328B (en) Cloud server information management method and system
CN107392759A (en) A kind of disaster recovery method and device of foreign exchange Feed systems
CN111639936B (en) Transaction information acquisition method and device, electronic equipment and readable storage medium
CN113190367B (en) Cross-system data interaction method and device based on browser and electronic equipment
US11184463B1 (en) Interacting with a client system to gather client data to use to diagnose a problem at the client system
CN113901363A (en) Cloud server information analysis method and system
CN117112297A (en) Database backup method, device, equipment, storage medium and product
CN117221395A (en) Cross-system data interaction method, device, equipment and medium
CN116346883A (en) Micro-service instance management method and device and computing device cluster

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