Live broadcast request processing method, device, electronic device and storage medium
By using cached risk control list and historical access data in the live broadcast request processing for risk identification and directly returning risk control prompt information, the problem of degradation in the performance of business modules under illegal requests is solved, and the stability and response speed of the system are improved.
Patent Information
- Application Number
- CN202210504286.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-10
- Publication Date
- 2024-12-31
- Estimated Expiration
- 2042-05-10
AI Technical Summary
Under a large number of illegal requests, the performance of the business module is seriously affected, resulting in a decrease in server stability and response time.
By obtaining live access requests for user accounts, using cached risk control lists and historical access data to determine access statistical parameters, risk identification is performed when the threshold is reached, and the risk control list is updated, and the risk control prompt information is directly returned instead of business processing, reducing Server load.
It improves the accuracy of risk identification and business processing performance, reduces server time-consuming and improves system stability.
Smart Images

Figure CN114697698B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of Internet technology, and in particular to a live broadcast request processing method, device, electronic device, computer-readable storage medium, and computer program product. Background Art
[0002] With the rapid development of Internet technology, live streaming has become a new form of interaction and has been integrated into various fields such as e-commerce, games, and entertainment.
[0003] In related technologies, in order to curb illegal requests from users, the risk control module is generally connected to the interface layer of the live broadcast square. When the request arrives, the business module of the interface layer processes the business logic, and the risk control module asynchronously performs risk control identification. The interface layer returns an error code or the result of the business logic processing based on the risk control identification result. For example, if the risk control identification result is an illegal request, the interface layer returns an error code. If the risk control identification result is a legal request, the interface layer returns the result of the business logic processing.
[0004] However, since the business module and the risk control module process requests asynchronously at the same time, the business module will perform business logic processing for each request as soon as possible, which will seriously affect the performance of the business module under a large number of illegal requests. Summary of the invention
[0005] The present disclosure provides a live broadcast request processing method, device, electronic device, computer-readable storage medium and computer program product to at least solve the problem in the related art that a large number of illegal requests seriously affect the service processing performance. The technical solution of the present disclosure is as follows:
[0006] According to a first aspect of an embodiment of the present disclosure, a method for processing a live broadcast request is provided, including:
[0007] Obtaining a live broadcast access request of a user account, wherein the live broadcast access request carries a corresponding request identifier, wherein the request identifier includes at least one of an account identifier of the user account and a page identifier of a target live broadcast page, wherein the target live broadcast page is a page requested to be accessed by the live broadcast access request;
[0008] When the request identifier does not exist in the cached risk control list, determining the access statistical parameters corresponding to the live broadcast access request according to the historical access data;
[0009] When the access statistical parameter reaches a corresponding parameter threshold, performing a first risk identification on the live broadcast access request to obtain a corresponding first risk identification result;
[0010] When the first risk identification result is that there is a risk, the risk control list is updated according to the request identifier corresponding to the live broadcast access request, and risk control prompt information is returned to the user account.
[0011] In one of the embodiments, the method further includes: when the request identifier exists in the cached risk control list, returning the risk control prompt information to the user account.
[0012] In one of the embodiments, the method further includes: when the access statistical parameter does not reach the corresponding parameter threshold, performing corresponding logical processing on the live access request; obtaining processed data after the logical processing of the live access request, and returning the processed data to the user account, wherein the processed data is used to characterize the access data corresponding to the live access request.
[0013] In one of the embodiments, the method further includes: when the first risk identification result is that there is no risk, performing a second risk identification on the live broadcast access request and obtaining a corresponding second risk identification result; when the second risk identification result is that there is a risk, returning the risk control prompt information to the user account.
[0014] In one of the embodiments, the method also includes: when the second risk identification result is that there is no risk, performing corresponding logical processing on the live broadcast access request; obtaining processed data after logical processing of the live broadcast access request, and returning the processed data to the user account, wherein the processed data is used to characterize the access data corresponding to the live broadcast access request.
[0015] In one of the embodiments, the access statistical parameters corresponding to the live access request include at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the result within the corresponding period; determining the access statistical parameters corresponding to the live access request based on historical access data includes: obtaining the historical access requests of the user account, the corresponding request time and the return result, the return result including any one of the risk control prompt information and processing data returned according to the historical access request; counting the number of requests of the user account based on different time periods according to the historical access requests of the user account, the corresponding request time and the live access request; obtaining the return result of each historical access request corresponding to the number of requests as the number of risk control prompt information; taking at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the result within the corresponding period as the corresponding access statistical parameter.
[0016] In one of the embodiments, the access statistical parameters corresponding to the live broadcast access request include at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as the result within the corresponding period; determining the access statistical parameters corresponding to the live broadcast access request based on historical access data includes: obtaining the historical access requests, corresponding request time and return results of the target live broadcast page, the return results including any one of risk control prompt information and processing data returned according to the historical access requests of the target live broadcast page; counting the number of requests for the target live broadcast page based on different time periods according to the historical access requests and corresponding request time of the target live broadcast page and the live broadcast access request; obtaining the return result of each historical access request corresponding to the requested number as the number of risk control prompt information; taking at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as the result within the corresponding period as the corresponding access statistical parameters.
[0017] In one of the embodiments, updating the risk control list according to the request identifier corresponding to the live access request includes: adding the request identifier corresponding to the live access request to the cached risk control list to update the risk control list.
[0018] In one embodiment, the cached risk control list includes a cached account identification list, and the method further includes: when the account identification of the user account does not exist in the cached account identification list, determining that the request identification does not exist in the cached risk control list.
[0019] In one embodiment, the cached risk control list includes a cached page identifier list, and the method further includes: when the page identifier of the target live broadcast page does not exist in the cached page identifier list, determining that the request identifier does not exist in the cached risk control list.
[0020] According to a second aspect of an embodiment of the present disclosure, a live broadcast request processing device is provided, the device comprising:
[0021] a request acquisition module, configured to execute a live broadcast access request for acquiring a user account, wherein the live broadcast access request carries a corresponding request identifier, wherein the request identifier includes at least one of an account identifier of the user account and a page identifier of a target live broadcast page, wherein the target live broadcast page is a page requested to be accessed by the live broadcast access request;
[0022] an access statistical parameter determination module, configured to determine the access statistical parameter corresponding to the live access request according to the historical access data when the request identifier does not exist in the cached risk control list;
[0023] A first risk identification module is configured to perform a first risk identification on the live broadcast access request when the access statistical parameter reaches a corresponding parameter threshold, and obtain a corresponding first risk identification result;
[0024] The request processing module is configured to execute, when the first risk identification result is that there is a risk, updating the risk control list according to the request identifier corresponding to the live broadcast access request, and returning risk control prompt information to the user account.
[0025] In one of the embodiments, the request processing module is further configured to execute: when the request identifier exists in the cached risk control list, return the risk control prompt information to the user account.
[0026] In one of the embodiments, the request processing module is further configured to execute: when the access statistical parameter does not reach the corresponding parameter threshold, performing corresponding logical processing on the live access request; obtaining processed data after logical processing of the live access request, and returning the processed data to the user account, wherein the processed data is used to characterize the access data corresponding to the live access request.
[0027] In one embodiment, the device also includes a first risk identification module, which is configured to execute: when the first risk identification result is that there is no risk, performing a second risk identification on the live broadcast access request and obtaining a corresponding second risk identification result; when the second risk identification result is that there is a risk, returning the risk control prompt information to the user account.
[0028] In one of the embodiments, the request processing module is further configured to execute: when the second risk identification result is that there is no risk, performing corresponding logical processing on the live broadcast access request; obtaining processed data after logical processing of the live broadcast access request, and returning the processed data to the user account, wherein the processed data is used to characterize the access data corresponding to the live broadcast access request.
[0029] In one of the embodiments, the access statistical parameters corresponding to the live access request include at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the result within the corresponding period; the access statistical parameter determination module is configured to execute: obtaining the historical access requests of the user account, the corresponding request time and the return result, the return result including any one of the risk control prompt information and processing data returned according to the historical access request; counting the number of requests of the user account based on different time periods according to the historical access requests of the user account, the corresponding request time and the live access request; obtaining the return result of each historical access request corresponding to the number of requests as the number of risk control prompt information; taking at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the result within the corresponding period as the corresponding access statistical parameter.
[0030] In one of the embodiments, the access statistical parameters corresponding to the live broadcast access request include at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as the result within the corresponding period; the access statistical parameter determination module is configured to execute: obtaining the historical access requests, corresponding request time and return results of the target live broadcast page, the return results including any one of the risk control prompt information and processing data returned according to the historical access requests of the target live broadcast page; counting the number of requests for the target live broadcast page based on different time periods according to the historical access requests and corresponding request time of the target live broadcast page and the live broadcast access request; obtaining the return result of each historical access request corresponding to the requested number as the number of risk control prompt information; taking at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as the result within the corresponding period as the corresponding access statistical parameter.
[0031] In one of the embodiments, the request processing module is further configured to execute: adding the request identifier corresponding to the live broadcast access request to the cached risk control list to update the risk control list.
[0032] In one of the embodiments, the cached risk control list includes a cached account identification list; the request processing module is also configured to execute: when the account identification of the user account does not exist in the cached account identification list, it is determined that the request identification does not exist in the cached risk control list.
[0033] In one of the embodiments, the cached risk control list includes a cached page identification list; the request processing module is also configured to execute: when the page identification of the target live broadcast page does not exist in the cached page identification list, it is determined that the request identification does not exist in the cached risk control list.
[0034] According to a third aspect of an embodiment of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing instructions executable by the processor; wherein the processor is configured to execute the instructions to implement the live broadcast request processing method as described in the first aspect above.
[0035] According to a fourth aspect of an embodiment of the present disclosure, a computer-readable storage medium is provided. When instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the live broadcast request processing method described in the first aspect above.
[0036] According to a fifth aspect of an embodiment of the present disclosure, a computer program product is provided, wherein the computer program product includes instructions, and when the instructions are executed by a processor of an electronic device, the electronic device is enabled to execute the live broadcast request processing method as described in the first aspect above.
[0037] The technical solution provided by the embodiments of the present disclosure brings at least the following beneficial effects: by obtaining a live broadcast access request carrying a request identifier of a user account, when the request identifier does not exist in the cached risk control list, the access statistical parameters corresponding to the live broadcast access request are determined according to the historical access data, and when the access statistical parameters reach the corresponding parameter threshold, the live broadcast access request is subjected to a first risk identification, and the corresponding first risk identification result is obtained, and when the first risk identification result is that there is a risk, the risk control list is updated according to the request identifier corresponding to the live broadcast access request, and the risk control prompt information is returned to the user account. Since the risk control list is stored in the cache, processing the request based on the cached risk control list can greatly reduce the time consumption of the server; in addition, for requests that are not in the risk control list, the identification results of the strategy and the risk control identification results are comprehensively considered for subsequent processing, thereby improving the accuracy of risk identification; in addition, for requests that are ultimately determined to be at risk, the risk prompt information is directly returned without performing business processing, thereby improving the performance of business processing and being beneficial to the stability of the server.
[0038] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] The drawings herein are incorporated into and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the description are used to explain the principles of the present disclosure, and do not constitute improper limitations on the present disclosure.
[0040] Figure 1 The present invention is an application environment diagram of a live broadcast request processing method according to an exemplary embodiment.
[0041] Figure 2 The figure is a flowchart of a method for processing a live broadcast request according to an exemplary embodiment.
[0042] Figure 3 The figure is a flowchart of a method for processing a live broadcast request according to another exemplary embodiment.
[0043] Figure 4 The figure is a schematic diagram of steps for determining access statistical parameters according to an exemplary embodiment.
[0044] Figure 5 The figure is a schematic diagram of steps for determining access statistical parameters according to another exemplary embodiment.
[0045] Figure 6 The figure is a block diagram of a device for processing a live broadcast request according to an exemplary embodiment.
[0046] Figure 7 It is a block diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION
[0047] In order to enable ordinary persons in the art to better understand the technical solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings.
[0048] It should be noted that the terms "first", "second", etc. in the specification and claims of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present disclosure described herein can be implemented in an order other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.
[0049] It should also be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for display, data for analysis, etc.) involved in this disclosure are all information and data authorized by the user or fully authorized by all parties.
[0050] Since the business module and the risk control module in traditional technology process requests asynchronously at the same time, the business module will immediately process the business logic for each request. Even if the request is intercepted by the risk control module, the business module still needs to process it. Users are also very sensitive to the time it takes for the interface to respond, and the risk control judgment logic is relatively complex and has poor stability. Therefore, if risk control is requested synchronously, it will bring a relatively large stability risk to the interface.
[0051] Based on this, the present disclosure provides a live broadcast request processing method, which can be applied to Figure 1 In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network. The data storage system can store the data that the server 104 needs to process. The data storage system can be integrated on the server 104, or it can be placed on the cloud or other network servers. Among them, the terminal 102 can be but is not limited to various personal computers, laptops, smart phones, tablets, Internet of Things devices and portable wearable devices. The Internet of Things devices can be smart speakers, smart TVs, smart air conditioners, smart car-mounted devices, etc. Portable wearable devices can be smart watches, smart bracelets, head-mounted devices, etc. The server 104 can be implemented with an independent server or a server cluster consisting of multiple servers. Specifically, a live broadcast application is installed in the terminal 102, and the server 104 is the background server of the live broadcast application.
[0052] Figure 2 is a flowchart of a method for processing a live broadcast request according to an exemplary embodiment. Figure 2 As shown, this method is applied to Figure 1 Taking the server in as an example, the following steps are included.
[0053] In step S210, a live broadcast access request of a user account is obtained.
[0054] The live broadcast access request is a request from a user account to access a target live broadcast page, the target live broadcast page is the live broadcast page requested to be accessed by the live broadcast access request, and the live broadcast page is the page currently being broadcast in the live broadcast application. Specifically, the live broadcast access request carries a corresponding request identifier, and the request identifier includes at least one of an account identifier of the user account and a page identifier of the target live broadcast page.
[0055] In this embodiment, when a user account wants to access a live page in a live application, a live access request to the live page is initiated through the terminal. Usually, in order to facilitate back-end processing, the live access request can carry a corresponding request identifier. The server obtains the corresponding live access request and performs subsequent processing according to the request identifier carried in the live access request.
[0056] In step S220, when the request identifier does not exist in the cached risk control list, the access statistical parameters corresponding to the live broadcast access request are determined according to the historical access data.
[0057] Among them, the risk control list is a high-risk blacklist pre-set based on risk management, including but not limited to a blacklist based on user accounts and a blacklist based on live pages. Specifically, the blacklist based on user accounts refers to a list of account identifiers corresponding to user accounts, and the blacklist based on live pages refers to a list of page identifiers corresponding to live pages. In this embodiment, the risk control list is stored in a cache. Specifically, the cache can be Redis (Remote Dictionary Server), i.e., a remote dictionary service, which is an open source, high-performance Key-Value database.
[0058] The historical access data includes, but is not limited to, the historical access data corresponding to the account ID of the user account currently requesting, and the historical access data corresponding to the page ID of the target live page currently requesting. Specifically, the historical access data corresponding to the account ID of the user account currently requesting refers to all historical access requests of the user account currently requesting, and the historical access data corresponding to the page ID of the target live page currently requesting refers to the historical data of the target live page currently requesting being accessed.
[0059] The access statistics parameters are statistical indicators obtained by counting historical access data according to certain statistical rules. For example, it can be the number of requests within the corresponding time dimension based on different time dimensions, such as the number of requests initiated by the user account of the current request in the last minute, or the number of requests initiated in the last day; or it can be the number of times the target live page of the current request has been visited in the last minute, or the number of times it has been visited in the last day, etc.
[0060] In this embodiment, the server determines whether there is a request identifier corresponding to the live access request in the cached risk control list based on the live access request obtained above, that is, determines whether the request identifier corresponding to the live access request exists in the pre-set blacklist, that is, preliminarily determines whether there is a risk in the current live access request. When it is determined that there is no request identifier corresponding to the live access request in the cached risk control list, it means that it can be preliminarily determined that there is no risk in the current live access request. Therefore, the access statistical parameters corresponding to the live access request are further determined based on the historical access data, and further risk control processing is performed based on subsequent steps.
[0061] In step S230, when the access statistical parameter reaches the corresponding parameter threshold, a first risk identification is performed on the live access request to obtain a corresponding first risk identification result.
[0062] Among them, the parameter threshold is a threshold for corresponding risk identification that is pre-configured based on a certain risk control strategy. For example, different parameter thresholds can be set based on different statistical indicators under different time dimensions. Therefore, a corresponding parameter threshold can be pre-configured for each access statistical parameter. When the access statistical parameter reaches the corresponding parameter threshold, for example, if the number of requests initiated by the user account of the current request within the last minute reaches the corresponding number threshold, it means that the corresponding live access request may be risky. Therefore, it is necessary to further identify the risk of the live access request, that is, to perform a first risk identification on the live access request to obtain the corresponding first risk identification result.
[0063] Specifically, the first risk identification can be implemented by calling a dedicated risk control module, and the first risk identification result is a result of whether the live broadcast access request has a risk after performing the first risk identification on the live broadcast access request.
[0064] In step S240, when the first risk identification result is that there is a risk, the risk control list is updated according to the request identifier corresponding to the live broadcast access request, and risk control prompt information is returned to the user account.
[0065] Among them, the risk control prompt information is used to prompt the user account that the live broadcast access request currently initiated is at risk, which can be a text prompt, voice prompt or other prompt.
[0066] Specifically, when the first risk identification result obtained after the first risk identification of the live access request through the above steps is that the live access request is at risk, it means that the identification result of the first risk identification is consistent with the identification result of the above risk control strategy, and therefore, it can be determined that the live access request is indeed at risk. Thus, the risk control prompt information is returned to the corresponding user account to prompt the user account that the live access request currently initiated is at risk. At the same time, the server can also update the risk control list according to the request identifier of the live access request currently identified as having risk, for example, adding the request identifier of the live access request having risk to the risk control list, thereby updating the risk control list.
[0067] In the above live broadcast request processing method, by obtaining the live broadcast access request carrying the request identifier of the user account, when the request identifier does not exist in the cached risk control list, the access statistical parameters corresponding to the live broadcast access request are determined according to the historical access data, and when the access statistical parameters reach the corresponding parameter threshold, the live broadcast access request is subjected to the first risk identification, and the corresponding first risk identification result is obtained. When the first risk identification result is that there is a risk, the risk control list is updated according to the request identifier corresponding to the live broadcast access request, and the risk control prompt information is returned to the user account. Since the risk control list is stored in the cache, processing the request based on the cached risk control list can greatly reduce the time consumption of the server; in addition, for requests that are not in the risk control list, the identification results of the strategy and the risk control identification results are comprehensively considered for subsequent processing, thereby improving the accuracy of risk identification; in addition, for requests that are ultimately determined to be at risk, the risk prompt information is directly returned without performing business processing, thereby improving the performance of business processing and being beneficial to the stability of the server.
[0068] In an exemplary embodiment, if Figure 3 As shown, the live broadcast request processing method includes the following steps:
[0069] In step S302, a live broadcast access request of a user account is obtained.
[0070] The live broadcast access request carries a corresponding request identifier, and the request identifier includes at least one of an account identifier of a user account and a page identifier of a target live broadcast page.
[0071] Specifically, in this embodiment, the server monitors the live access request initiated by the user account. When the live access request initiated by the user account is monitored, the server stores the message based on Kafka (a high-throughput distributed publish-subscribe message system) on the one hand, and sequentially executes the subsequent steps to process the request on the other hand. Since Kafka has the characteristic of partitioned storage of messages, the messages can be partitioned and stored based on different risk control strategies. For example, requests with the same account identifier can be stored in the same partition based on the account identifiers of different user accounts; or requests with the same page identifier can be stored in the same partition based on different page identifiers, which is conducive to the statistics of messages.
[0072] In step S304, it is identified whether there is a request identifier corresponding to the live broadcast access request in the cached risk control list.
[0073] When the cached risk control list contains a request identifier corresponding to the live broadcast access request, step S306 is executed; when the cached risk control list contains no request identifier corresponding to the live broadcast access request, step S308 is executed.
[0074] In step S306, risk control prompt information is returned to the user account.
[0075] When there is a request identifier in the cached risk control list, it means that the current live access request is in the inaccessible blacklist, that is, the current live access request is a risky request. Therefore, the risk control prompt information is directly returned to the user account, and no business processing is performed to improve the performance of business processing.
[0076] In step S308, access statistical parameters corresponding to the live broadcast access request are determined according to the historical access data.
[0077] When there is no request identifier in the cached risk control list, it means that the current live access request is not in the inaccessible blacklist, but at this time it is impossible to determine whether the live access request is risky. Therefore, the access statistical parameters corresponding to the live access request are further determined based on the historical access data, so as to judge whether the live access request is risky according to the preset risk control strategy.
[0078] In step S310, it is identified whether the access statistical parameter reaches the corresponding parameter threshold.
[0079] When the access statistical parameter reaches the corresponding parameter threshold, step S312 is executed, and when the access statistical parameter does not reach the corresponding parameter threshold, step S322 is executed.
[0080] In step S312, a first risk identification is performed on the live broadcast access request to obtain a corresponding first risk identification result.
[0081] When the access statistical parameter reaches the corresponding parameter threshold, it indicates that the corresponding live access request may have risks. Therefore, it is necessary to further identify the risks of the live access request, that is, to perform a first risk identification on the live access request to obtain a corresponding first risk identification result.
[0082] In step S314, it is identified whether the first risk identification result is a result indicating the existence of risk.
[0083] When the first risk identification result is a result that there is a risk, step S316 is executed, and when the first risk identification result is a result that there is no risk, step S318 is executed.
[0084] In step S316, the risk control list is updated according to the request identifier corresponding to the live broadcast access request.
[0085] When the first risk identification result is a result that there is a risk, it means that the identification result of the first risk identification is consistent with the identification result of the above-mentioned risk control strategy. Therefore, it can be determined that the live broadcast access request does have a risk. The risk control list is updated according to the request identifier corresponding to the live broadcast access request, and returns to step S306 to return the risk control prompt information to the user account.
[0086] In step S318, a second risk identification is performed on the live broadcast access request, and a corresponding second risk identification result is obtained.
[0087] When the first risk identification result is a result that there is no risk, it means that the identification result of the first risk identification is inconsistent with the identification result of the above risk control strategy. Therefore, it is necessary to perform a second risk identification on the live access request to obtain a corresponding second risk identification result. This embodiment corrects the inconsistency of the above identification results based on the second risk identification result, which is conducive to improving the accuracy of risk identification.
[0088] In step S320, it is identified whether the second risk identification result is a result indicating the presence of risk.
[0089] When the second risk identification result is a result that there is a risk, it can be determined that the live access request does have a risk, so step S316 is executed to update the risk control list according to the request identifier corresponding to the live access request, and return to step S306 to return the risk control prompt information to the user account. If the second risk identification result is a result that there is no risk, step S322 is executed.
[0090] In step S322, corresponding logic processing is performed on the live broadcast access request to obtain processed data after the logic processing, and the processed data is returned to the user account.
[0091] The processing data is used to characterize the access data corresponding to the live access request. Specifically, this embodiment performs corresponding logic processing only when it is finally determined that the live access request does not have risks, and for the request that is finally determined to have risks, the risk warning information is directly returned without performing business processing, thereby improving the performance of business processing and facilitating the stability of the server.
[0092] In an exemplary embodiment, the access statistics parameter corresponding to the live access request includes at least one of the number of requests from the user account based on different time periods and the number of risk control prompt information returned in the corresponding period. Figure 4 As shown, in step S220, the access statistical parameters corresponding to the live access request are determined according to the historical access data, which may specifically include:
[0093] In step S410, historical access requests of the user account, corresponding request times and return results are obtained.
[0094] Among them, the returned result includes any one of the risk control prompt information and processing data returned according to the historical access request. Specifically, based on the above embodiment, it can be known that for an access request, when it is determined that there is no risk, the processing data obtained after logical processing of the access request is usually returned, and when it is determined that there is a risk, the corresponding risk control prompt information is returned. Therefore, for each historical access request of the user account, the corresponding return result is either the risk control prompt information or the processing data obtained after logical processing. In this embodiment, the historical access requests of the user account, the corresponding request time and the return result are obtained based on the user level.
[0095] In step S420, the number of requests of the user account based on different time periods is counted according to the historical access requests of the user account, the corresponding request time and the live broadcast access requests.
[0096] The time period refers to the time range for statistics, for example, the time period can be by minute, by hour, by day, etc. Specifically, if the time period is by minute, the number of requests initiated by the user account in the last minute can be counted, and if the time period is by day, the number of requests initiated by the user account in the last day can be counted. It can be understood that the number of statistics can include the current live broadcast access request.
[0097] In step S430, the return result of each historical access request corresponding to the request quantity is obtained as the quantity of risk control prompt information.
[0098] Since the corresponding return result for each historical access request of the user account is either risk control prompt information or processed data obtained after logical processing, the number of risk control prompt information returned in all historical requests of the user account within the above time period can be further counted.
[0099] In step S440, at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as a result in the corresponding period is used as a corresponding access statistical parameter.
[0100] Specifically, in this embodiment, at least one of the number of requests of user accounts based on different time periods and the number of risk control prompt information returned as results in the corresponding period can be used as the corresponding access statistical parameter.
[0101] In the above embodiment, by obtaining the historical access requests of the user account, the corresponding request time and the return result, according to the historical access requests of the user account, the corresponding request time and the live access request, the number of requests of the user account based on different time periods is counted, and the number of risk control prompt information returned as the result of each historical access request corresponding to the number of requests is obtained, and at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the result in the corresponding period is used as the corresponding access statistical parameter. Therefore, different risk control strategies can be configured based on the access statistical parameters of different dimensions to realize multi-dimensional risk control strategy control.
[0102] In an exemplary embodiment, the access statistical parameter corresponding to the live broadcast access request includes at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned in the corresponding period; Figure 5 As shown, in step S220, the access statistical parameters corresponding to the live access request are determined according to the historical access data, which may specifically include:
[0103] In step S510, the historical access requests, corresponding request times and return results of the target live broadcast page are obtained.
[0104] The returned result includes any one of the risk control prompt information and processing data returned according to the historical access requests of the target live broadcast page.
[0105] Similarly, for the access request of the live page, when it is determined that there is no risk, the processing data obtained after the logical processing of the access request is usually returned, and when it is determined that there is a risk, the corresponding risk control prompt information is returned. Therefore, for each historical access request of the target live page, the corresponding return result is either the risk control prompt information or the processing data obtained after the logical processing. In this embodiment, the historical access request of the target live page, the corresponding request time and the return result are obtained based on the live page level.
[0106] In step S520, the number of requests for the target live page based on different time periods is counted according to the historical access requests of the target live page and the corresponding request time and the live access requests.
[0107] The time period refers to the time range for statistics, for example, the time period can be by minute, by hour, by day, etc. Specifically, if the time period is by minute, the number of requests for the target live page in the last minute can be counted, and if the time period is by day, the number of requests for the target live page in the last day can be counted. It is understandable that the number of statistics can include the current live access request to the target live page.
[0108] In step S530, the number of risk control prompt information returned as a result of each historical access request corresponding to the requested number is obtained.
[0109] Since the corresponding return result for each historical access request of the target live page is either risk control prompt information or processed data obtained after logical processing, the number of risk control prompt information returned in all historical requests of the target live page within the above time period can be further counted.
[0110] In step S540, at least one of the number of requests for the target live page based on different time periods and the number of risk control prompt information returned as a result in the corresponding period is used as a corresponding access statistical parameter.
[0111] Specifically, in this embodiment, at least one of the number of requests for the target live page based on different time periods and the number of risk control prompt information returned as a result in the corresponding period can be used as the corresponding access statistical parameter.
[0112] In the above embodiment, by obtaining the historical access requests, corresponding request time and return results of the target live page, according to the historical access requests, corresponding request time and live access requests of the target live page, the number of requests for the target live page based on different time periods is counted, and the number of risk control prompt information returned as the result of each historical access request corresponding to the requested number is obtained, and at least one of the number of requests for the target live page based on different time periods and the number of risk control prompt information returned as the result in the corresponding period is used as the corresponding access statistical parameter. Therefore, different risk control strategies can be configured based on access statistical parameters of different dimensions to achieve multi-dimensional risk control strategy control.
[0113] In an exemplary embodiment, in step S240, updating the risk control list according to the request identifier corresponding to the live access request includes: adding the request identifier corresponding to the live access request to the cached risk control list to update the risk control list. Specifically, the risk control list is updated by adding the request identifier of the live access request identified as having risks to the risk control list. Therefore, when a request corresponding to the request identifier is received again, the risk control prompt information can be directly returned, so that no business processing is performed, so as to further improve the performance of business processing.
[0114] In an exemplary embodiment, the cached risk control list includes a cached account identification list, and the above method further includes: when the account identification of the user account does not exist in the cached account identification list, it is determined that the request identification does not exist in the cached risk control list. When the account identification of the user account exists in the cached account identification list, it is determined that the request identification exists in the cached risk control list. Then, the corresponding strategy is processed to realize risk control identification from the user level and improve the flexibility of risk control identification.
[0115] In an exemplary embodiment, the cached risk control list includes a cached page identifier list, and the above method further includes: when the page identifier of the target live page does not exist in the cached page identifier list, it is determined that there is no request identifier in the cached risk control list. When the page identifier of the target live page exists in the cached page identifier list, it is determined that there is a request identifier in the cached risk control list. Then, processing is performed according to the corresponding strategy to realize risk control identification at the page level, so as to improve the flexibility and diversity of risk control identification.
[0116] It should be understood that although Figure 1-Figure 5 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1-Figure 5 At least part of the steps may include multiple steps or multiple stages. These steps or stages are not necessarily performed at the same time, but can be performed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed in turn or alternately with other steps or at least part of the steps or stages in other steps.
[0117] It can be understood that the same / similar parts between the various embodiments of the above method in this specification can refer to each other, and each embodiment focuses on the differences from other embodiments. For related points, please refer to the description of other method embodiments.
[0118] Figure 6 FIG. 1 is a block diagram of a live broadcast request processing device according to an exemplary embodiment. Figure 6 The device includes a request acquisition module 602 , an access statistical parameter determination module 604 , a first risk identification module 606 and a request processing module 608 .
[0119] The request acquisition module 602 is configured to execute a live broadcast access request for acquiring a user account, wherein the live broadcast access request carries a corresponding request identifier, and the request identifier includes at least one of an account identifier of the user account and a page identifier of a target live broadcast page, and the target live broadcast page is the page requested to be accessed by the live broadcast access request;
[0120] The access statistical parameter determination module 604 is configured to determine the access statistical parameter corresponding to the live access request according to the historical access data when the request identifier does not exist in the cached risk control list;
[0121] The first risk identification module 606 is configured to perform a first risk identification on the live broadcast access request when the access statistical parameter reaches a corresponding parameter threshold, and obtain a corresponding first risk identification result;
[0122] The request processing module 608 is configured to execute, when the first risk identification result is that there is a risk, updating the risk control list according to the request identifier corresponding to the live broadcast access request, and returning risk control prompt information to the user account.
[0123] In an exemplary embodiment, the request processing module is further configured to execute: when the request identifier exists in the cached risk control list, return the risk control prompt information to the user account.
[0124] In an exemplary embodiment, the request processing module is further configured to execute: when the access statistical parameter does not reach the corresponding parameter threshold, performing corresponding logical processing on the live access request; obtaining processed data after logical processing of the live access request, and returning the processed data to the user account, wherein the processed data is used to characterize the access data corresponding to the live access request.
[0125] In an exemplary embodiment, the device also includes a first risk identification module, which is configured to execute: when the first risk identification result is that there is no risk, performing a second risk identification on the live broadcast access request and obtaining a corresponding second risk identification result; when the second risk identification result is that there is a risk, returning the risk control prompt information to the user account.
[0126] In an exemplary embodiment, the request processing module is also configured to execute: when the second risk identification result is that there is no risk, performing corresponding logical processing on the live broadcast access request; obtaining processed data after logical processing of the live broadcast access request, and returning the processed data to the user account, wherein the processed data is used to characterize the access data corresponding to the live broadcast access request.
[0127] In an exemplary embodiment, the access statistical parameters corresponding to the live access request include at least one of the number of requests from the user account based on different time periods and the number of risk control prompt information returned as the result within the corresponding period; the access statistical parameter determination module is configured to execute: obtaining the historical access requests of the user account, the corresponding request time and the return result, the return result including any one of the risk control prompt information and processing data returned according to the historical access request; counting the number of requests from the user account based on different time periods according to the historical access requests of the user account, the corresponding request time and the live access request; obtaining the return result of each historical access request corresponding to the number of requests as the number of risk control prompt information; taking at least one of the number of requests from the user account based on different time periods and the number of risk control prompt information returned as the result within the corresponding period as the corresponding access statistical parameter.
[0128] In an exemplary embodiment, the access statistical parameters corresponding to the live broadcast access request include at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as the result within the corresponding period; the access statistical parameter determination module is configured to execute: obtaining the historical access requests, corresponding request time and return results of the target live broadcast page, the return results including any one of the risk control prompt information and processing data returned according to the historical access requests of the target live broadcast page; counting the number of requests for the target live broadcast page based on different time periods according to the historical access requests and corresponding request time of the target live broadcast page and the live broadcast access request; obtaining the return result of each historical access request corresponding to the requested number as the number of risk control prompt information; taking at least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as the result within the corresponding period as the corresponding access statistical parameter.
[0129] In an exemplary embodiment, the request processing module is further configured to execute: adding the request identifier corresponding to the live broadcast access request to the cached risk control list to update the risk control list.
[0130] In an exemplary embodiment, the cached risk control list includes a cached account identification list; the request processing module is also configured to execute: when the account identification of the user account does not exist in the cached account identification list, it is determined that the request identification does not exist in the cached risk control list.
[0131] In an exemplary embodiment, the cached risk control list includes a cached page identification list; the request processing module is also configured to execute: when the page identification of the target live broadcast page does not exist in the cached page identification list, it is determined that the request identification does not exist in the cached risk control list.
[0132] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0133] Figure 7 FIG. 1 is a block diagram of an electronic device S00 for processing a live broadcast request according to an exemplary embodiment. For example, the electronic device S00 may be a server. Figure 7 The electronic device S00 includes a processing component S20, which further includes one or more processors, and a memory resource represented by a memory S22 for storing instructions executable by the processing component S20, such as an application. The application stored in the memory S22 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component S20 is configured to execute the instructions to perform the above method.
[0134] The electronic device S00 may further include: a power supply component S24 configured to perform power management of the electronic device S00, a wired or wireless network interface S26 configured to connect the electronic device S00 to a network, and an input / output (I / O) interface S28. The electronic device S00 may operate based on an operating system stored in the memory S22, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD or the like.
[0135] In an exemplary embodiment, a computer-readable storage medium including instructions is also provided, such as a memory S22 including instructions, and the above instructions can be executed by a processor of the electronic device S00 to complete the above method. The storage medium can be a computer-readable storage medium, for example, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0136] In an exemplary embodiment, a computer program product is further provided. The computer program product includes instructions. The instructions can be executed by a processor of the electronic device S00 to complete the above method.
[0137] It should be noted that the above-mentioned devices, electronic devices, computer-readable storage media, computer program products, etc. may also include other implementation methods according to the description of the method embodiments. The specific implementation methods can refer to the description of the relevant method embodiments, which will not be described one by one here.
[0138] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present disclosure are indicated by the claims.
[0139] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Claims
1. A method for processing a live broadcast request, characterized in that: The method comprises: Obtaining a live broadcast access request of a user account, wherein the live broadcast access request carries a corresponding request identifier, wherein the request identifier includes at least one of an account identifier of the user account and a page identifier of a target live broadcast page, wherein the target live broadcast page is a page requested to be accessed by the live broadcast access request; When the request identifier does not exist in the cached risk control list, determining the access statistical parameters corresponding to the live access request according to the historical access data, the access statistical parameters corresponding to the live access request including at least one of the number of requests for the target live page based on different time periods and the number of risk control prompt information returned as a result within the corresponding period, and the returned result is a historical risk identification result returned based on the historical access requests for the target live page; When the access statistical parameter reaches a corresponding parameter threshold, performing a first risk identification on the live broadcast access request to obtain a corresponding first risk identification result; When the first risk identification result is that there is a risk, updating the risk control list according to the request identifier corresponding to the live broadcast access request, and returning risk control prompt information to the user account; When the access statistical parameter does not reach the corresponding parameter threshold, the live access request is subjected to corresponding logical processing; processed data after the logical processing of the live access request is obtained, and the processed data is returned to the user account, wherein the processed data is used to characterize the access data corresponding to the live access request.
2. The method according to claim 1, characterized in that The method further comprises: When the first risk identification result is that there is no risk, performing a second risk identification on the live broadcast access request and obtaining a corresponding second risk identification result; When the second risk identification result is that there is a risk, the risk control prompt information is returned to the user account.
3. The method according to claim 2, characterized in that The method further comprises: When the second risk identification result is that there is no risk, performing corresponding logical processing on the live broadcast access request; Processing data after logical processing of the live broadcast access request is obtained, and the processing data is returned to the user account, where the processing data is used to represent access data corresponding to the live broadcast access request.
4. The method according to any one of claims 1 to 3, characterized in that: The access statistical parameter corresponding to the live access request includes at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as a result within the corresponding period; the access statistical parameter corresponding to the live access request is determined according to the historical access data, including: Obtaining historical access requests, corresponding request times, and return results of the user account, wherein the return results include any one of risk control prompt information and processing data returned according to the historical access requests; According to the historical access requests of the user account, the corresponding request time and the live broadcast access request, counting the number of requests of the user account based on different time periods; The return result of each historical access request corresponding to the request quantity is obtained as the quantity of the risk control prompt information; At least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the results in the corresponding period is used as the corresponding access statistical parameter.
5. The method according to any one of claims 1 to 3, characterized in that: The determining, according to the historical access data, access statistical parameters corresponding to the live access request includes: Obtaining historical access requests, corresponding request times, and return results of the target live page, wherein the return results include any one of risk control prompt information and processing data returned according to historical access requests of the target live page; According to the historical access requests and corresponding request times of the target live page and the live access requests, counting the number of requests for the target live page based on different time periods; Obtaining the number of risk control prompt information for which the return result of each historical access request corresponding to the requested number is the number of risk control prompt information; At least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as results in the corresponding period is used as a corresponding access statistical parameter.
6. The method according to any one of claims 1 to 3, characterized in that: The updating of the risk control list according to the request identifier corresponding to the live broadcast access request includes: The request identifier corresponding to the live broadcast access request is added to the cached risk control list to update the risk control list.
7. The method according to any one of claims 1 to 3, characterized in that: The cached risk control list includes a cached account identification list, and the method further includes: When the account identifier of the user account does not exist in the cached account identifier list, it is determined that the request identifier does not exist in the cached risk control list.
8. The method according to any one of claims 1 to 3, characterized in that: The cached risk control list includes a cached page identification list, and the method further includes: When the page identifier of the target live broadcast page does not exist in the cached page identifier list, it is determined that the request identifier does not exist in the cached risk control list.
9. A live broadcast request processing device, characterized in that: The device comprises: a request acquisition module, configured to execute a live broadcast access request for acquiring a user account, wherein the live broadcast access request carries a corresponding request identifier, wherein the request identifier includes at least one of an account identifier of the user account and a page identifier of a target live broadcast page, wherein the target live broadcast page is a page requested to be accessed by the live broadcast access request; an access statistical parameter determination module, configured to determine, when the request identifier does not exist in the cached risk control list, the access statistical parameter corresponding to the live access request according to historical access data, the access statistical parameter corresponding to the live access request including at least one of the number of requests for the target live page based on different time periods and the number of risk control prompt information returned as a result within the corresponding period, the returned result being a historical risk identification result returned based on historical access requests for the target live page; A first risk identification module is configured to perform a first risk identification on the live broadcast access request when the access statistical parameter reaches a corresponding parameter threshold, and obtain a corresponding first risk identification result; A request processing module, configured to execute, when the first risk identification result is that there is a risk, updating the risk control list according to the request identifier corresponding to the live broadcast access request, and returning risk control prompt information to the user account; The request processing module is also configured to execute: when the access statistical parameter does not reach the corresponding parameter threshold, perform corresponding logical processing on the live access request; obtain processing data after logical processing of the live access request, and return the processing data to the user account, the processing data is used to characterize the access data corresponding to the live access request.
10. The device according to claim 9, characterized in that The device also includes a first risk identification module configured to execute: When the first risk identification result is that there is no risk, performing a second risk identification on the live broadcast access request and obtaining a corresponding second risk identification result; When the second risk identification result is that there is a risk, the risk control prompt information is returned to the user account.
11. The device according to claim 10, characterized in that The request processing module is also configured to perform: When the second risk identification result is that there is no risk, performing corresponding logical processing on the live broadcast access request; Processing data after logical processing of the live broadcast access request is obtained, and the processing data is returned to the user account, where the processing data is used to represent access data corresponding to the live broadcast access request.
12. The device according to any one of claims 9 to 11, characterized in that The access statistical parameter corresponding to the live access request includes at least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as a result within the corresponding period; the access statistical parameter determination module is configured to execute: Obtaining historical access requests, corresponding request times, and return results of the user account, wherein the return results include any one of risk control prompt information and processing data returned according to the historical access requests; According to the historical access requests of the user account, the corresponding request time and the live broadcast access request, counting the number of requests of the user account based on different time periods; The return result of each historical access request corresponding to the request quantity is obtained as the quantity of the risk control prompt information; At least one of the number of requests of the user account based on different time periods and the number of risk control prompt information returned as the results in the corresponding period is used as the corresponding access statistical parameter.
13. The device according to any one of claims 9 to 11, characterized in that The access statistics parameter determination module is configured to execute: Obtaining historical access requests, corresponding request times, and return results of the target live page, wherein the return results include any one of risk control prompt information and processing data returned according to historical access requests of the target live page; According to the historical access requests and corresponding request times of the target live page and the live access requests, counting the number of requests for the target live page based on different time periods; Obtaining the number of risk control prompt information for which the return result of each historical access request corresponding to the requested number is the number of risk control prompt information; At least one of the number of requests for the target live broadcast page based on different time periods and the number of risk control prompt information returned as results in the corresponding period is used as a corresponding access statistical parameter.
14. The device according to any one of claims 9 to 11, characterized in that The request processing module is also configured to perform: The request identifier corresponding to the live broadcast access request is added to the cached risk control list to update the risk control list.
15. The device according to any one of claims 9 to 11, characterized in that The cached risk control list includes a cached account identification list; the request processing module is further configured to execute: When the account identifier of the user account does not exist in the cached account identifier list, it is determined that the request identifier does not exist in the cached risk control list.
16. The device according to any one of claims 9 to 11, characterized in that The cached risk control list includes a cached page identification list; the request processing module is further configured to execute: When the page identifier of the target live broadcast page does not exist in the cached page identifier list, it is determined that the request identifier does not exist in the cached risk control list.
17. An electronic device, characterized in that: include: processor; a memory for storing instructions executable by the processor; The processor is configured to execute the instructions to implement the live broadcast request processing method as described in any one of claims 1 to 8.
18. A computer-readable storage medium, characterized in that: When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the live broadcast request processing method as described in any one of claims 1 to 8.