CN112492036A - Information processing method and device, electronic equipment and storage medium - Google Patents

Information processing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112492036A
CN112492036A CN202011385775.7A CN202011385775A CN112492036A CN 112492036 A CN112492036 A CN 112492036A CN 202011385775 A CN202011385775 A CN 202011385775A CN 112492036 A CN112492036 A CN 112492036A
Authority
CN
China
Prior art keywords
target
program
information
application service
request 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
CN202011385775.7A
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.)
Chengdu Yanchuang Qixin Information Technology Co ltd
Original Assignee
Chengdu Yanchuang Qixin 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 Chengdu Yanchuang Qixin Information Technology Co ltd filed Critical Chengdu Yanchuang Qixin Information Technology Co ltd
Priority to CN202011385775.7A priority Critical patent/CN112492036A/en
Publication of CN112492036A publication Critical patent/CN112492036A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/562Brokering proxy services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Stored Programmes (AREA)

Abstract

The application provides an information processing method and device, an electronic device and a storage medium, and relates to the technical field of program development. The electronic equipment is deployed with an application service program and an information processing program based on a side car mode, and the information processing program is executed by the electronic equipment to realize an information processing method, wherein the method comprises the following steps: performing a monitoring operation on the target port; if the target request information is obtained based on the monitoring operation, determining a flow control strategy corresponding to the target request information; and determining whether to perform a sending operation on the target request information based on the flow control policy, wherein the sending operation comprises sending the target request information to the application service program so that the application service program accesses the corresponding target resource based on the target request information. Based on the method, the problem of low maintenance convenience of the program in the prior art can be solved.

Description

Information processing method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of program development technologies, and in particular, to an information processing method and apparatus, an electronic device, and a storage medium.
Background
Flow control means that flow and burst of a connection in a network are limited, and corresponding messages are sent at a relatively uniform speed to ensure stability of the system, for example, the messages are placed in a buffer or a queue, and then are processed based on a certain policy.
The inventors have found that, in the prior art, when a program for controlling the flow rate is maintained, there is a problem that the ease of operation is low, and it is difficult to perform effective maintenance.
Disclosure of Invention
In view of the above, an object of the present application is to provide an information processing method and apparatus, an electronic device, and a storage medium, so as to solve the problem of low convenience in maintaining a program in the prior art.
In order to achieve the above purpose, the embodiment of the present application adopts the following technical solutions:
an information processing method is applied to an electronic device, the electronic device is deployed with an application service program and an information processing program based on a side car mode, and the information processing program realizes the information processing method when being executed by the electronic device, and the method comprises the following steps:
performing a monitoring operation on the target port;
if the target request information is obtained based on the monitoring operation, determining a flow control strategy corresponding to the target request information, wherein the flow control strategy is generated based on the execution of configuration operation aiming at the target resource corresponding to the target request information in advance;
and determining whether to perform a sending operation on the target request information based on the flow control policy, wherein the sending operation comprises sending the target request information to the application service program so that the application service program accesses a corresponding target resource based on the target request information.
In a preferred option of the embodiment of the present application, in the information processing method, the step of performing a listening operation on the target port includes:
reading target port information in a target configuration file, wherein the target configuration file is generated based on the application service program and the information processing program;
and executing monitoring operation on a target port corresponding to the target port information.
In a preferred option of the embodiment of the present application, in the information processing method, the step of determining the traffic control policy corresponding to the target request information includes:
determining a target resource corresponding to the target request information based on the target request information;
and reading the flow control strategy corresponding to the target resource in a target configuration file, wherein the target configuration file is generated based on the application service program and the information processing program.
In a preferable selection of the embodiment of the present application, in the information processing method, the step of determining whether to perform a sending operation on the target request information based on the traffic control policy includes:
determining whether to send the target request information to the application service program based on the flow control strategy, and determining corresponding sending time information when the target request information needs to be sent;
and if the target request information needs to be sent to the application service program, sending the target request information to the application service program based on the sending time information.
In a preferred option of the embodiment of the present application, in the information processing method, the step of determining whether to perform a sending operation on the target request information based on the traffic control policy further includes:
if the target request information needs to be sent to the application service program, after the target request information is sent to the application service program, obtaining an access result of the application service program for accessing the corresponding target resource based on the target request;
if the target request information does not need to be sent to the application service program, generating an access result for indicating that the access to the corresponding target resource is rejected;
and sending the access result to a request pair corresponding to the target request information.
In a preferred option of the embodiment of the present application, in the information processing method, the method further includes:
obtaining port address information of the target port;
sending the port address information to a service registration program;
the service registration program is used for storing the port address information so as to send the port address information to other application service programs or the service calling program when obtaining service query information of the other application service programs or the service calling program, and the other application service programs or the service calling program are used for sending target request information to the target port based on the port address information so as to request the application service programs to access target resources.
An embodiment of the present application further provides an information processing apparatus, which is applied to an electronic device, where an application service program is deployed on the electronic device, and the application service program and the information processing apparatus are deployed based on a sidecar mode, and the information processing apparatus includes:
the monitoring operation execution module is used for executing monitoring operation on the target port;
a control policy determining module, configured to determine a traffic control policy corresponding to target request information when the target request information is obtained based on the monitoring operation, where the traffic control policy is generated based on a configuration operation performed in advance on a target resource corresponding to the target request information;
and the operation execution determining module is used for determining whether to execute sending operation on the target request information based on the flow control strategy, wherein the sending operation comprises sending the target request information to the application service program so that the application service program accesses the corresponding target resource based on the target request information.
In a preferred option of the embodiment of the present application, the information processing apparatus further includes:
an address information obtaining module, configured to obtain port address information of the target port;
the address information sending module is used for sending the port address information to a service registration program;
the service registration program is configured to store the port address information, so as to send the port address information to another application service program or the service calling program when obtaining service query information of the other application service program or the service calling program, where the other application service program or the service calling program is configured to send target request information to the target port based on the port address information, so as to request the application service program to access a target resource.
On the basis, an embodiment of the present application further provides an electronic device, including:
a memory for storing a computer program;
and the processor is connected with the memory and is used for executing the computer program stored in the memory so as to realize the information processing method.
On the basis of the foregoing, an embodiment of the present application further provides a computer-readable storage medium, which stores a computer program, and when the computer program is executed, the computer program implements the information processing method described above.
According to the information processing method and device, the electronic device and the storage medium, the information processing program is deployed in the application service program and the information processing program based on the sidecar mode, so that the information processing program can control the request information sent to the application service program based on the flow control strategy, and stable operation of the application service program is guaranteed. Therefore, the application service program and the information processing program are deployed based on the side car mode, so that the maintenance of the information processing program, such as updating and upgrading, can be independent of the application service program, the maintenance of the information processing program has higher operation convenience, and the problem of lower maintenance convenience of the program in the prior art is solved.
In order to make the aforementioned objects, features and advantages of the present application more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
Fig. 1 is a block diagram of an electronic device according to an embodiment of the present disclosure.
Fig. 2 is a schematic flowchart of an information processing method according to an embodiment of the present application.
Fig. 3 is a flowchart illustrating sub-steps included in step S110 in fig. 2.
Fig. 4 is a flowchart illustrating the sub-steps included in step S120 in fig. 2.
Fig. 5 is a flowchart illustrating sub-steps included in step S130 in fig. 2.
Fig. 6 is a flowchart illustrating other sub-steps included in step S130 in fig. 2.
Fig. 7 is a flowchart illustrating other steps included in the information processing method shown in fig. 2 based on the information processing method according to the embodiment of the present application.
Fig. 8 is a schematic diagram of an application scenario of the information processing method according to the embodiment of the present application.
Fig. 9 is a block diagram illustrating an information processing apparatus according to an embodiment of the present application.
Icon: 10-an electronic device; 12-a memory; 14-a processor; 100-an information processing apparatus; 110-a listening operation execution module; 120-a control strategy determination module; 130-operation execution determination module.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
As shown in fig. 1, an embodiment of the present application provides an electronic device 10, which may include a memory 12, a processor 14, and an information processing apparatus 100.
Wherein the memory 12 and the processor 14 are electrically connected directly or indirectly to realize data transmission or interaction. For example, they may be electrically connected to each other via one or more communication buses or signal lines. The information processing apparatus 100 includes at least one software functional module that can be stored in the memory 12 in the form of software or firmware (firmware). The processor 14 is configured to execute executable computer programs stored in the memory 12, such as application service programs, and software functional modules and computer programs included in the information processing apparatus 100, so as to implement the information processing method provided in the embodiment of the present application.
Alternatively, the Memory 12 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like.
The processor 14 may be a general-purpose processor including a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), and the like.
It will be appreciated that the configuration shown in FIG. 1 is merely illustrative and that the electronic device 10 may include more or fewer components than shown in FIG. 1 or may have a different configuration than shown in FIG. 1. For example, the electronic device 10 may further include a communication unit for information interaction with other devices.
Wherein, in an alternative example, the electronic device 10 may be a server having data processing capabilities.
With reference to fig. 2, an embodiment of the present application further provides an information processing method, which can be applied to the electronic device 10. Wherein, the electronic device 10 is deployed with an application service program (such as a Web application program, in an alternative example, the Web application program may be deployed by the same virtual machine or container as an information processing program, and one or more virtual machines or containers may be deployed on the electronic device 10, or a distributed deployment of the Web application program may be formed by a plurality of electronic devices 10 to cooperatively provide services) and the information processing program based on the sidecar mode, and the information processing program implements the information processing method when executed by the electronic device 10.
That is, the method steps defined by the flow relating to the information processing method may be implemented by the electronic device 10. The specific process shown in FIG. 2 will be described in detail below.
Step S110, a monitoring operation is performed on the target port.
In this embodiment, the electronic device 10 may perform a listening operation on the target port to determine whether to obtain the target request information. The target request information is used for requesting the application service program to access the target resource.
Step S120, if the target request information is obtained based on the monitoring operation, determining a traffic control policy corresponding to the target request information.
In this embodiment, after performing the listening operation on the target port based on step S110, if the target request information is obtained based on the listening operation, the electronic device 10 may determine the flow control policy corresponding to the target request information.
The flow control policy may be generated based on a pre-target resource performing configuration operation, where the target resource is a resource corresponding to (needing to be accessed by) the target request information.
Step S130, determining whether to perform a sending operation on the target request information based on the traffic control policy.
In this embodiment, after determining the flow control policy based on step S120, the electronic device 10 may determine whether to perform a transmission operation on the target request information based on the flow control policy. And sending the target request information to the application service program so that the application service program accesses the corresponding target resource based on the target request information.
That is, it is determined whether to transmit the target request information to the application service program.
Based on the method, on the basis of realizing the flow control request of the application service program, the application service program and the information processing program are deployed based on a side car mode, so that the maintenance of the information processing program, such as updating and upgrading, can be independent of the application service program, the maintenance of the information processing program has higher operation convenience, and the problem of lower maintenance convenience of the program in the prior art is solved.
In the first aspect, it should be noted that, in step S110, a manner of performing the listening operation on the target port is not limited, and may be selected according to an actual application requirement.
For example, in an alternative example, a snoop operation may be performed directly on all program ports of the information handler, so that snooping on a target port may be achieved.
For another example, in another alternative example, in order to avoid the problem of resource waste, in conjunction with fig. 3, step S110 may include step S111 and step S112, which is described in detail below.
Step S111, reading the destination port information in the destination configuration file.
In this embodiment, when a listening operation needs to be performed on a target port, for example, after the information processing program is started, a reading operation may be performed on a target configuration file, so that target port information may be read in the target configuration file.
Wherein the target configuration file is generated based on the application service program and the information processing program. That is, after the application service program and the information processing program are deployed or at least after the application service program and the information processing program are generated, a target port to be monitored can be determined, and thus, corresponding target port information can be obtained.
Step S112, performing a monitoring operation on the target port corresponding to the target port information.
In this embodiment, after the target port information is read based on step S111, a listening operation may be performed on a target port corresponding to the target port information.
That is, the target port may be determined based on the target port information, and then a listening operation may be performed on the target port.
In the second aspect, it should be noted that, in step S120, a specific manner for determining the flow control policy is not limited, and may be selected according to an actual application requirement.
For example, in an alternative example, if the control requirements for accessing all target resources are the same, only one flow control policy may be saved, and thus, the flow control policy may be directly determined as the flow control policy corresponding to the target request information.
For another example, in another alternative example, considering that different resources (such as video resources, document resources, etc.) generally have different access control requirements, in order to reliably and effectively control access to the target resource, in conjunction with fig. 4, step S120 may include step S121 and step S122, which are described in detail below.
Step S121, determining a target resource corresponding to the target request information based on the target request information.
In this embodiment, after performing the snoop operation on the target port based on step S110, if the target request information is obtained based on the snoop operation, the target resource corresponding to the target request information (i.e. the resource requested to be accessed by the target request information) may be determined based on the target request information.
Step S122, reading the flow control policy corresponding to the target resource from the target configuration file.
In this embodiment, after determining the target resource based on step S121, a read operation may be performed on the target configuration file, so that a flow control policy corresponding to the target resource, such as maximum QPS (Query Per Second, request amount Per Second), may be read in the target configuration file.
The target configuration file is generated based on the application service program and the information processing program (as described above, it is not described in detail here).
It is understood that, in the above example, the target configuration file may include the target port information and the flow control policy, and, based on different requirements, may further include other information, such as maximum load information of the electronic device 10, a load of the electronic device 10, a maximum utilization rate of a central processor and a memory, port information of the application service program, address information of a registration object when performing registration, and address information (url, uniform resource locator) of health detection of the application service program by the registration object after registration.
In the third aspect, it should be noted that, for step S130, a specific manner for determining whether to perform the generating operation is not limited, and may be selected according to actual application requirements.
For example, in an alternative example, it may be determined directly whether the target request message needs to be sent to the application service. That is, if the flow control policy is met, the target request message may be directly sent to the application service program; if the flow control policy is not met, the target request information may not be sent to the application service program, for example, the target request information is directly discarded, i.e., the service is refused to be provided.
For another example, in another alternative example, in order to ensure the reliability of the flow control, in conjunction with fig. 5, step S130 may include step S131 and step S132, which are described in detail below.
Step S131, determining whether to send the target request information to the application service program based on the flow control strategy, and determining corresponding sending time information when the target request information needs to be sent.
In this embodiment, after determining the flow control policy based on step S120, it may be determined whether to send the target request information to the application service program based on the flow control policy (e.g., whether the current request amount per second of the target resource is greater than the maximum request amount per second, and if the current request amount per second is greater than the maximum request amount per second, it may be determined not to send the target request information to the application service program). When it is determined that the target request information needs to be generated to the application service program, the corresponding transmission time information may be determined first.
Step S132, sending the target request information to the application service program based on the sending time information.
In this embodiment, after determining that the target request information and the transmission time information need to be transmitted based on step S131, the target request information may be transmitted to the application service program based on the transmission time information (wherein the transmission time information may be 0, indicating that the target request information is immediately transmitted to the application service program).
That is, the target request information may be transmitted to the application service program after the transmission time information has passed, and thus, the frequency with which the target resource is accessed may be alleviated.
On the basis of the above example, it is considered that the access request based on the target request information may obtain a corresponding access result, and based on a certain requirement, the access result may also be sent to the request object. Based on this, with reference to fig. 6, step S130 may further include step S133, step S134, and step S135, which are specifically described below.
Step S133, obtaining an access result of the application service program accessing the corresponding target resource based on the target request.
In this embodiment, if it is determined that the target request information needs to be sent to the application service program based on step S131, after step S132 is executed to send the target request information to the application service program, the application service program may access the corresponding target resource based on the target request information, and thus, a corresponding access result (such as a resource that requests to be returned) may be formed, and thus, the access result may be obtained.
In step S134, an access result indicating that access to the corresponding target resource is denied is generated.
In this embodiment, if it is determined based on step S131 that the target request information does not need to be sent to the application service program, a corresponding access result may also be generated. The access result is used to indicate that access to the corresponding target resource is denied.
Step S135, sending the access result to the request object corresponding to the target request information.
In this embodiment, after obtaining the access result based on step S133 or step S134, the obtained access result may be sent to the request object corresponding to the target request information (in this way, the request object may obtain the requested resource or learn that the access is denied, etc.).
On the basis of the above example, it is considered that when a request object needs to request the application service program to access a target resource, the target request information needs to be sent through a target port of the information processing program, and therefore, the request object needs to obtain an address of the target port. Based on this, in order to facilitate the request object to obtain the address, the information processing method may further include step S140 and step S150 in conjunction with fig. 7, which is described in detail below.
Step S140, obtaining the port address information of the target port.
In this embodiment, the electronic device 10 may obtain port address information of the target port.
Step S150, sending the port address information to a service registration program.
In this embodiment, after obtaining the port address information based on step S140, the electronic device 10 may send the port address information to a service registration program.
The service registration program is configured to store the port address information, so as to send the port address information to another application service program or a service calling program (which may be referred to as the request object) when obtaining service query information of the other application service program or the service calling program, where the other application service program or the service calling program is configured to send target request information (where a request of the other application service program may be referred to as an internal request and a request of the service calling program may be referred to as an external request) to the target port based on the port address information, so as to request the application service program to access a target resource, where the request of the other application service program may be a request for implementing a mutual request between the application service programs or a request of an external program for the application service program.
It is understood that, when the port information is sent to the service registration program based on step S150, considering that in some examples, the number of the application service programs may be large, so for convenience of management, the application identification information of the application service program may be sent to the service registration program together when step S150 is executed.
Based on this, when the request object needs to access the target resource through the application service program, the service registration program may be queried first to obtain the application identification information of each application service program, then one application service program may be selected from the service registration program (for example, one with the smallest current load may be selected based on load balancing), then the port address information of the target port of the corresponding information processing program is determined based on the application identification information of the application service program, and then the target request information is sent to the target port based on the port address information.
On the basis of the above example, the embodiment of the present application further provides a specific application scenario of the information processing method. With reference to fig. 8, in the application scenario, an application server 1, an application server 2, an application server 3, a registry server, and a load balancing server may be included.
The application server 1, the application server 2 and the application server 3 are respectively deployed with a virtual machine 1, a virtual machine 2 and a virtual machine 3, the virtual machine 1 includes a Web application program 1 and an information processing program 1, the virtual machine 2 includes a Web application program 2 and an information processing program 2, and the virtual machine 3 includes a Web application program 3 and an information processing program 3.
In this manner, the information processing program 1 can transmit the port address information of the information processing program 1 and the application identification information of the Web application 1 to the registry server to cause the registry server to complete the registration processing based on the deployed service registry, thereby saving the port address information and the application identification information. The information processing program 2 may transmit the port address information of the information processing program 2 and the application identification information of the Web application 2 to the registry server to cause the registry server to complete registration processing based on the deployed service registration program, thereby saving the port address information and the application identification information. The information processing program 3 may transmit the port address information of the information processing program 3 and the application identification information of the Web application 3 to the registry server to cause the registry server to complete registration processing based on the deployed service registry, thereby saving the port address information and the application identification information. Based on this, the registry server stores the port address information of the information processing program 1 and the application identification information of the Web application 1, the port address information of the information processing program 2 and the application identification information of the Web application 2, the port address information of the information processing program 3 and the application identification information of the Web application 3.
Then, if the Web application 1 needs to access resources on other application servers, all the application identification information may be obtained from the registry server first, and then, an application server with the minimum load may be selected, so as to determine the application identification information of the corresponding Web application, such as the application identification information of the Web application 2. In this way, the port address information of the information processing program 2 corresponding to the Web application 2 can be acquired again, and the request information can be transmitted to the target port of the information processing program 2.
If the external device needs to access the resource on the application server, the request information may be sent to the load balancing server first, and the load balancing server may obtain all the application identification information from the registry server first, and then may select an application server with the smallest load, thereby determining the application identification information of the corresponding Web application program, such as the application identification information of the Web application program 3. In this way, the port address information of the information processing program 3 corresponding to the Web application 3 can be acquired again, and the request information can be transmitted to the target port of the information processing program 3.
With reference to fig. 9, an information processing apparatus 100 is further provided in the embodiment of the present application, and is applicable to the electronic device 10. Wherein, the electronic device 10 is deployed with an application service program, and the application service program is deployed with the information processing apparatus 100 based on a sidecar mode, and the information processing apparatus 100 includes a monitoring operation executing module 110, a control policy determining module 120, and an operation execution determining module 130.
The snoop operation executing module 110 is configured to execute a snoop operation on a target port. In this embodiment, the listening operation performing module 110 may be configured to perform step S110 shown in fig. 2, and reference may be made to the foregoing description of step S110 for relevant contents of the listening operation performing module 110.
The control policy determining module 120 is configured to determine a flow control policy corresponding to target request information when the target request information is obtained based on the monitoring operation, where the flow control policy is generated based on a configuration operation performed in advance on a target resource corresponding to the target request information. In this embodiment, the control strategy determination module 120 may be configured to perform step S120 shown in fig. 2, and reference may be made to the foregoing description of step S120 for relevant contents of the control strategy determination module 120.
The operation execution determining module 130 is configured to determine whether to execute a sending operation on the target request information based on the flow control policy, where the sending operation includes sending the target request information to the application service program, so that the application service program accesses a corresponding target resource based on the target request information. In this embodiment, the operation execution determination module 130 may be configured to execute step S130 shown in fig. 2, and the foregoing description of step S130 may be referred to for relevant content of the operation execution determination module 130.
On the basis of the above example, the information processing apparatus may further include different other modules to implement different functions based on different requirements.
For example, in an alternative example, the information processing apparatus 100 may further include an address information obtaining module and an address information transmitting module.
In detail, the address information obtaining module is configured to obtain port address information of the target port. And the address information sending module is used for sending the port address information to a service registration program. The service registration program is configured to store the port address information, so as to send the port address information to another application service program or the service calling program when obtaining service query information of the other application service program or the service calling program, where the other application service program or the service calling program is configured to send target request information to the target port based on the port address information, so as to request the application service program to access a target resource.
In an embodiment of the present application, there is also provided a computer-readable storage medium having a computer program stored therein, where the computer program executes to execute the steps of the information processing method.
The steps executed when the computer program runs are not described in detail herein, and reference may be made to the foregoing explanation of the information processing method.
In summary, the information processing method and apparatus, the electronic device, and the storage medium provided by the present application are deployed in the application service program and the information processing program based on the sidecar mode, so that the information processing program can control the request information sent to the application service program based on the flow control policy, so as to ensure stable operation of the application service program. Therefore, the application service program and the information processing program are deployed based on the side car mode, so that the maintenance of the information processing program, such as updating and upgrading, can be independent of the application service program, the maintenance of the information processing program has higher operation convenience, and the problem of lower maintenance convenience of the program in the prior art is solved.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method can be implemented in other ways. The apparatus and method embodiments described above are illustrative only, as the flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, functional modules in the embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, an electronic device, or a network device) to perform all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes. It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (10)

1. An information processing method applied to an electronic device, the electronic device being deployed with an application service program and an information processing program based on a sidecar mode, the information processing program implementing the information processing method when executed by the electronic device, the method comprising:
performing a monitoring operation on the target port;
if the target request information is obtained based on the monitoring operation, determining a flow control strategy corresponding to the target request information, wherein the flow control strategy is generated based on the execution of configuration operation aiming at the target resource corresponding to the target request information in advance;
and determining whether to perform a sending operation on the target request information based on the flow control policy, wherein the sending operation comprises sending the target request information to the application service program so that the application service program accesses a corresponding target resource based on the target request information.
2. The information processing method according to claim 1, wherein the step of performing a snoop operation on the target port comprises:
reading target port information in a target configuration file, wherein the target configuration file is generated based on the application service program and the information processing program;
and executing monitoring operation on a target port corresponding to the target port information.
3. The information processing method according to claim 1, wherein the step of determining the traffic control policy corresponding to the target request information includes:
determining a target resource corresponding to the target request information based on the target request information;
and reading the flow control strategy corresponding to the target resource in a target configuration file, wherein the target configuration file is generated based on the application service program and the information processing program.
4. The information processing method according to claim 1, wherein the step of determining whether to perform a transmission operation on the target request information based on the traffic control policy includes:
determining whether to send the target request information to the application service program based on the flow control strategy, and determining corresponding sending time information when the target request information needs to be sent;
and if the target request information needs to be sent to the application service program, sending the target request information to the application service program based on the sending time information.
5. The information processing method according to claim 4, wherein the step of determining whether to perform a transmission operation on the target request information based on the traffic control policy further comprises:
if the target request information needs to be sent to the application service program, after the target request information is sent to the application service program, obtaining an access result of the application service program for accessing the corresponding target resource based on the target request;
if the target request information does not need to be sent to the application service program, generating an access result for indicating that the access to the corresponding target resource is rejected;
and sending the access result to a request object corresponding to the target request information.
6. The information processing method according to any one of claims 1 to 5, characterized by further comprising:
obtaining port address information of the target port;
sending the port address information to a service registration program;
the service registration program is used for storing the port address information so as to send the port address information to other application service programs or the service calling program when obtaining service query information of the other application service programs or the service calling program, and the other application service programs or the service calling program are used for sending target request information to the target port based on the port address information so as to request the application service programs to access target resources.
7. An information processing apparatus, applied to an electronic device, wherein an application service program is deployed in the electronic device, and the application service program and the information processing apparatus are deployed based on a sidecar mode, the information processing apparatus comprising:
the monitoring operation execution module is used for executing monitoring operation on the target port;
a control policy determining module, configured to determine a traffic control policy corresponding to target request information when the target request information is obtained based on the monitoring operation, where the traffic control policy is generated based on a configuration operation performed in advance on a target resource corresponding to the target request information;
and the operation execution determining module is used for determining whether to execute sending operation on the target request information based on the flow control strategy, wherein the sending operation comprises sending the target request information to the application service program so that the application service program accesses the corresponding target resource based on the target request information.
8. The information processing apparatus according to claim 7, characterized by further comprising:
an address information obtaining module, configured to obtain port address information of the target port;
the address information sending module is used for sending the port address information to a service registration program;
the service registration program is configured to store the port address information, so as to send the port address information to another application service program or the service calling program when obtaining service query information of the other application service program or the service calling program, where the other application service program or the service calling program is configured to send target request information to the target port based on the port address information, so as to request the application service program to access a target resource.
9. An electronic device, comprising:
a memory for storing a computer program;
a processor connected to the memory for executing the computer program stored in the memory to implement the information processing method of any one of claims 1 to 6.
10. A computer-readable storage medium storing a computer program, characterized in that the computer program, when executed, implements the information processing method of any one of claims 1 to 6.
CN202011385775.7A 2020-12-01 2020-12-01 Information processing method and device, electronic equipment and storage medium Pending CN112492036A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011385775.7A CN112492036A (en) 2020-12-01 2020-12-01 Information processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011385775.7A CN112492036A (en) 2020-12-01 2020-12-01 Information processing method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112492036A true CN112492036A (en) 2021-03-12

Family

ID=74938510

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011385775.7A Pending CN112492036A (en) 2020-12-01 2020-12-01 Information processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112492036A (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101296256A (en) * 2008-06-19 2008-10-29 中国电信股份有限公司 Method and system for implementing accurate information propelling by internet
CN107317816A (en) * 2017-07-05 2017-11-03 北京信息职业技术学院 A kind of method for network access control differentiated based on client application
CN109981789A (en) * 2019-04-03 2019-07-05 山东浪潮云信息技术有限公司 A kind of micro services engine based on proxy mode
CN110413416A (en) * 2019-07-31 2019-11-05 中国工商银行股份有限公司 A kind of current-limiting method and device of distributed server
US10547456B1 (en) * 2017-01-19 2020-01-28 Tigera, Inc. Policy controlled cryptography
CN110990205A (en) * 2019-11-28 2020-04-10 腾讯科技(深圳)有限公司 Interface call testing method, device and computer readable storage medium
CN111049913A (en) * 2019-12-17 2020-04-21 中国建设银行股份有限公司 Data file transmission method and device, storage medium and electronic equipment
CN111510478A (en) * 2020-04-07 2020-08-07 支付宝(杭州)信息技术有限公司 Request processing method, device and system and electronic equipment

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101296256A (en) * 2008-06-19 2008-10-29 中国电信股份有限公司 Method and system for implementing accurate information propelling by internet
US10547456B1 (en) * 2017-01-19 2020-01-28 Tigera, Inc. Policy controlled cryptography
CN107317816A (en) * 2017-07-05 2017-11-03 北京信息职业技术学院 A kind of method for network access control differentiated based on client application
CN109981789A (en) * 2019-04-03 2019-07-05 山东浪潮云信息技术有限公司 A kind of micro services engine based on proxy mode
CN110413416A (en) * 2019-07-31 2019-11-05 中国工商银行股份有限公司 A kind of current-limiting method and device of distributed server
CN110990205A (en) * 2019-11-28 2020-04-10 腾讯科技(深圳)有限公司 Interface call testing method, device and computer readable storage medium
CN111049913A (en) * 2019-12-17 2020-04-21 中国建设银行股份有限公司 Data file transmission method and device, storage medium and electronic equipment
CN111510478A (en) * 2020-04-07 2020-08-07 支付宝(杭州)信息技术有限公司 Request processing method, device and system and electronic equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
丁乙等: "面向军用微服务的服务网格架构研究与设计", 《指挥信息系统与技术》 *

Similar Documents

Publication Publication Date Title
CN109428922B (en) Subscription and publishing method and server
JP4876170B2 (en) System and method for tracking security enforcement in a grid system
CN107733839B (en) Data transmission method and system
EP1672495A1 (en) Grid parallel execution
CN110995873A (en) Gateway service interface discovery method, system, electronic device and storage medium
CN109617824B (en) Data acquisition method and device and server
US11575689B2 (en) System, method, and computer program product for dynamically configuring a virtual environment for identifying unwanted data
CN111580993A (en) Data processing method and device, electronic equipment and storage medium
CN112597039A (en) Virtual machine access method, system, device and computer readable storage medium
CN108600008B (en) Server management method, server management device and distributed system
CN111552441B (en) Data storage method and device, main node and distributed system
CN111586171B (en) Server operation method and device, electronic equipment and storage medium
US10257285B2 (en) Resource migration method and apparatus
US20220334877A1 (en) Method for overload control in a container-virtualized computing apparatus
CN107332703B (en) Method and device for checking multi-application logs
CN113259429A (en) Session keeping control method, device, computer equipment and medium
US8904533B2 (en) Determining heavy distinct hitters in a data stream
CN112492036A (en) Information processing method and device, electronic equipment and storage medium
CN113596105B (en) Content acquisition method, edge node and computer readable storage medium
CN114528114B (en) Data processing method, device and equipment
CN112118275B (en) Overload processing method, internet of things platform and computer readable storage medium
CN109639639B (en) Fusion control method and device for multi-platform monitoring system
CN113259203A (en) Terminal performance monitoring method and device
CN114143056B (en) Terminal access method and device, electronic equipment and storage medium
CN108108243B (en) Resource sharing system and method

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210312