CN114240459A - Service speed-based provider selection method, device, equipment and storage medium - Google Patents

Service speed-based provider selection method, device, equipment and storage medium Download PDF

Info

Publication number
CN114240459A
CN114240459A CN202111544155.8A CN202111544155A CN114240459A CN 114240459 A CN114240459 A CN 114240459A CN 202111544155 A CN202111544155 A CN 202111544155A CN 114240459 A CN114240459 A CN 114240459A
Authority
CN
China
Prior art keywords
time
service
response
response time
supplier
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
CN202111544155.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.)
Ping An Property and Casualty Insurance Company of China Ltd
Original Assignee
Ping An Property and Casualty Insurance Company of China 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 Ping An Property and Casualty Insurance Company of China Ltd filed Critical Ping An Property and Casualty Insurance Company of China Ltd
Priority to CN202111544155.8A priority Critical patent/CN114240459A/en
Publication of CN114240459A publication Critical patent/CN114240459A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/01Customer relationship services
    • G06Q30/012Providing warranty services

Landscapes

  • Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Finance (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention relates to the field of data analysis, and discloses a supplier selection method based on service speed, which comprises the following steps: constructing a sliding time window, configuring the time dimension of the sliding time window, and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension; receiving response data sent by the server of the supplier according to the service acquisition request; calculating the interval time between the sending of the service acquisition request and the receiving of the response data to obtain response time, and selecting the maximum response time and the minimum response time from the response time; calculating average response time according to the maximum response time and the minimum response time; and selecting the service of the supplier according to the average response time and a preset supplier selection rule. The invention also provides a supplier selection device, equipment and a storage medium based on the service speed. The invention can improve the management efficiency of the supplier.

Description

Service speed-based provider selection method, device, equipment and storage medium
Technical Field
The present invention relates to the field of data analysis, and in particular, to a service speed-based provider selection method and apparatus, an electronic device, and a readable storage medium.
Background
With the development of economy, more and more suppliers are involved in docking for enterprises, especially large-scale enterprises, the service quality of each supplier is uneven, and how to effectively manage the suppliers in real time and improve the service quality is a difficulty. At present, the existing supplier management method needs to set management logic in advance according to business rules, certain hysteresis exists in management, the management logic often needs to be changed according to business requirements, and the suppliers cannot be managed in real time, so that the operation intelligence is insufficient, and the management efficiency of enterprise parties to the suppliers is low.
Disclosure of Invention
The invention provides a supplier selection method, a supplier selection device, electronic equipment and a computer-readable storage medium based on service speed, and aims to improve the management efficiency of suppliers.
In order to achieve the above object, the present invention provides a provider selection method based on service speed, including:
constructing a sliding time window, configuring the time dimension of the sliding time window, and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension;
receiving response data sent by the server of the supplier according to the service acquisition request;
calculating the interval time between the sending of the service acquisition request and the receiving of the response data to obtain response time, and selecting the maximum response time and the minimum response time from the response time;
calculating average response time according to the maximum response time and the minimum response time;
and selecting the service of the supplier according to the average response time and a preset supplier selection rule.
Optionally, the configuring the time dimension of the sliding time window includes:
according to the service requirements, selecting suppliers meeting the service requirements;
acquiring historical response time of the supplier, and determining the time length of each time slice in the sliding time window according to the historical response time;
determining a time length of the sliding time window according to the number of suppliers;
and determining the time dimension of the sliding time window according to the time length of the time segment and the time length of the sliding time window.
Optionally, the time dimension of the sliding time window further comprises a processing period, and the processing period comprises a start time and/or an end time of the sliding time window.
Optionally, the receiving response data sent by the server of the provider according to the service acquisition request includes:
performing timestamp conversion on time data in the service acquisition request of the request interface in the sliding time window to obtain a starting timestamp;
acquiring time information of response data received by a receiving interface in the sliding time window, and performing timestamp conversion on the response data according to the time information to obtain a response timestamp;
and storing the starting time stamp and the response time stamp on a pre-constructed B + tree according to the time stamp sequence.
Optionally, when the sliding time window cannot process the reception response time within the processing period, the receiving response data sent by the server of the provider according to the request for obtaining service includes:
obtaining the residual processing time of the response data according to the time information of the response data and the processing period of the sliding time window;
and allocating the response data to other sliding time windows consistent with the remaining processing time of the response data for continuous processing.
Optionally, the calculating an interval time between sending the service acquisition request and receiving the response data to obtain a response time includes:
extracting a start timestamp and a corresponding response timestamp from a leaf node in the B + tree;
and calculating according to the starting time stamp and the response time stamp to obtain the response time.
Optionally, the selecting a service for the provider according to the average response time and a preset provider selection rule includes:
traversing the average response time of each supplier, and deleting the average response time larger than a preset threshold and the corresponding suppliers;
carrying out reciprocal change on the average response time of the rest suppliers to obtain the reciprocal of the average response time;
carrying out rounding comparison on the inverses, and determining the proportion weight of each supplier in the rest suppliers;
and selecting the service of the supplier according to the proportion weight.
In order to solve the above problems, the present invention also provides an offline product recommendation apparatus, including:
the service request sending module is used for constructing a sliding time window, configuring the time dimension of the sliding time window and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension;
an average response time calculation module, configured to receive response data sent by the provider server according to the service acquisition request, calculate an interval time between sending the service acquisition request and receiving the response data, obtain response times, select a maximum response time and a minimum response time from the response times, and calculate an average response time according to the maximum response time and the minimum response time;
and the supplier selection module is used for selecting the service of the supplier according to the average response time and a preset supplier selection rule.
In order to solve the above problem, the present invention also provides an electronic device, including:
a memory storing at least one computer program; and
a processor executing a computer program stored in the memory to implement the service speed based provider selection method described above.
In order to solve the above problem, the present invention also provides a computer-readable storage medium having at least one computer program stored therein, the at least one computer program being executed by a processor in an electronic device to implement the service speed-based provider selection method described above.
The supplier selection method and device based on the service speed, the electronic equipment and the readable storage medium provided by the embodiment of the invention realize real-time selection of suppliers by constructing the time window and configuring the dimension of the time window without setting the requirement logic in advance according to the business rule, thereby improving the management efficiency of the suppliers. Furthermore, the time window is utilized to perform service response time test on the suppliers meeting the preset service requirements, and the suppliers are selected for service according to the test results, so that the risk of selecting the suppliers mistakenly is reduced, the real-time management of the suppliers is realized, and the management efficiency of the suppliers is improved.
Drawings
FIG. 1 is a flow chart illustrating a method for provider selection based on service speed according to an embodiment of the present invention;
FIG. 2 is a block diagram of an offline product recommendation device according to an embodiment of the present invention;
fig. 3 is a schematic internal structural diagram of an electronic device implementing a service-speed-based provider selection method according to an embodiment of the present invention;
the implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The embodiment of the invention provides a supplier selection method based on service speed. The execution subject of the service speed-based provider selection method includes, but is not limited to, at least one of a server, a terminal, and the like that can be configured to execute the method provided by the embodiments of the present application. In other words, the service speed-based provider selection method may be performed by software installed in a terminal device or a server device, or hardware, and the software may be a block chain platform. The server may include an independent server, or a cloud server providing basic cloud computing services such as cloud service, a cloud database, cloud computing, cloud functions, cloud storage, Network service, cloud communication, middleware service, domain name service, security service, Content Delivery Network (CDN), big data and an artificial intelligence platform.
Referring to fig. 1, which is a schematic flow chart of a service-speed-based provider selection method according to an embodiment of the present invention, in an embodiment of the present invention, the service-speed-based provider selection method includes:
s1, constructing a sliding time window, configuring the time dimension of the sliding time window, and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension.
In the embodiment of the invention, the sliding time window is obtained by dividing the time window into smaller time segments, and the time window slides to the right by one grid every time segment, wherein each time segment is provided with an independent counter, and the total number of requests of the whole time window can be calculated by accumulating the counters of all the time segments.
In the embodiment of the present invention, the time dimension of the sliding time window may include the time length of the entire sliding time window and the time length of each time slice. For example, the time length of the whole time window is determined to be one minute, and the time window is divided into ten time segments, and the time length of each time segment is six seconds, so that the time dimension of the sliding time window is obtained.
In an optional embodiment of the present invention, the frequency of sending the service acquisition request to the server of the provider is determined by configuring the time dimension of the sliding time window, so as to prevent a critical problem from occurring, thereby influencing an enterprise to select a provider with a high service quality.
In detail, the configuring the time dimension of the sliding time window comprises:
selecting a supplier meeting the preset service requirement;
acquiring historical response time of the supplier, and determining the time length of each time slice in the sliding time window according to the historical response time;
determining a time length of the sliding time window according to the number of suppliers;
and determining the time dimension of the sliding time window according to the time length of the time segment and the time length of the sliding time window.
Further, the time dimension of the sliding time window further comprises a processing period, the processing period comprising a start time and/or an end time of the sliding time window.
In the embodiment of the present invention, the sliding time window can adjust the starting time of the time window, so that the sliding time window can be earlier when sending the service acquisition request, but still maintain the same time interval.
In addition, it should be understood that the sending of the service acquisition request to the server of the provider meeting the preset service requirement according to the time dimension is within the same sliding time window, so as to ensure that no error occurs in the selection of the provider, thereby enabling a higher accuracy of the selection of the provider.
And S2, receiving response data sent by the server of the supplier according to the service acquisition request.
In an optional embodiment of the present invention, interface response data in the sliding time window is received, time data in the service acquisition request of the interface is converted into a timestamp, the response data is used as an attribute of the Java object, and the timestamp and the response data are stored in the B + tree.
The B + tree refers to a tree data structure, which is commonly used in a file system of a database and an operating system. The timestamp and the response data are stored in the B + tree, so that data sorting and tracking are facilitated.
In detail, the receiving response data sent by the server of the provider according to the request for obtaining the service includes:
performing timestamp conversion on time data in the service acquisition request of the sliding time window to obtain a starting timestamp;
acquiring time information of response data received by the sliding time window, and performing timestamp conversion on the response data according to the time information to obtain a response timestamp;
and storing the starting time stamp and the response time stamp on a pre-constructed B + tree according to the time stamp sequence.
In an optional embodiment of the present invention, when each sliding time window processes a response time including a time information attribute, a problem that the number of response times exceeds the upper limit of the number of processing response times of the sliding time window may be encountered. Therefore, when the sliding time window cannot process the reception response time within the processing cycle, the embodiment of the present invention may further include:
obtaining the residual processing time of the response data according to the time information of the response data and the processing period of the sliding time window;
and allocating the response data to other sliding time windows consistent with the remaining processing time of the response data for continuous processing.
S3, calculating the interval time between the sending of the service acquisition request and the receiving of the response data to obtain the response time, and selecting the maximum response time and the minimum response time from the response time.
In this embodiment of the present invention, the response time may be a time difference between the service acquisition request sent by each time slice in the sliding event window and the response data sent by the server of the provider, and may be used to judge the service quality of the provider.
In detail, the calculating an interval time between sending the service acquisition request and receiving the response data to obtain a response time includes:
extracting a start timestamp and a corresponding response timestamp from a leaf node in the B + tree;
and calculating according to the starting time stamp and the response time stamp to obtain the response time.
In an alternative embodiment of the present invention, the time for sending the service acquisition requests to the servers of A, B, C, D four providers is 12 hours, 13 minutes, 30 seconds, 12 hours, 13 minutes, 42 seconds, 12 hours, 13 minutes, 48 seconds, the time for receiving the response data sent by the servers of A, B, C, D four providers corresponding to the service acquisition request of 12 hours, 13 minutes, 30 seconds, 12 hours, 13 minutes, 45 seconds, 12 hours, 13 minutes, 50 seconds, 12 hours, 14 minutes, 0 seconds, respectively, the response time of A, B, C, D four providers is 10 seconds, 15 seconds, 20 seconds, and 30 seconds, the response time of a provider a is 10 seconds, 12 seconds, 11 seconds, and 8 seconds, respectively, the response time of B provider B is 15 seconds, 12 minutes, 13 minutes, 48 seconds, respectively, and the response time of A, B, C, D four providers corresponding to the service acquisition request of 12 hours, 13 minutes, 30 seconds, respectively, 18 seconds and 17 seconds, wherein the four response times of the C supplier are respectively 20 seconds, 15 seconds, 21 seconds and 25 seconds, the four response times of the D supplier are respectively 30 seconds, 20 seconds, 22 seconds and 30 seconds, the maximum response time of the A supplier is 12 seconds, the minimum response time is 8 seconds, the maximum response time of the B supplier is 18 seconds, the minimum response time is 12 seconds, the maximum response time of the C supplier is 25 seconds, the minimum response time is 15 seconds, the maximum response time of the D supplier is 30 seconds, and the minimum response time is 20 seconds.
And S4, calculating average response time according to the maximum response time and the minimum response time.
In the embodiment of the invention, the maximum response time and the average response time of the minimum response time can be calculated through an average algorithm, so that the error rate of selecting suppliers is reduced, and the suppliers with better service quality are selected more accurately.
In an optional embodiment of the present invention, when the maximum response time of the a-provider is 12 seconds and the minimum response time is 8 seconds, the average response time of the a-provider is calculated by an average algorithm to be 10 seconds; when the maximum response time of the B supplier is 18 seconds and the minimum response time is 12 seconds, the average response time of the B supplier is 15 seconds; when the maximum response time of the C supplier is 25 seconds and the minimum response time is 15 seconds, the average response time of the C supplier is 20 seconds; when the maximum response time of the D-vendor is 30 seconds and the minimum response time is 20 seconds, the average response time of the D-vendor is 25 seconds.
And S5, selecting the service of the supplier according to the average response time and a preset supplier selection rule.
In the embodiment of the present invention, the preset provider selection rule may be a rule that is formulated by a service person to better select a provider with good service quality. The service selection refers to selecting a certain supplier to serve the enterprise or the company.
In an optional embodiment of the present invention, suppliers with average response time greater than a preset threshold may be removed, and then the average response time of each of the suppliers is subjected to reciprocal comparison.
In detail, the selecting a service for the provider according to the average response time and a preset provider selection rule includes:
traversing the average response time of each supplier, and deleting the average response time larger than a preset threshold and the corresponding suppliers;
carrying out reciprocal change on the average response time of the rest suppliers to obtain the reciprocal of the average response time;
carrying out rounding comparison on the inverses, and determining the proportion weight of each supplier in the rest suppliers;
and selecting the service of the supplier according to the proportion weight.
In the embodiment of the invention, the rounding comparison refers to comparing the inverses and converting all inverses into integers according to a certain proportion.
The supplier selection method based on the service speed, provided by the embodiment of the invention, is used for testing the service response time of the supplier meeting the preset service requirement by constructing the time window and configuring the dimensionality of the time window, and further, the supplier is selected for use according to the test result without setting requirement logic in advance according to the service rule, so that the risk of selecting the supplier error is reduced, the real-time management of the supplier is realized, and the management efficiency of the supplier is improved.
Fig. 2 is a functional block diagram of the off-line product recommendation device according to the present invention.
The offline product recommendation apparatus 100 according to the present invention may be installed in an electronic device. According to the implemented functions, the offline product recommendation apparatus may include a service request sending module 101, an average response time calculation module 102 and a supplier selection module 103, which may also be referred to as a unit, and refer to a series of computer program segments that can be executed by a processor of the electronic device and can perform fixed functions, and are stored in a memory of the electronic device.
In the present embodiment, the functions regarding the respective modules/units are as follows:
the service request sending module 101 is configured to construct a sliding time window, configure a time dimension of the sliding time window, and send an acquisition service request to a server of a provider meeting a preset service requirement according to the time dimension.
In the embodiment of the invention, the sliding time window is obtained by dividing the time window into smaller time segments, and the time window slides to the right by one grid every time segment, wherein each time segment is provided with an independent counter, and the total number of requests of the whole time window can be calculated by accumulating the counters of all the time segments.
In the embodiment of the present invention, the time dimension of the sliding time window may include the time length of the entire sliding time window and the time length of each time slice. For example, the time length of the whole time window is determined to be one minute, and the time window is divided into ten time segments, and the time length of each time segment is six seconds, so that the time dimension of the sliding time window is obtained.
In an optional embodiment of the present invention, the frequency of sending the service acquisition request to the server of the provider is determined by configuring the time dimension of the sliding time window, so as to prevent a critical problem from occurring, thereby influencing an enterprise to select a provider with a high service quality.
In detail, the configuring the time dimension of the sliding time window comprises:
selecting a supplier meeting the preset service requirement;
acquiring historical response time of the supplier, and determining the time length of each time slice in the sliding time window according to the historical response time;
determining a time length of the sliding time window according to the number of suppliers;
and determining the time dimension of the sliding time window according to the time length of the time segment and the time length of the sliding time window.
Further, the time dimension of the sliding time window further comprises a processing period, the processing period comprising a start time and/or an end time of the sliding time window.
In the embodiment of the present invention, the sliding time window can adjust the starting time of the time window, so that the sliding time window can be earlier when sending the service acquisition request, but still maintain the same time interval.
In addition, it should be understood that the sending of the service acquisition request to the server of the provider meeting the preset service requirement according to the time dimension is within the same sliding time window, so as to ensure that no error occurs in the selection of the provider, thereby enabling a higher accuracy of the selection of the provider.
The average response time calculation module 102 is configured to receive response data sent by the provider server according to the service acquisition request, calculate an interval time between sending the service acquisition request and receiving the response data, obtain response times, select a maximum response time and a minimum response time from the response times, and calculate an average response time according to the maximum response time and the minimum response time.
In an optional embodiment of the present invention, interface response data in the sliding time window is received, time data in the service acquisition request of the interface is converted into a timestamp, the response data is used as an attribute of the Java object, and the timestamp and the response data are stored in the B + tree.
The B + tree refers to a tree data structure, which is commonly used in a file system of a database and an operating system. The timestamp and the response data are stored in the B + tree, so that data sorting and tracking are facilitated.
In detail, the receiving response data sent by the server of the provider according to the request for obtaining the service includes:
performing timestamp conversion on time data in the service acquisition request of the sliding time window to obtain a starting timestamp;
acquiring time information of response data received by the sliding time window, and performing timestamp conversion on the response data according to the time information to obtain a response timestamp;
and storing the starting time stamp and the response time stamp on a pre-constructed B + tree according to the time stamp sequence.
In an optional embodiment of the present invention, when each sliding time window processes a response time including a time information attribute, a problem that the number of response times exceeds the upper limit of the number of processing response times of the sliding time window may be encountered. Therefore, when the sliding time window cannot process the reception response time within the processing cycle, the embodiment of the present invention may further include:
obtaining the residual processing time of the response data according to the time information of the response data and the processing period of the sliding time window;
and allocating the response data to other sliding time windows consistent with the remaining processing time of the response data for continuous processing.
In this embodiment of the present invention, the response time may be a time difference between the service acquisition request sent by each time slice in the sliding event window and the response data sent by the server of the provider, and may be used to judge the service quality of the provider.
In detail, the calculating an interval time between sending the service acquisition request and receiving the response data to obtain a response time includes:
extracting a start timestamp and a corresponding response timestamp from a leaf node in the B + tree;
and calculating according to the starting time stamp and the response time stamp to obtain the response time.
In an alternative embodiment of the present invention, the time for sending the service acquisition requests to the servers of A, B, C, D four providers is 12 hours, 13 minutes, 30 seconds, 12 hours, 13 minutes, 42 seconds, 12 hours, 13 minutes, 48 seconds, the time for receiving the response data sent by the servers of A, B, C, D four providers corresponding to the service acquisition request of 12 hours, 13 minutes, 30 seconds, 12 hours, 13 minutes, 45 seconds, 12 hours, 13 minutes, 50 seconds, 12 hours, 14 minutes, 0 seconds, respectively, the response time of A, B, C, D four providers is 10 seconds, 15 seconds, 20 seconds, and 30 seconds, the response time of a provider a is 10 seconds, 12 seconds, 11 seconds, and 8 seconds, respectively, the response time of B provider B is 15 seconds, 12 minutes, 13 minutes, 48 seconds, respectively, and the response time of A, B, C, D four providers corresponding to the service acquisition request of 12 hours, 13 minutes, 30 seconds, respectively, 18 seconds and 17 seconds, wherein the four response times of the C supplier are respectively 20 seconds, 15 seconds, 21 seconds and 25 seconds, the four response times of the D supplier are respectively 30 seconds, 20 seconds, 22 seconds and 30 seconds, the maximum response time of the A supplier is 12 seconds, the minimum response time is 8 seconds, the maximum response time of the B supplier is 18 seconds, the minimum response time is 12 seconds, the maximum response time of the C supplier is 25 seconds, the minimum response time is 15 seconds, the maximum response time of the D supplier is 30 seconds, and the minimum response time is 20 seconds.
In the embodiment of the invention, the maximum response time and the average response time of the minimum response time can be calculated through an average algorithm, so that the error rate of selecting suppliers is reduced, and the suppliers with better service quality are selected more accurately.
In an optional embodiment of the present invention, when the maximum response time of the a-provider is 12 seconds and the minimum response time is 8 seconds, the average response time of the a-provider is calculated by an average algorithm to be 10 seconds; when the maximum response time of the B supplier is 18 seconds and the minimum response time is 12 seconds, the average response time of the B supplier is 15 seconds; when the maximum response time of the C supplier is 25 seconds and the minimum response time is 15 seconds, the average response time of the C supplier is 20 seconds; when the maximum response time of the D-vendor is 30 seconds and the minimum response time is 20 seconds, the average response time of the D-vendor is 25 seconds.
The supplier selection module 103 is configured to select a service for the supplier according to the average response time and a preset supplier selection rule.
In the embodiment of the present invention, the preset provider selection rule may be a rule that is formulated by a service person to better select a provider with good service quality.
In an optional embodiment of the present invention, suppliers with average response time greater than a preset threshold may be removed, and then the average response time of each of the suppliers is subjected to reciprocal comparison.
In detail, the selecting a service for the provider according to the average response time and a preset provider selection rule includes:
traversing the average response time of each supplier, and deleting the average response time larger than a preset threshold and the corresponding suppliers;
carrying out reciprocal change on the average response time of the rest suppliers to obtain the reciprocal of the average response time;
carrying out rounding comparison on the inverses, and determining the proportion weight of each supplier in the rest suppliers;
and selecting the service of the supplier according to the proportion weight.
In the embodiment of the invention, the rounding comparison refers to comparing the inverses and converting all inverses into integers according to a certain proportion.
Fig. 3 is a schematic structural diagram of an electronic device implementing the service-speed-based provider selection method according to the present invention.
The electronic device may comprise a processor 10, a memory 11, a communication bus 12 and a communication interface 13, and may further comprise a computer program, such as an off-line product recommendation program, stored in the memory 11 and executable on the processor 10.
The memory 11 includes at least one type of readable storage medium, which includes flash memory, removable hard disk, multimedia card, card-type memory (e.g., SD or DX memory, etc.), magnetic memory, magnetic disk, optical disk, etc. The memory 11 may in some embodiments be an internal storage unit of the electronic device, for example a removable hard disk of the electronic device. The memory 11 may also be an external storage device of the electronic device in other embodiments, such as a plug-in mobile hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the electronic device. Further, the memory 11 may also include both an internal storage unit and an external storage device of the electronic device. The memory 11 may be used not only to store application software installed in the electronic device and various types of data, such as codes of offline product recommendation programs, etc., but also to temporarily store data that has been output or is to be output.
The processor 10 may be composed of an integrated circuit in some embodiments, for example, a single packaged integrated circuit, or may be composed of a plurality of integrated circuits packaged with the same or different functions, including one or more Central Processing Units (CPUs), microprocessors, digital Processing chips, graphics processors, and combinations of various control chips. The processor 10 is a Control Unit (Control Unit) of the electronic device, connects various components of the whole electronic device by using various interfaces and lines, and executes various functions and processes data of the electronic device by running or executing programs or modules (e.g., off-line product recommendation programs, etc.) stored in the memory 11 and calling data stored in the memory 11.
The communication bus 12 may be a PerIPheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus may be divided into an address bus, a data bus, a control bus, etc. The communication bus 12 is arranged to enable connection communication between the memory 11 and at least one processor 10 or the like. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
Fig. 3 shows only an electronic device having components, and those skilled in the art will appreciate that the structure shown in fig. 3 does not constitute a limitation of the electronic device, and may include fewer or more components than those shown, or some components may be combined, or a different arrangement of components.
For example, although not shown, the electronic device may further include a power supply (such as a battery) for supplying power to each component, and preferably, the power supply may be logically connected to the at least one processor 10 through a power management device, so that functions of charge management, discharge management, power consumption management and the like are realized through the power management device. The power supply may also include any component of one or more dc or ac power sources, recharging devices, power failure detection circuitry, power converters or inverters, power status indicators, and the like. The electronic device may further include various sensors, a bluetooth module, a Wi-Fi module, and the like, which are not described herein again.
Optionally, the communication interface 13 may include a wired interface and/or a wireless interface (e.g., WI-FI interface, bluetooth interface, etc.), which is generally used to establish a communication connection between the electronic device and other electronic devices.
Optionally, the communication interface 13 may further include a user interface, which may be a Display (Display), an input unit (such as a Keyboard (Keyboard)), and optionally, a standard wired interface, or a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is suitable, among other things, for displaying information processed in the electronic device and for displaying a visualized user interface.
It is to be understood that the described embodiments are for purposes of illustration only and that the scope of the appended claims is not limited to such structures.
The off-line product recommendation program stored in the memory 11 of the electronic device is a combination of a plurality of computer programs, which when executed in the processor 10, may implement:
constructing a sliding time window, configuring the time dimension of the sliding time window, and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension;
receiving response data sent by the server of the supplier according to the service acquisition request;
calculating the interval time between the sending of the service acquisition request and the receiving of the response data to obtain response time, and selecting the maximum response time and the minimum response time from the response time;
calculating average response time according to the maximum response time and the minimum response time;
and selecting the service of the supplier according to the average response time and a preset supplier selection rule.
Specifically, the processor 10 may refer to the description of the relevant steps in the embodiment corresponding to fig. 1 for a specific implementation method of the computer program, which is not described herein again.
Further, the electronic device integrated module/unit, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in a computer readable storage medium. The computer readable medium may be non-volatile or volatile. The computer-readable medium may include: any entity or device capable of carrying said computer program code, recording medium, U-disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM).
Embodiments of the present invention may also provide a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor of an electronic device, the computer program may implement:
constructing a sliding time window, configuring the time dimension of the sliding time window, and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension;
receiving response data sent by the server of the supplier according to the service acquisition request;
calculating the interval time between the sending of the service acquisition request and the receiving of the response data to obtain response time, and selecting the maximum response time and the minimum response time from the response time;
calculating average response time according to the maximum response time and the minimum response time;
and selecting the service of the supplier according to the average response time and a preset supplier selection rule.
Further, the computer usable storage medium may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function, and the like; the storage data area may store data created according to the use of the blockchain node, and the like.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus, device and method can be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the modules is only one logical functional division, and other divisions may be realized in practice.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional module.
It will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof.
The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference signs in the claims shall not be construed as limiting the claim concerned.
The block chain is a novel application mode of computer technologies such as distributed data storage, point-to-point transmission, a consensus mechanism, an encryption algorithm and the like. A block chain (Blockchain), which is essentially a decentralized database, is a series of data blocks associated by using a cryptographic method, and each data block contains information of a batch of network transactions, so as to verify the validity (anti-counterfeiting) of the information and generate a next block. The blockchain may include a blockchain underlying platform, a platform product service layer, an application service layer, and the like.
Furthermore, it is obvious that the word "comprising" does not exclude other elements or steps, and the singular does not exclude the plural. A plurality of units or means recited in the system claims may also be implemented by one unit or means in software or hardware. The terms second, etc. are used to denote names, but not any particular order.
Finally, it should be noted that the above embodiments are only for illustrating the technical solutions of the present invention and not for limiting, and although the present invention is described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that modifications or equivalent substitutions may be made on the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.

Claims (10)

1. A method for service speed based provider selection, the method comprising:
constructing a sliding time window, configuring the time dimension of the sliding time window, and sending a service acquisition request to a server of a provider according to the time dimension;
receiving response data sent by the server of the supplier according to the service acquisition request;
calculating the interval time between the sending of the service acquisition request and the receiving of the response data to obtain response time, and selecting the maximum response time and the minimum response time from the response time;
calculating average response time according to the maximum response time and the minimum response time;
and selecting the service of the supplier according to the average response time and a preset supplier selection rule.
2. The service speed based provider selection method of claim 1, wherein said configuring a time dimension of said sliding time window comprises:
according to the service requirements, selecting suppliers meeting the service requirements;
acquiring historical response time of the supplier, and determining the time length of each time slice in the sliding time window according to the historical response time;
determining a time length of the sliding time window according to the number of suppliers;
and determining the time dimension of the sliding time window according to the time length of the time segment and the time length of the sliding time window.
3. The service speed based provider selection method of claim 2, wherein the time dimension of the sliding time window further comprises a processing period, the processing period comprising a start time and/or an end time of the sliding time window.
4. The service speed based provider selection method as claimed in claim 1, wherein said receiving response data transmitted by said provider's server according to said get service request comprises:
performing timestamp conversion on time data in the service acquisition request of the request interface in the sliding time window to obtain a starting timestamp;
acquiring time information of response data received by a receiving interface in the sliding time window, and performing timestamp conversion on the response data according to the time information to obtain a response timestamp;
and storing the starting time stamp and the response time stamp on a pre-constructed B + tree according to the time stamp sequence.
5. The service speed-based provider selection method according to claim 4, wherein when the sliding time window cannot process a reception completion response time within the processing period, the receiving of the response data transmitted by the server of the provider according to the get service request comprises:
obtaining the residual processing time of the response data according to the time information of the response data and the processing period of the sliding time window;
and allocating the response data to other sliding time windows consistent with the remaining processing time of the response data for continuous processing.
6. The service speed based provider selection method as claimed in claim 1, wherein said calculating an interval time between sending said get service request and receiving said response data resulting in a response time comprises:
extracting a start timestamp and a corresponding response timestamp from a leaf node in the B + tree;
and calculating according to the starting time stamp and the response time stamp to obtain the response time.
7. The service speed-based provider selection method as claimed in claim 1, wherein said selecting a service for the provider according to the average response time and preset provider selection rules comprises:
traversing the average response time of each supplier, and deleting the average response time larger than a preset threshold and the corresponding suppliers;
carrying out reciprocal change on the average response time of the rest suppliers to obtain the reciprocal of the average response time;
carrying out rounding comparison on the inverses, and determining the proportion weight of each supplier in the rest suppliers;
and selecting the service of the supplier according to the proportion weight.
8. A service speed based vendor selection apparatus, comprising:
the service request sending module is used for constructing a sliding time window, configuring the time dimension of the sliding time window and sending a service acquisition request to a server of a supplier meeting the preset service requirement according to the time dimension;
an average response time calculation module, configured to receive response data sent by the provider server according to the service acquisition request, calculate an interval time between sending the service acquisition request and receiving the response data, obtain response times, select a maximum response time and a minimum response time from the response times, and calculate an average response time according to the maximum response time and the minimum response time;
and the supplier selection module is used for selecting the service of the supplier according to the average response time and a preset supplier selection rule.
9. An electronic device, characterized in that the electronic device comprises:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores computer program instructions executable by the at least one processor to enable the at least one processor to perform the service speed based provider selection method of any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the service speed based provider selection method according to any one of claims 1 to 7.
CN202111544155.8A 2021-12-16 2021-12-16 Service speed-based provider selection method, device, equipment and storage medium Pending CN114240459A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111544155.8A CN114240459A (en) 2021-12-16 2021-12-16 Service speed-based provider selection method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111544155.8A CN114240459A (en) 2021-12-16 2021-12-16 Service speed-based provider selection method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114240459A true CN114240459A (en) 2022-03-25

Family

ID=80757122

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111544155.8A Pending CN114240459A (en) 2021-12-16 2021-12-16 Service speed-based provider selection method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114240459A (en)

Similar Documents

Publication Publication Date Title
CN112148577A (en) Data anomaly detection method and device, electronic equipment and storage medium
CN112052370A (en) Message generation method and device, electronic equipment and computer readable storage medium
CN113807553A (en) Method, device, equipment and storage medium for analyzing number of reservation services
CN114881616A (en) Business process execution method and device, electronic equipment and storage medium
CN113868528A (en) Information recommendation method and device, electronic equipment and readable storage medium
CN113890712A (en) Data transmission method and device, electronic equipment and readable storage medium
CN114612194A (en) Product recommendation method and device, electronic equipment and storage medium
CN114844844A (en) Delay message processing method, device, equipment and storage medium
CN112948380A (en) Data storage method and device based on big data, electronic equipment and storage medium
CN111985194A (en) Data storage method and device, electronic equipment and storage medium
CN112541688A (en) Service data checking method and device, electronic equipment and computer storage medium
CN114240459A (en) Service speed-based provider selection method, device, equipment and storage medium
CN115759746A (en) Configurable user early warning method and device, electronic equipment and storage medium
CN114626948A (en) Block chain transaction accounting method and device, electronic equipment and storage medium
CN114911479A (en) Interface generation method, device, equipment and storage medium based on configuration
CN114820132A (en) Order distribution method and device, electronic equipment and storage medium
CN114490137A (en) Service data real-time statistical method and device, electronic equipment and readable storage medium
CN113657546A (en) Information classification method and device, electronic equipment and readable storage medium
CN113469649A (en) Project progress analysis method and device, electronic equipment and storage medium
CN113449002A (en) Vehicle recommendation method and device, electronic equipment and storage medium
CN113377857A (en) Data distribution method and device, electronic equipment and readable storage medium
CN115225489B (en) Dynamic control method for queue service flow threshold, electronic equipment and storage medium
CN116701233B (en) Transaction system testing method, equipment and medium based on high concurrency report simulation
CN115659026A (en) Client recommendation method and device, electronic equipment and storage medium
CN114598624A (en) Cluster monitoring method and device, electronic equipment and 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