CN111866144A - Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium - Google Patents

Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium Download PDF

Info

Publication number
CN111866144A
CN111866144A CN202010711755.8A CN202010711755A CN111866144A CN 111866144 A CN111866144 A CN 111866144A CN 202010711755 A CN202010711755 A CN 202010711755A CN 111866144 A CN111866144 A CN 111866144A
Authority
CN
China
Prior art keywords
service request
client
data
request
processing
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.)
Withdrawn
Application number
CN202010711755.8A
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.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent 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 Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202010711755.8A priority Critical patent/CN111866144A/en
Publication of CN111866144A publication Critical patent/CN111866144A/en
Withdrawn 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/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0811Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/133Protocols for remote procedure calls [RPC]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Environmental & Geological Engineering (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention discloses a service request response method, a service request response device, FPGA equipment and a computer readable storage medium, wherein the method comprises the following steps: acquiring a service request sent by a client; analyzing the service request according to a data protocol corresponding to the client to obtain target data; carrying out data processing on the target data to obtain a processing result; and responding to the service request by using the processing result. The method sets corresponding data protocols for the FPGA device and the client, the FPGA device and the client can directly carry out data communication by using the data protocols, and the FPGA device does not need to rely on a host when providing services. The target data needing to be processed can be obtained by analyzing the service request according to the data protocol, the processing result is obtained by processing the target data and the service request is responded, the response of the service request can be completed only by two times of data transmission, the time required by data transmission is reduced, and the request response time delay is small.

Description

Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium
Technical Field
The present invention relates to the field of parallel training technologies, and in particular, to a service request response method, a service request response apparatus, an FPGA device, and a computer-readable storage medium.
Background
FPGA (Field-Programmable Gate Array), i.e. a Field Programmable Gate Array. With the enhancement of the computational power of the FPGA and the popularization of the FPGA algorithm, more and more servers begin to use the FPGA as a computing unit. In the related art, when the FPGA device is used as a server to provide computing services for a client, data is required to be relayed (including data forwarding, data format conversion, and the like) through a host, for example, the client sends data to the host, and the host analyzes the data into a form that can be recognized by the FPGA device and then sends the data to the FPGA device for data processing. And after the data processing is finished, acquiring a processing result sent by the FPGA equipment, converting the processing result into a form which can be identified by the client, and forwarding the processing result to the client. Therefore, the related technology is very dependent on host to forward data, long time is needed for data transmission, and the request response time delay is large.
Therefore, how to solve the problems of the related art that the data transmission needs a long time and the request response delay is large is a technical problem to be solved by those skilled in the art.
Disclosure of Invention
In view of the above, the present invention provides a service request response method, a service request response apparatus, an FPGA device, and a computer readable storage medium, which solve the problems of long time required for data transmission and long request response delay in the related art.
In order to solve the above technical problem, the present invention provides a service request response method, including:
acquiring a service request sent by a client;
analyzing the service request according to a data protocol corresponding to the client to obtain target data;
performing data processing on the target data to obtain a processing result;
and carrying out serialization processing on the processing result according to the data protocol to obtain a serialization result, and responding to the service request by using the serialization result.
Optionally, the analyzing the service request according to the data protocol corresponding to the client to obtain target data includes:
selecting the data protocol according to the service request;
and analyzing the service request according to the data protocol to obtain the target data.
Optionally, the performing data processing on the target data to obtain a processing result includes:
determining a target data processing mode according to the service request;
and performing data processing on the target data according to the target data processing mode to obtain the processing result.
Optionally, before acquiring the service request sent by the client, the method further includes:
acquiring a registration request sent by registration equipment;
executing a registration operation according to the registration request;
and if the registration operation is finished, marking the registration equipment as the client and establishing connection with the client.
Optionally, the method further comprises:
sending a connection test request to the client;
judging whether connection test response information sent by the client side is received;
and if the connection test response information sent by the client is not received, disconnecting the connection with the client.
Optionally, after obtaining the service request sent by the client, before parsing the service request according to the data protocol corresponding to the client, the method further includes:
judging whether the mobile terminal is in an idle state;
if the service request is not in the idle state, the service request is put into a request queue;
and if the client is in the idle state, analyzing the service request according to a data protocol corresponding to the client to obtain target data.
Optionally, the placing the service request into a request queue includes:
judging whether the request number of the request queue is smaller than a preset value or not;
if the service request is not less than the preset value, responding to the service request by utilizing rejection information;
and if the service request is smaller than the preset value, the service request is placed at the tail of the request queue.
The invention also provides a service request response device, comprising:
the acquisition module is used for acquiring a service request sent by a client;
the analysis module is used for analyzing the service request according to a data protocol corresponding to the client to obtain target data;
the processing module is used for carrying out data processing on the target data to obtain a processing result;
and the response module is used for carrying out serialization processing on the processing result according to the data protocol to obtain a serialization result and responding the service request by using the serialization result.
The invention also provides an FPGA device, comprising a memory and a processor, wherein:
the memory is used for storing a computer program;
the processor is configured to execute the computer program to implement the service request response method.
The present invention also provides a computer-readable storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the service request response method described above.
The service request response method provided by the invention obtains the service request sent by the client; analyzing the service request according to a data protocol corresponding to the client to obtain target data; carrying out data processing on the target data to obtain a processing result; and responding to the service request by using the processing result.
Therefore, the method sets corresponding data protocols for the FPGA device and the client, and the data protocols explain the format of data transmitted between the FPGA device and the client. By using the data protocol, the FPGA equipment and the client can directly and accurately carry out data communication, and the FPGA equipment does not need to rely on a host when providing services. The target data needing to be processed can be obtained by analyzing the service request according to the data protocol, the processing result is obtained by processing the target data and the service request is responded, the response of the service request can be completed only by two times of data transmission, the time required by data transmission is reduced, and the request response time delay is small. The problems that the related technology needs long time for data transmission and the request response time delay is large are solved. Meanwhile, the host does not need to be relied on, so that the host does not need to be set or developed, and the development workload required when the FPGA equipment is used as a server to provide services is reduced.
In addition, the invention also provides a service request response device, FPGA equipment and a computer readable storage medium, and the beneficial effects are also achieved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a service request response method according to an embodiment of the present invention;
fig. 2 is a schematic diagram illustrating a service request response process according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a service request response apparatus according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an FPGA device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. 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 invention.
In a possible implementation manner, please refer to fig. 1, where fig. 1 is a flowchart of a service request response method according to an embodiment of the present invention. The method comprises the following steps:
s101: and acquiring a service request sent by a client.
Some or all of the steps in the embodiments of the present invention may be executed by an FPGA device, and the specific architecture, circuit design, and the like of the FPGA device are not limited. The client is a terminal which needs to perform data processing by using the FPGA device, such as a computer or a server, and may be any terminal which needs to perform data processing, or may be a terminal which is registered by the FPGA device, that is, a legal terminal which is acknowledged by the FPGA device. The client may request the service from the FPGA device by sending a service request, where the service request may specifically include initial data necessary for data processing, and may also include other content, such as information about a data processing manner. It should be noted that, in this embodiment, the language type adopted by the client is not limited, and may be, for example, C language, C + +, Java, python, and the like, and in order to enable the FPGA device to recognize the service request and ensure the accuracy of information transfer, the language adopted by the client itself may be serialized, so as to ensure the consistency of the service request formats corresponding to different languages.
It should be noted that, since the FPGA device communicates with the client directly, it is not necessary to pass through the host, and therefore, the FPGA device needs to be able to perform network communication. For example, a network protocol may be deployed on the FPGA device, for example, a TCP/IP protocol may be deployed, and the FPGA device may have a network transmission function through the deployment of the network protocol, so as to implement direct communication with the client. For a specific network protocol deployment manner, reference may be made to related technologies, which are not described herein again in this embodiment.
Further, in a possible implementation manner, in order to avoid a situation that the computing resources of the FPGA device are abused, the device or the terminal that requests the data processing may register, and only the device or the terminal that passes through the registration may be called a client. Before the step S101, the method may further include:
step 11: and acquiring a registration request sent by the registration equipment.
Step 12: and executing registration operation according to the registration request.
Step 13: and if the registration operation is finished, marking the registration equipment as the client and establishing connection with the client.
The register device can be any device, and the register request is generated by the register device according to the network protocol and is sent to the FPGA device. The specific content of the registration request is not limited in this embodiment, and may include information such as a device number, an IP address, a MAC address, and a right. After the registration request is obtained, the FPGA device executes registration operation according to the registration request, and the specific process of the registration operation is not limited. For example, whether the registered device has the authority to call the FPGA device may be determined according to the authority in the registration request, if so, the registration operation may be completed, and if not, the registration operation may not be completed. Or the MAC address in the registration request may be used to determine whether the registration device is in an address interval that allows the FPGA device to be called, and if so, may further determine whether the number of clients that have currently completed the registration operation reaches a threshold. If the threshold value is not reached, the registration operation can be completed, and if the threshold value is not in the address interval or is reached, the registration operation cannot be completed. If the registration operation is completed, the registered device may be marked as the client, and a connection may be established therebetween, so as to obtain the service request sent by the registered device.
Further, in a possible implementation manner, in order to timely release the computing resources and the communication resources of the FPGA device, the connection with the client may be tested, including:
step 21: and sending a connection test request to the client.
Step 22: and judging whether the connection test response information sent by the client is received.
Step 23: if the connection test response information sent by the client is not received, the connection with the client is disconnected
It should be noted that the present embodiment does not limit the execution timing of step 21, step 22, and step 23, and may be executed at any time after the connection is established with the client. For example, the connection may be established and executed before the service request is acquired; or after the service request is obtained, the method can be executed before the service request is responded; or may be performed after responding to a service request. The connection test request is used for testing the connection with the server, and can be a small data packet to avoid excessive occupation of communication resources. After receiving the connection test request, the client may respond to the connection test request, that is, send corresponding information of the connection test if the client needs to perform data processing by using the FPGA device or needs to maintain connection with the FPGA device. And when the FPGA equipment receives the connection test response information sent by the client, the connection between the FPGA equipment and the client is kept. If the connection test response information sent by the client is not received, the client does not need the FPGA equipment to provide service, so that the connection between the client and the client is disconnected. The embodiment does not limit the specific determination method for not receiving the connection test response information, for example, the connection test request may be sent according to a preset period when the connection test response information is not received, and when the sending times reach a preset number, it is determined that the corresponding information of the connection test sent by the client is not received.
Further, in a possible implementation, when receiving a service request sent by a client, the FPGA device may be performing data processing, and at this time, the service request may be placed in a request queue to wait for a response. After acquiring the service request sent by the client, before parsing the service request according to the data protocol corresponding to the client, the method may further include:
step 31: and judging whether the mobile terminal is in an idle state or not.
Step 32: and if the mobile terminal is not in the idle state, the service request is put into a request queue.
Step 33: and if the client is in the idle state, executing a step of analyzing the service request according to the data protocol corresponding to the client to obtain the target data.
When the FPGA device is in an idle state, namely when data processing is not performed, the FPGA device can immediately respond to a service request of a client. At this time, a step of parsing the service request according to the data protocol corresponding to the client to obtain the target data, i.e., step S102, may be performed. If the FPGA device is not in an idle state, i.e., is processing data, the service request cannot be immediately processed, and at this time, it may be placed in a request queue. The request queue is used to place service requests that cannot be processed immediately.
Further, when there are more service requests waiting for processing already in the request queue, the service request may be rejected in order to avoid long waiting time of the client. If the service request is not in the idle state, before the service request is put into a request queue, the method further includes:
step 41: and judging whether the request number of the request queue is smaller than a preset value.
Step 42: and if the service request is not less than the preset value, responding to the service request by utilizing the rejection information.
Step 43: and if the service request is smaller than the preset value, the step of putting the service request into the request queue is executed.
The specific size of the preset value may be set according to actual situations, which is not limited in this embodiment. When the number of requests in the request queue is the number of service requests waiting to be processed in the request queue. When the number of requests is smaller than the preset value, it indicates that the waiting time of the client is short, so that the client can be put into a request queue. When the number of the requests is not less than the preset value, the waiting time of the client is longer, so that the service request can be responded by using the rejection information, and the client can call other FPGA equipment.
S102: and analyzing the service request according to the data protocol corresponding to the client to obtain target data.
The data protocol is used for analyzing the service request sent by the client so as to acquire required data according to the service request and perform data processing. The type of the data protocol is not limited in this embodiment, and may be, for example, a custom RPC (Remote Procedure Call) protocol, or may be another type of custom protocol. For example, the data protocol may be as follows:
Figure BDA0002596796030000071
the target data is the initial data necessary for data processing in the service request, such as input data, parameter data, etc. necessary for data processing. The process of analyzing the service request by using the data protocol can be called as an deserialization process, and the FPGA equipment can obtain data of the data type in the FPGA through the deserialization process to finish cross-platform access of the data.
In one embodiment, one data protocol cannot be used to analyze service requests sent by all types of clients, so multiple data protocols may be set, and a corresponding data protocol is selected when analyzing the service requests. The S102 step may include:
step 51: a data protocol is selected based on the service request.
Step 52: and analyzing the service request according to the data protocol to obtain target data.
The embodiment does not limit the specific selection manner of the data protocol, for example, the service request may include a protocol field, and the data protocol is selected according to the protocol field. Or the format of the service request can be identified, and the data protocol corresponding to the service request is determined in a format identification mode.
S103: and carrying out data processing on the target data to obtain a processing result.
And after the target data are obtained, performing data processing on the target data to obtain a processing result. The present embodiment does not limit the specific process and manner of data processing, and reference may be made to related technologies. The embodiment also does not limit the content and form of the processing result, which can be related to the target data and the specific way of data processing.
In a possible implementation manner, the FPGA device may perform data processing by using a plurality of different processing manners, so that the client may select a data processing manner required by the client. The S103 step may include:
step 61: and determining a target data processing mode according to the service request.
Step 62: and carrying out data processing on the target data according to the target data processing mode to obtain a processing result.
Specifically, the service request may execute a target data processing method, such as an AI inference method, a matrix computation method, and the like. And after the target data processing mode is determined, performing data processing on the target data according to the target data processing mode to obtain a processing result.
S104: and carrying out serialization processing on the processing result according to a data protocol to obtain a serialization result, and responding to the service request by using the serialization result.
And after the processing result is obtained, continuing the serialization processing on the processing result according to the data protocol to obtain a serialization result. And responding the service request by using the serialization result, namely sending the service request to the client, wherein the client can perform deserialization processing on the serialization result to obtain a result corresponding to the language type of the client, and the response to the service request is completed.
By applying the service request response method provided by the embodiment of the invention, the corresponding data protocols are set for the FPGA equipment and the client, and the data protocols explain the format of data transmitted between the FPGA equipment and the client. By using the data protocol, the FPGA equipment and the client can directly and accurately carry out data communication, and the FPGA equipment does not need to rely on a host when providing services. The target data needing to be processed can be obtained by analyzing the service request according to the data protocol, the processing result is obtained by processing the target data and the service request is responded, the response of the service request can be completed only by two times of data transmission, the time required by data transmission is reduced, and the request response time delay is small. The problems that the related technology needs long time for data transmission and the request response time delay is large are solved. Meanwhile, the host does not need to be relied on, so that the host does not need to be set or developed, and the development workload required when the FPGA equipment is used as a server to provide services is reduced.
Based on the above embodiments, the present embodiment will specifically describe a response procedure of a service request. Referring to fig. 2, fig. 2 is a schematic diagram illustrating a service request response process according to an embodiment of the present invention. The Server is the FPGA device, and the client is the client. The client comprises a first service module, a first RPC protocol module and a first network module, and the FPGA device comprises a second service module, a second RPC protocol module and a second network module. The first network module and the second network module comprise network protocols, and the network protocols are used for supporting the network transmission functions of the client and the FPGA so as to directly communicate. The first RPC sequence module and the second RPC sequence module both have protocol codes, the protocol codes are data protocols, it should be noted that the contents of the two protocol codes are corresponding but not identical, and the protocol codes in the first RPC protocol module are used for converting data between a language form adopted by the client itself and serialized data, that is, protocol serialization or protocol deserialization. And the protocol code in the second RPC protocol module is used for converting the data between the FPGA internal data format and the serialized data, namely protocol serialization or protocol deserialization. The first service module in the client is used for sending a registration request when the service is discovered and is used for sending a service request. The second service module in the FPGA device is configured to perform a registration operation, i.e., a registration service function, and is further configured to receive a service request, i.e., a service receiving function. Meanwhile, the second service module is also used for processing data by using the processing program and maintaining the service queue. The Client registers the service to the server after discovering the service, namely sends a registration request to the FPGA device, and requests the service to the server after the registration is successful, namely sends a service request. After network connection is established between the Client and the server, service protocol packets based on an RPC protocol, namely protocol linen, are sent, and the FPGA returns data packets based on the RPC protocol when returning processing results.
The FPGA device serves as a server end and provides services. The network host firstly sends a registration request to the FPGA device through a network protocol, and the FPGA device carries out protocol deserialization processing on the registration request and executes corresponding registration operation. Only the registered network host can be used as a client to perform request service on the FPGA device. And after the FPGA equipment is registered, the execution result is serialized by an RPC protocol and is returned to the network host through the network. After the FPGA equipment is registered, the network host sends a service request operation packet to the FPGA equipment: the data packet is obtained by serializing the request obtained by the network host after writing the request by adopting a local language. And the FPGA equipment executes corresponding processing operation through protocol deserialization. And after the execution is finished, the execution result is subjected to RPC protocol serialization and returned to the network host through the network. When a plurality of network hosts simultaneously request for service, the FPGA equipment stores the requests into a queue according to the sequence of the received requests, sets the maximum value of the queue, and directly returns a rejection to a newly arrived request when the maximum number of the requests is reached.
In the following, the service request responding apparatus provided by the embodiment of the present invention is introduced, and the service request responding apparatus described below and the service request responding method described above may be referred to correspondingly.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a service request response apparatus according to an embodiment of the present invention, including:
an obtaining module 110, configured to obtain a service request sent by a client;
the analysis module 120 is configured to analyze the service request according to a data protocol corresponding to the client, so as to obtain target data;
the processing module 130 is configured to perform data processing on the target data to obtain a processing result;
the response module 140 is configured to perform serialization processing on the processing result according to the data protocol to obtain a serialization result, and respond to the service request by using the serialization result.
Optionally, the parsing module 120 includes:
a protocol determining unit for selecting a data protocol according to the service request;
and the analysis unit is used for analyzing the service request according to the data protocol to obtain the target data.
Optionally, the processing module 130 includes:
a processing mode determining unit, configured to determine a target data processing mode according to the service request;
and the processing unit is used for carrying out data processing on the target data according to the target data processing mode to obtain a processing result.
Optionally, the method further comprises:
a registration request acquisition module, configured to acquire a registration request sent by a registration device;
the registration module is used for executing registration operation according to the registration request;
and the connection establishing module is used for marking the registered equipment as the client and establishing connection with the client if the registration operation is finished.
Optionally, the method further comprises:
the test request sending module is used for sending a connection test request to the client;
the response judging module is used for judging whether connection test response information sent by the client side is received or not;
and the connection disconnection module is used for disconnecting the connection with the client if the connection test response information sent by the client is not received.
Optionally, the method further comprises:
the idle judging module is used for judging whether the mobile terminal is in an idle state or not;
the queue module is used for putting the service request into a request queue if the queue module is not in an idle state;
correspondingly, the parsing module 120 is a module that, if the module is in the idle state, parses the service request according to the data protocol corresponding to the client, and obtains the target data.
Optionally, the method further comprises:
the quantity judging module is used for judging whether the request quantity of the request queue is smaller than a preset value or not;
the rejection module is used for responding the service request by using the rejection information if the rejection information is not less than the preset value;
correspondingly, the queue module is a module for putting the service request into the request queue if the queue module is smaller than the preset value.
In the following, the FPGA device provided in the embodiment of the present invention is introduced, and the FPGA device described below and the service request response method described above may be referred to correspondingly.
Referring to fig. 4, fig. 4 is a schematic structural diagram of an FPGA device according to an embodiment of the present invention. Where the FPGA device 100 may include a processor 101 and a memory 102, it may further include one or more of a multimedia component 103, an information input/information output (I/O) interface 104, and a communication component 105.
The processor 101 is configured to control the overall operation of the FPGA device 100 to complete all or part of the steps in the service request response method; the memory 102 is used to store various types of data to support operation at the FPGA device 100, which may include, for example, instructions for any application or method operating on the FPGA device 100, as well as application-related data. The Memory 102 may be implemented by any type of volatile or non-volatile Memory device or combination thereof, such as one or more of Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic or optical disk.
The multimedia component 103 may include a screen and an audio component. Wherein the screen may be, for example, a touch screen and the audio component is used for outputting and/or inputting audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may further be stored in the memory 102 or transmitted through the communication component 105. The audio assembly also includes at least one speaker for outputting audio signals. The I/O interface 104 provides an interface between the processor 101 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 105 is used for wired or wireless communication between the FPGA device 100 and other devices. Wireless Communication, such as Wi-Fi, bluetooth, Near Field Communication (NFC), 2G, 3G, or 4G, or a combination of one or more of them, so that the corresponding Communication component 105 may include: Wi-Fi part, Bluetooth part, NFC part.
The FPGA Device 100 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components, and is configured to perform the service request response method according to the above embodiments.
In the following, the computer-readable storage medium provided by the embodiment of the present invention is introduced, and the computer-readable storage medium described below and the service request response method described above may be referred to correspondingly.
The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when being executed by a processor, implements the steps of the service request response method described above.
The computer-readable storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same or similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this 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 implementation. 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 invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
Finally, it should also be noted that, herein, relationships such as first and second, etc., are intended only to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms include, or any other variation is intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that includes 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.
The service request response method, the service request response device, the FPGA device, and the computer readable storage medium provided by the present invention are introduced in detail, and a specific example is applied in the present document to explain the principle and the implementation of the present invention, and the description of the above embodiment is only used to help understanding the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (10)

1. A service request response method, comprising:
acquiring a service request sent by a client;
analyzing the service request according to a data protocol corresponding to the client to obtain target data;
performing data processing on the target data to obtain a processing result;
and carrying out serialization processing on the processing result according to the data protocol to obtain a serialization result, and responding to the service request by using the serialization result.
2. The method according to claim 1, wherein the parsing the service request according to the data protocol corresponding to the client to obtain target data comprises:
selecting the data protocol according to the service request;
and analyzing the service request according to the data protocol to obtain the target data.
3. The method according to claim 2, wherein the performing data processing on the target data to obtain a processing result comprises:
determining a target data processing mode according to the service request;
and performing data processing on the target data according to the target data processing mode to obtain the processing result.
4. The service request response method according to claim 1, further comprising, before obtaining the service request sent by the client:
acquiring a registration request sent by registration equipment;
executing a registration operation according to the registration request;
and if the registration operation is finished, marking the registration equipment as the client and establishing connection with the client.
5. The service request response method according to claim 4, further comprising:
sending a connection test request to the client;
judging whether connection test response information sent by the client side is received;
and if the connection test response information sent by the client is not received, disconnecting the connection with the client.
6. The method according to claim 1, further comprising, after obtaining the service request sent by the client, before parsing the service request according to a data protocol corresponding to the client:
judging whether the mobile terminal is in an idle state;
if the service request is not in the idle state, the service request is put into a request queue;
and if the client is in the idle state, analyzing the service request according to a data protocol corresponding to the client to obtain target data.
7. The method of claim 6, wherein if not in the idle state, before placing the service request in a request queue, further comprising:
judging whether the request number of the request queue is smaller than a preset value or not;
if the service request is not less than the preset value, responding to the service request by utilizing rejection information;
and if the service request is smaller than the preset value, the step of putting the service request into a request queue is executed.
8. A service request response device, comprising:
the acquisition module is used for acquiring a service request sent by a client;
the analysis module is used for analyzing the service request according to a data protocol corresponding to the client to obtain target data;
the processing module is used for carrying out data processing on the target data to obtain a processing result;
and the response module is used for carrying out serialization processing on the processing result according to the data protocol to obtain a serialization result and responding the service request by using the serialization result.
9. An FPGA device, comprising a memory and a processor, wherein:
the memory is used for storing a computer program;
the processor for executing the computer program to implement the service request response method of any one of claims 1 to 7.
10. A computer-readable storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the service request response method according to any one of claims 1 to 7.
CN202010711755.8A 2020-07-22 2020-07-22 Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium Withdrawn CN111866144A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010711755.8A CN111866144A (en) 2020-07-22 2020-07-22 Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010711755.8A CN111866144A (en) 2020-07-22 2020-07-22 Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium

Publications (1)

Publication Number Publication Date
CN111866144A true CN111866144A (en) 2020-10-30

Family

ID=72949431

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010711755.8A Withdrawn CN111866144A (en) 2020-07-22 2020-07-22 Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111866144A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114172946A (en) * 2021-12-06 2022-03-11 京东科技信息技术有限公司 Request result sending method and device, electronic equipment and computer readable medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114172946A (en) * 2021-12-06 2022-03-11 京东科技信息技术有限公司 Request result sending method and device, electronic equipment and computer readable medium

Similar Documents

Publication Publication Date Title
CN107277153B (en) Method, device and server for providing voice service
CN110198247B (en) Interface test method and system
CN108574604B (en) Test method and device
CN107360261B (en) HTTP request processing method and device and electronic equipment
CN110798380B (en) Data acquisition method, system, device, test equipment and test server
US11916740B2 (en) K8S-based service deployment method and apparatus, device, and medium
WO2022105591A1 (en) Cache server performance test method and apparatus, device, and medium
CN110224896B (en) Network performance data acquisition method and device and storage medium
CN106357609A (en) User creation method and system, public network server and private cloud equipment
CN110933075B (en) Service calling method and device, electronic equipment and storage medium
CN110175130B (en) Cluster system performance testing method, device, equipment and readable storage medium
US20160234320A1 (en) System, device, and method for accessing cross-platform service
CN111866144A (en) Service request response method and device, FPGA (field programmable Gate array) equipment and storage medium
CN116627849B (en) System test method, device, equipment and storage medium
CN112714042A (en) Pressure testing method and device, electronic equipment and storage medium
CN113839828B (en) Network quality detection method, device, terminal equipment and medium
CN110602194B (en) IOT message subscription method, IOT message subscription device and computer readable storage medium
CN114025014A (en) Asset detection method and device, electronic equipment and storage medium
CN112019558A (en) Universal baffle testing method, device, equipment and computer storage medium
CN114238065A (en) Test processing method, device, equipment and readable storage medium
CN112804768B (en) Method and device for processing communication connection, terminal and non-transitory storage medium
CN112261051B (en) User registration method, device and system
CN113806213B (en) High-expandability SDK automatic test system and method
CN116627851B (en) Interface testing method and device
CN116155877A (en) Remote calling method and device, electronic equipment and computer readable storage medium

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
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20201030