Method, apparatus, device, and storage medium for determining a blacklisted device in the rta system
Patent Information
- Application Number
- HK22026125899
- Authority / Receiving Office
- HK · HK
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2026-07-08
- Publication Date
- 2026-09-11
Smart Images

Figure 00000027_0000 
Figure 00000027_0001 
Figure 00000027_0002
Abstract
Description
1. Specification Method, Apparatus, Device, and Storage Medium for Determining Blacklisted Devices in an RTA System Technical Field This invention relates to the field of real-time advertising technology, and particularly to a method, apparatus, device, and storage medium for determining blacklisted devices in an RTA system. Background Technology With the rapid development of internet advertising, RTB (Real-Time Bidding) has become the mainstream transaction model. The RTA (Real-Time API) system is responsible for evaluating user devices and deciding whether to deliver ads within milliseconds. Blacklisted device filtering is a key step in improving ad conversion rates and ROI. However, taking Baidu's information flow RTA as an example, its daily request volume reaches 3 billion times, and the number of blacklisted devices exceeds 100 million. Existing solutions mainly rely on Redis for blacklist determination, requiring network I / O for each query, resulting in high latency and heavy load, making it difficult to meet millisecond-level response requirements. If the entire blacklist is cached in the application's local memory, a single server would require approximately 2GB of memory, and 100 servers would consume a total of 200GB, resulting in extremely high hardware costs. On the other hand, blacklist data needs to be periodically synchronized from Hive to application servers in various data centers. The original text file size is close to 2GB, and directly distributing it to hundreds of servers will consume more than 10GB of bandwidth. Message queues have limitations on message size, traditional file servers are complex to configure and have high maintenance costs, and the application server's line-by-line file parsing is inefficient, resulting in slow system startup and updates. In summary, existing RTA systems have performance, cost, and accuracy problems in blacklist detection and data synchronization, and there is an urgent need for an efficient, low-cost, and scalable solution. This invention provides a method, apparatus, computer equipment, and storage medium for blacklist device detection in an RTA system to solve the problems of low efficiency and low accuracy of existing blacklist device detection methods in RTA systems on the market.Firstly, a method for determining blacklisted devices in an RTA system is provided, comprising: retrieving the latest blacklisted device data table from a preset table in real time or periodically, and extracting original blacklist text data from the blacklisted device data table; constructing a serialized Bloom filter instance file based on the original blacklist text data; transmitting the serialized Bloom filter instance file to a preset file server, using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, thereby obtaining a Bloom filter instance file stored on the file server containing version information; broadcasting a file update notification to a preset RTA application server using the file server, and after receiving the notification, comparing the version of the Bloom filter instance file in the local memory of the RTA application server with the latest version, and requesting to download the serialized Bloom filter instance file from the file server when the versions are inconsistent, and loading the Bloom filter instance file into the local memory through deserialization to obtain the latest version of the Bloom filter instance; and using the RTA application server to detect and receive RTAs sent by users. Upon receiving an RTA request, the system extracts the device identifier of the corresponding device from the RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency check between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device.Secondly, a device for determining blacklisted devices in an RTA system is provided, comprising: a data extraction module, used to obtain the latest blacklisted device data table from a preset table in real time or at regular intervals, and extract the original blacklist text data from the blacklisted device data table; a filter construction module, used to construct a serialized Bloom filter instance file based on the original blacklist text data; a file transfer module, used to transfer the serialized Bloom filter instance file to a preset file server, use the file server to perform a completeness verification on the serialized Bloom filter instance file, and record version information after successful verification, thereby obtaining a Bloom filter instance file stored on the file server containing version information; and a filter loading module, used to broadcast a file update notification to a preset RTA application server using the file server, and after receiving the notification, the RTA application server loads the RTA... The application server compares the version of the Bloom filter instance file in its local memory with the latest version. If the versions are inconsistent, it requests the download of the serialized Bloom filter instance file from the file server and loads the Bloom filter instance file into the local memory through deserialization to obtain the latest version of the Bloom filter instance. A device determination module is used to detect and receive RTA requests sent by users using the RTA application server. After receiving an RTA request, it extracts the device identifier of the corresponding device from the RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency check between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device. In a third aspect, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the blacklisted device determination method in the above-described RTA system. In a fourth aspect, a computer-readable storage medium is provided, storing a computer program. When the computer program is executed by a processor, it implements the steps of the blacklisted device determination method in the above-described RTA system.In the aforementioned RTA system, the blacklist device judgment method, device, computer equipment, and storage medium can obtain the latest blacklist device data table from a preset table in real time or periodically, providing a complete and reliable raw data foundation for subsequent processing. The raw blacklist text data is extracted from the blacklist device data table, avoiding loading all data into memory and effectively preventing memory overflow. Simultaneously, data cleaning and format standardization are performed to ensure the accuracy of the input data for constructing the Bloom filter, improving processing efficiency. A serialized Bloom filter instance file is constructed based on the raw blacklist text data, significantly reducing storage costs and achieving cross-language compatibility and high-performance deserialization (HK 20137564 A 4), ensuring efficient transmission and fast loading. The serialized Bloom filter instance file is transmitted to a preset file server, which verifies its integrity and records version information upon successful verification, resulting in a Bloom filter instance file stored on the file server containing version information, reducing network load. Based on the file server, the data is then transmitted to the preset RTA system. The application server sends an instantiation command, avoiding the communication pressure of the file server directly establishing connections with hundreds of application servers. It also supports off-peak download strategies, ensuring real-time notifications and system scalability. The instantiation command loads the Bloom filter instance file stored on the file server into memory. The RTA application server detects and receives RTA requests sent by users. Upon receiving an RTA request, it extracts the device identifier of the corresponding device from the request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation, and compares the calculation result with a preset value to determine whether the corresponding device is on the blacklist. This improves the efficiency and accuracy of blacklist device identification in the RTA system. The accompanying drawings are provided to more clearly illustrate the technical solutions of the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.Figure 1 is a schematic diagram of an application environment for a blacklist device determination method in an RTA system according to an embodiment of the present invention; Figure 2 is a flowchart of a blacklist device determination method in an RTA system according to an embodiment of the present invention; Figure 3 is a structural schematic diagram of a blacklist device determination device in an RTA system according to an embodiment of the present invention; Figure 4 is a structural schematic diagram of a computer device according to an embodiment of the present invention; Figure 5 is another structural schematic diagram of a computer device according to an embodiment of the present invention. Detailed Description The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention. The blacklist device determination method in an RTA system provided by the embodiments of the present invention can be applied in the application environment shown in Figure 1, wherein the client communicates with the server through a network. The server can retrieve the latest blacklist device data table from a preset table in real time or periodically via the client. It extracts the original blacklist text data from the table, constructs a serialized Bloom filter instance file based on this data, and transmits it to a preset file server. The file server verifies the integrity of the serialized Bloom filter instance file and records version information upon successful verification, resulting in a Bloom filter instance file stored on the file server containing version information. The file server then broadcasts a file update notification to a preset RTA application server. Upon receiving the notification, the RTA application server compares the version of the Bloom filter instance file in its local memory with the latest version. If the versions are inconsistent, it requests to download the serialized Bloom filter instance file from the file server and loads it into its local memory via deserialization, obtaining the latest version of the Bloom filter instance. The RTA application server detects and receives RTA requests from users. Upon receiving an RTA request, it retrieves the latest version of the Bloom filter instance from the file server... The device identifier of the corresponding device is extracted from the request. The device identifier is input into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier. The calculation result is compared with a preset value to determine whether the corresponding device is a blacklisted device, thereby improving the efficiency and accuracy of blacklisted device determination in the RTA system.The client can be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server can be implemented using a standalone server or a server cluster consisting of multiple servers. The invention will be described in detail below through specific embodiments. Please refer to Figure 2, which is a flowchart illustrating a blacklist device judgment method in an RTA system provided by an embodiment of the invention, including the following steps: S1. Obtain the latest blacklist device data table from a preset table in real time or periodically, and extract the original blacklist text data from the blacklist device data table. In this embodiment of the invention, the blacklist device data table is updated according to a preset frequency. In this embodiment of the invention, the preset table refers to the blacklist device data table stored in Hive, which is specifically used to store the device ID information that needs to be excluded. Specifically, the preset frequency can be once a day. Specifically, Hive is a Hadoop-based data warehouse tool used to process large-scale structured data. Its core function is to map data files stored on the Hadoop Distributed File System (HDFS) into database tables, and to provide a query language called HiveQL (similar to SQL), allowing data analysts to query and analyze massive amounts of data using familiar SQL syntax without having to write complex MapReduce programs. In this embodiment of the invention, extracting the original blacklist text data from the blacklist device data table includes: obtaining the device IDs from the blacklist device data table by executing an SQL query, resulting in a device ID result set cursor; obtaining a device ID text line data stream from the blacklist device data table based on the device ID result set cursor; and obtaining text data from a preset server based on the device ID text line data stream and a preset target file path to obtain the original blacklist text data. In detail, the step of retrieving the device IDs from the blacklist device data table by executing an SQL query and obtaining a device ID result set cursor is achieved by establishing a connection with the Hive database through the Hive JDBC driver (HK 20137564 A 7) and executing a predefined SQL query statement. This query selects all device ID fields from the blacklist device data table. To avoid memory overflow caused by loading massive amounts of data at once, the query uses a cursor method to retrieve the result set, that is, by setting the fetch size parameter or using Hive's streaming read mode, the result set is returned row by row or in batches.In detail, the step of obtaining the device ID text line data stream from the blacklist device data table based on the device ID result set cursor is achieved by traversing the device ID result set cursor and calling the getString("device_id") method to extract the string value of the device ID field for each record. During the extraction process, necessary data cleaning is performed, such as removing leading and trailing whitespace characters and verifying whether the device ID format conforms to specifications (such as length and character type). In detail, the step of obtaining text data from a preset server based on the device ID text line data stream and a preset target file path to obtain the original blacklist text data involves creating a file output stream based on the preset target file path. This output stream can be directly written to a remote FTP server. During the writing process, the data service reads data line by line from the device ID text line data stream and writes each line to the file output stream. S2: Construct a serialized Bloom filter instance file based on the original blacklist text data. In this embodiment of the invention, constructing a serialized Bloom filter instance file based on the original blacklist text data includes: initializing the instance based on preset Bloom filter parameters to obtain a blank Bloom filter instance; obtaining a device ID line read stream based on the original blacklist text data; filling the blank Bloom filter instance with the device ID line read stream to obtain a filled Bloom filter instance; and serializing the filled Bloom filter instance into a file to obtain a serialized Bloom filter instance file. Specifically, the initialization of the instance based on preset Bloom filter parameters to obtain a blank Bloom filter instance involves creating an empty Bloom filter instance in memory using a preset optimal parameter combination (e.g., number of hash functions k=7, bit array length m=16 billion bits, false positive rate p=0.0081). HK 20137564 A 8 Specifically, the implementation can use the BloomFilter.create() method of the Google Guava library. By specifying Funnels.stringFunnel(Charset.forName("UTF-8")) as the element type, setting the expected number of inserted elements (e.g., 70 million) using the withExpectedInsertions parameter, and setting the false Probability to set the false positive rate, Guava will automatically calculate and allocate the required bit array internally. In detail, the step of obtaining the device ID line reading stream based on the original blacklist text data involves opening the file and creating an input stream based on the preset original blacklist text data file path, wrapping it as a buffered character reader (such as BufferedReader in Java).The file content is read line by line by calling the `readLine()` method repeatedly. For each line, leading and trailing whitespace characters are removed (using `trim()`), and empty or invalid lines are filtered out. Specifically, filling the blank Bloom filter instance with the device ID line read stream to obtain a filled Bloom filter instance involves calling the Bloom filter's insertion method (such as the `put()` method in Guava) for each non-empty device ID string based on the device ID line read stream. In this embodiment, serializing the filled Bloom filter instance into a file to obtain a serialized Bloom filter instance file includes: extracting metadata and a bit array from the Bloom filter instance; generating a Protobuf Java class according to a predefined message format; generating a Protobuf message object based on the metadata, the bit array, and the Protobuf Java class; converting the Protobuf message object into binary to obtain a serialized binary byte array; and writing the serialized binary byte array to a preset specified path to obtain the serialized Bloom filter instance file. Specifically, the extraction of metadata and bit arrays from the Bloom filter instance involves directly obtaining key metadata via API or internal fields, including the number of hash functions k (k=7 in this scheme), bit array length m (16 billion bits), and false positive rate p (0.0081). Specifically, the generation of a Protobuf Java class based on a predefined message format involves writing a Protocol Buffers .proto file (HK 20137564 A 9) to define the message format, such as fields including int32 k, int64 m, double falseProbability, bytes bits, and int64 version. Then, the protoc compiler (Protocol Buffers compilation tool) is used to compile the .proto file to generate a class file in the corresponding programming language (such as Java). Specifically, the generation of a Protobuf message object based on the metadata, the bit array, and the Protobuf Java class is achieved by creating a message builder. The extracted metadata (k, m, p) is set into the builder using setter methods; the bit array and byte array are encapsulated into a protobuf ByteString type using the ByteString.copyFrom() method and set; the version number (such as a timestamp) is also set. Finally, the build() method is called to generate a fully populated Protobuf message object.In detail, writing the serialized binary byte array to a preset specified path to obtain a serialized Bloom filter instance file involves creating a file output stream based on the preset file path, writing the binary byte array in blocks to the file, and ensuring that the data is completely written to disk. S3: The serialized Bloom filter instance file is transmitted to a preset file server. The file server performs integrity verification on the serialized Bloom filter instance file, and records version information after successful verification, resulting in a Bloom filter instance file stored on the file server containing version information. In this embodiment of the invention, the file server refers to a network service endpoint (such as FTP, SMB, NFS server, or cloud storage API, etc.) pre-specified in the system or program configuration for storing or sharing files. In this embodiment of the invention, the step of transmitting the serialized Bloom filter instance file to a preset file server, using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, to obtain a Bloom filter instance file stored on the file server containing version information, includes: calculating the verification information of the serialized Bloom filter instance file to obtain first verification information; converting the serialized Bloom filter instance file into binary stream data; uploading the binary stream data to a temporary storage area of the preset file server; calculating the verification information of the Bloom filter instance file in the temporary storage area of the file server to obtain second verification information; if the first verification information is consistent with the second verification information, recording the filename, size, checksum, upload time, and status of the temporarily stored Bloom filter instance file to obtain metadata records; and updating the version information of the Bloom filter instance file in the temporary storage area based on the metadata records. Specifically, calculating the verification information of the serialized Bloom filter instance file to obtain the first verification information involves calculating the hash value of the serialized Bloom filter instance file using Java's MessageDigest class (such as the MD5 algorithm) or the Apache Commons Codec library. Specifically, converting the serialized Bloom filter instance file into binary stream data involves opening the serialized Bloom filter instance file in binary mode, creating a FileInputStream and wrapping it as a BufferedInputStream, and reading the file content in a streaming manner. Specifically, calculating the verification information of the Bloom filter instance file in the temporary storage area of the file server to obtain the second verification information is the same as the steps for calculating the verification information of the serialized Bloom filter instance file to obtain the first verification information, and will not be repeated here.In detail, updating the version information of the Bloom filter instance file in the temporary storage area based on the metadata record involves atomically setting the pointer to the currently effective version of the Bloom filter instance file in the temporary storage (such as the current_version field in the database or a ZooKeeper node) to the new version number. Simultaneously, a symbolic link or configuration file can be generated pointing to the new file, allowing the RTA application to obtain the latest file via a fixed URL (such as / current). S4. The file server broadcasts a file update notification to a preset RTA application server. Upon receiving the notification, the RTA application server compares the version of the Bloom filter instance file in its local memory with the latest version. If the versions are inconsistent, it requests the download of the serialized Bloom filter instance file from the file server and loads the Bloom filter instance file into its local memory through deserialization to obtain the latest version of the Bloom filter instance. HK 20137564 A 11 In this embodiment of the invention, the file server and the RTA application server can be the same physical / cloud server, and the file service and the RTA application service can be deployed on the same machine; alternatively, they can be deployed on different physical / cloud servers, and the file service and the RTA application service can be deployed on different machines. In a production environment, deployment on different machines is preferred because: the RTA application service has extremely demanding performance requirements, requiring stable CPU, memory, and network bandwidth to ensure millisecond-level latency, while the file service will compete for disk I / O and bandwidth when reading and writing large files, which may cause fluctuations in the RTA service response latency and affect the advertising effect. In one embodiment of the invention, when the versions are inconsistent, a preset staggered peak strategy is used to request the download of the serialized Bloom filter instance file from the file server. Specifically, the staggered peak strategy refers to: when multiple clients detect that the locally cached Bloom filter version is inconsistent with the file server version, in order to avoid a large number of clients initiating download requests to the server at the same time, causing an instantaneous traffic peak (i.e., the "thundering herd effect" or "traffic spike"), a set of differentiated waiting time rules are preset. Specific implementation methods include, but are not limited to: calculating a random delay between 0 and N seconds based on the modulo of the hash value of the client device ID (such as IMEI, IDFA) or user ID; grouping clients by IP range or device model, and assigning different delay times to different groups (e.g., group A has a delay of 0-2 seconds, group B has a delay of 3-5 seconds). Through these strategies, clients request downloads from the server at staggered times when their versions are inconsistent, thereby distributing server load and ensuring system stability.In this embodiment of the invention, the instantiation instruction sent from the file server to the preset RTA application server is generated and broadcast through an internal configuration center (such as the HiPPO notification center) after the file server has completed storing the new version of the Bloom filter instance file and updating the version information. The RTA application server has registered to listen to specific configuration items (such as / bloomfilter / version) in the configuration center upon startup. When the value of the configuration item is updated, the configuration center actively pushes a change notification to all subscribed RTA application server instances. After receiving the notification, the application service parses the changed content to obtain the version number and download address of the new file, triggering a background thread to execute a file retrieval task, thereby realizing the transmission of the instantiation instruction from the file server to the RTA application. HK 20137564 A 12 In this embodiment of the invention, the step of loading the Bloom filter instance file stored on the file server into memory according to the instantiation instruction involves starting a background thread to initiate an HTTP request to the file server based on the file version number and download address carried in the instantiation instruction, and downloading the latest serialized Bloom filter instance file. After the download is completed, the application service uses the deserialization method of Protocol Buffers (such as parseFrom) to directly deserialize the file content into a Bloom filter data structure in memory, and finally seamlessly replaces the old instance with the newly loaded Bloom filter instance through an atomic pointer replacement operation. S5. The RTA application server detects and receives RTA requests sent by the user. After receiving an RTA request, the device identifier of the corresponding device is extracted from the RTA request. The device identifier is input into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and the calculation result is compared with a preset value to determine whether the corresponding device is a blacklisted device.In this embodiment of the invention, the step of using the RTA application server to detect and receive RTA requests sent by users, extracting the device identifier of the corresponding device from the RTA request after receiving an RTA request, inputting the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performing a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device, includes: parsing the device ID in the RTA request to obtain an ID string; performing a hash calculation on the ID string to obtain an array index position; checking whether the value of each index position in the array index position is 1; if the value of each index position in the array index position is 1, the judgment result is that the corresponding device in the RTA request is a blacklisted device; if the value of each index position in the array index position is not 1, the judgment result is that the corresponding device in the RTA request is not a blacklisted device. Specifically, parsing the device ID in the RTA request to obtain the ID string involves using a JSON parsing library (such as Jackson or Gson) to read the request body and retrieve the corresponding string value (e.g., HK 20137564 A 13 device_id). More specifically, hashing the ID string to obtain the array index position involves using k preset hash functions (k=7 in this scheme, based on the MurmurHash algorithm) to hash the device ID string. Typically, a basic hash function is first used to generate a 128-bit or 64-bit hash value, then a double hashing technique is used to derive k independent hash results. Finally, the result is modulo the array length m to obtain k array index positions between 0 and m-1. In this embodiment of the invention, the step of using the RTA application server to detect and receive RTA requests sent by users, extracting the device identifier of the corresponding device from the RTA request after receiving an RTA request, inputting the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performing a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device, further includes: if the judgment result determines that the corresponding device in the RTA request is a blacklisted device, then confirming the cancellation of ad delivery; if the judgment result determines that the corresponding device in the RTA request is not a blacklisted device, then obtaining the user's profile data; matching candidate ads according to the profile data and a preset advertising plan configuration to obtain a candidate ad list; and delivering ads from the candidate ad list to the user.In detail, the user profile data typically includes demographic attributes and behavioral characteristics such as age, gender, region, and interest tags. Specifically, the process of matching candidate ads based on the user profile data and a pre-configured advertising plan to obtain a candidate ad list involves reading the pre-loaded advertising plan configuration (containing targeting conditions, bids, budgets, etc. for each ad) and iterating through all available advertising plans. For each ad, its targeting conditions (such as geographic range, age range, interest tags, etc.) are compared item by item with the real-time user profile data to filter out ads that match the user profile. Therefore, the above solution proposes a highly efficient processing method for blacklisting devices in an RTA system based on a Bloom filter (HK 20137564 A 14), addressing the performance bottlenecks and resource consumption issues faced by information flow RTA systems handling 3 billion daily requests and 100 million blacklist devices. Existing solutions rely on Redis for blacklist checks, resulting in high network I / O latency and heavy load. Furthermore, caching the entire blacklist locally requires 2GB of memory per machine, totaling 200GB across hundreds of servers, leading to extremely high hardware costs. Simultaneously, directly distributing the original blacklist text file (approximately 2GB) to hundreds of servers incurs over 10GB of bandwidth consumption and low parsing efficiency. The core of this solution lies in introducing a Bloom filter into the RTA blacklist removal process. Through mathematical calculations, the optimal parameter combination is determined (hash function count k=7, bit array length m=16 billion bits, false positive rate p=0.0081), compressing the single-application memory usage to approximately 120MB (only 6% of traditional solutions). This achieves ultra-high performance with a single thread performing 100 million checks in just 200 milliseconds, completely eliminating network I / O overhead. At the data synchronization level, a "pre-construction + serialization compression" strategy is adopted. A Bloom filter instance is built on the original blacklist text at the data source end and serialized into a binary file using Protocol Buffers, reducing the file size from 2GB to approximately 100MB (compression rate of 95%). A lightweight file server based on Spring Boot is deployed in a Shanghai data center, broadcasting change notifications through the configuration center. The RTA application employs a random delay peak download and exponential backoff retry strategy, combined with memory-mapped files and Protobuf deserialization technology to achieve seamless hot reloading at runtime. This solution significantly enhances the scalability and accuracy of the system while improving the efficiency of blacklist judgment and reducing memory and bandwidth consumption, providing cost-effective technical support for handling massive requests in RTA services. It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of this embodiment.In one embodiment, a blacklist device determination device for an RTA system is provided, which corresponds one-to-one with the blacklist device determination method for an RTA system described in the above embodiments. As shown in Figure 3, the blacklist device determination device for an RTA system includes a data extraction module 101, a filter construction module 102, a file transfer module 103, a filter loading module 104, and a device determination module 105. The functional modules are described in detail below: Data extraction module 101 is used to retrieve the latest blacklist HK 20137564 A 15 device data table from a preset table in real time or at regular intervals, and extract the original blacklist text data from the blacklist device data table; Filter construction module 102 is used to construct a serialized Bloom filter instance file based on the original blacklist text data; File transfer module 103 is used to transfer the serialized Bloom filter instance file to a preset file server, use the file server to perform integrity verification on the serialized Bloom filter instance file, and record version information after successful verification, resulting in a Bloom filter instance file stored on the file server containing version information; Filter loading module 104 is used to broadcast a file update notification to a preset RTA application server using the file server, and after receiving the notification, the RTA application server loads the RTA... The application server compares the version of the Bloom filter instance file in its local memory with the latest version. If the versions are inconsistent, it requests the file server to download the serialized Bloom filter instance file and loads it into the local memory through deserialization to obtain the latest version of the Bloom filter instance. The device determination module 105 is used to detect and receive RTA requests sent by users using the RTA application server. After receiving an RTA request, it extracts the device identifier of the corresponding device from the RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device. In one embodiment, the data extraction module 101, when performing the extraction of original blacklist text data from the blacklist device data table, specifically performs the following steps: obtaining the device ID from the blacklist device data table by executing an SQL query, and obtaining a device ID result set cursor; obtaining a device ID text line data stream from the blacklist device data table based on the device ID result set cursor; and obtaining text data from a preset server based on the device ID text line data stream and a preset target file path to obtain the original blacklist text data.In one embodiment, the filter construction module 102, when executing the step of constructing a serialized Bloom filter instance file based on the original blacklist text data, specifically performs the following: Initializes the instance based on preset Bloom filter parameters to obtain a blank Bloom filter instance; Obtains a device ID line read stream based on the original blacklist text data; Fills the blank Bloom filter instance with the device ID line read stream to obtain a filled Bloom filter instance; Serializes the filled Bloom filter instance into a file to obtain a serialized Bloom filter instance file. In one embodiment, the filter construction module 102, when performing the step of serializing the filled Bloom filter instance into a file to obtain a serialized Bloom filter instance file, specifically performs the following steps: extracting metadata and bit arrays from the Bloom filter instance; generating a Protobuf Java class according to a predefined message format; generating a Protobuf message object based on the metadata, the bit array, and the Protobuf Java class; converting the Protobuf message object into binary to obtain a serialized binary byte array; and writing the serialized binary byte array to a preset specified path to obtain the serialized Bloom filter instance file. In one embodiment, the file transfer module 103, when performing the step of transferring the serialized Bloom filter instance file to a preset file server, using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, to obtain a Bloom filter instance file stored on the file server containing version information, specifically performs the following steps: calculating the verification information of the serialized Bloom filter instance file to obtain first verification information; converting the serialized Bloom filter instance file into binary stream data; uploading the binary stream data to a temporary storage area of the preset file server; calculating the verification information (HK 20137564 A 17) of the Bloom filter instance file in the temporary storage area of the file server to obtain second verification information; if the first verification information is consistent with the second verification information, recording the filename, size, checksum, upload time, and status of the temporarily stored Bloom filter instance file to obtain metadata records; and updating the version information of the Bloom filter instance file in the temporary storage area based on the metadata records.In one embodiment, the device determination module 105, when performing the step of detecting and receiving RTA requests sent by users using the RTA application server, extracts the device identifier of the corresponding device from the RTA request after receiving an RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device, specifically performs the following steps: parsing the device ID in the RTA request to obtain an ID string; performing a hash calculation on the ID string to obtain an array index position; checking whether the value of each index position in the array index position is 1; if the value of each index position in the array index position is 1, the judgment result is that the corresponding device in the RTA request is a blacklisted device; if the value of each index position in the array index position is not 1, the judgment result is that the corresponding device in the RTA request is not a blacklisted device. In one embodiment, the device determination module 105, after performing the step of detecting and receiving RTA requests sent by users using the RTA application server, extracts the device identifier of the corresponding device from the RTA request after receiving an RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device. It is further configured to: if the judgment result determines that the corresponding device in the RTA request is a blacklisted device, then confirm the cancellation of ad delivery; if the judgment result determines that the corresponding device in the RTA request is not a blacklisted device, then obtain the user's profile data; match candidate ads according to the profile data and a preset advertising plan configuration to obtain a candidate ad list; and deliver ads from the candidate ad list to the user. This invention provides a blacklisted device determination device in an RTA system, addressing the performance bottleneck and resource consumption problems faced by information flow RTA with an average of 3 billion requests per day and 100 million blacklisted devices. The existing solution relies on Redis for blacklist determination, resulting in high network I / O latency and heavy load. Furthermore, caching the entire blacklist in local memory requires 2GB of memory per machine, consuming a total of 200GB across hundreds of servers, which is extremely costly in terms of hardware. At the same time, directly distributing the original blacklist text file (approximately 2GB) to hundreds of servers will generate more than 10GB of bandwidth consumption and result in low parsing efficiency.The core of the solution lies in introducing a Bloom filter into the RTA blacklisting process. Optimal parameter combinations are determined through mathematical calculations (number of hash functions k=7, bit array length m=16 billion bits, false positive rate p=0.0081), compressing the single-application memory footprint to approximately 120MB (only 6% of traditional solutions). This achieves ultra-high performance with 100 million single-threaded checks in just 200 milliseconds, completely eliminating network I / O overhead. At the data synchronization level, a "pre-construction + serialization compression" strategy is adopted. A Bloom filter instance is built on the original blacklist text at the data source end and serialized into a binary file using Protocol Buffers, reducing the file size from 2GB to approximately 100MB (95% compression). A lightweight file server based on Spring Boot is deployed in a Shanghai data center. Change notifications are broadcast through the configuration center. The RTA application employs random delays for staggered downloads and exponential backoff retry strategies, combined with memory-mapped files and Protobuf deserialization technology to achieve seamless hot reloading at runtime. This solution significantly enhances the scalability and accuracy of the system while improving the efficiency of blacklist detection and reducing memory and bandwidth consumption, providing cost-effective technical support for handling massive requests in RTA services. Specific limitations on the blacklist device detection device in the RTA system can be found in the limitations on the blacklist device detection method in the RTA system above, and will not be repeated here. Each module in the aforementioned blacklist device detection device in the RTA system can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in the computer device in hardware form, or stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each module in HK 20137564 A 19. In one embodiment, a computer device is provided, which can be a server, and its internal structure diagram can be as shown in Figure 4. The computer device includes a processor, memory, network interface, and database connected via a system bus. The processor of the computer device provides computing and control capabilities. The memory of the computer device includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface of the computer device is used to communicate with external clients via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a blacklist device identification method on the server side of an RTA system. In one embodiment, a computer device is provided, which can be a client, and its internal structure diagram can be as shown in Figure 5.The computer device includes a processor, memory, network interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The network interface is used to communicate with an external server via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a blacklist device identification method on the client side of an RTA system. In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it performs the following steps: retrieving the latest blacklist device data table from a preset table in real time or periodically; extracting original blacklist text data from the blacklist device data table; constructing a serialized Bloom filter instance file based on the original blacklist text data; transmitting the serialized Bloom filter instance file to a preset file server; using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, resulting in a Bloom filter instance file stored on the file server containing version information; broadcasting a file update notification to a preset RTA application server using the file server; and upon receiving the notification, the RTA application server... The application server compares the version of the Bloom filter instance file in its local memory with the latest version. If the versions are inconsistent, it requests the download of the serialized Bloom filter instance file from the file server and loads the Bloom filter instance file into the local memory through deserialization to obtain the latest version of the Bloom filter instance. The application server uses the RTA to detect and receive RTA requests sent by the user. After receiving an RTA request, it extracts the device identifier of the corresponding device from the RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency check between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device.In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, it performs the following steps: retrieving the latest blacklist device data table from a preset table in real time or periodically, and extracting original blacklist text data from the blacklist device data table; constructing a serialized Bloom filter instance file based on the original blacklist text data; transmitting the serialized Bloom filter instance file to a preset file server, using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, thus obtaining a Bloom filter instance file stored on the file server containing version information; broadcasting a file update notification to a preset RTA application server using the file server, and upon receiving the notification, comparing the version of the Bloom filter instance file in the local memory of the RTA application server with the latest version, requesting to download the serialized Bloom filter instance file from the file server when the versions are inconsistent, and loading the Bloom filter instance file into the local memory through deserialization to obtain the latest version of the Bloom filter instance; HK 20137564 A 21 The RTA application server detects and receives RTA requests sent by users. Upon receiving an RTA request, it extracts the device identifier of the corresponding device from the request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and compares the calculation result with a preset value to determine whether the corresponding device is a blacklisted device. It should be noted that the functions or steps implemented by the computer-readable storage medium or computer device described above can be found in the relevant descriptions of the server-side and client-side in the foregoing method embodiments. To avoid repetition, they will not be described in detail here. Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory.By way of illustration and not limitation, RAM is available in various forms, such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Dual Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchlink DRAM (SLDRAM), Rambus Direct RAM (RDRAM), Direct Memory Bus Dynamic RAM (DRDRAM), and Memory Bus Dynamic RAM (RDRAM), etc. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. Finally, it should be noted that if any software tools or components not belonging to this company appear in the embodiments of the application, HK 20137564 A 22 is merely for illustrative purposes and does not represent actual use. The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.HK 20137564 A 1 Claim 1. A method for determining blacklisted devices in an RTA system, characterized in that it includes: obtaining the latest blacklisted device data table from a preset table in real time or at regular intervals, and extracting original blacklist text data from the blacklisted device data table; constructing a serialized Bloom filter instance file based on the original blacklist text data; transmitting the serialized Bloom filter instance file to a preset file server, using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, thereby obtaining a Bloom filter instance file stored on the file server containing version information; broadcasting a file update notification to a preset RTA application server using the file server, and the RTA application server, upon receiving the notification, transmitting the RTA... The application server compares the version of the Bloom filter instance file in its local memory with the version of the Bloom filter instance file in the file server. If the versions are inconsistent, it requests the download of the serialized Bloom filter instance file from the file server and loads the Bloom filter instance file into the local memory through deserialization to obtain the latest version of the Bloom filter instance. The application server detects and receives RTA requests sent by users. After receiving an RTA request, it extracts the device identifier of the corresponding device from the RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency check between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device. 2. The method for determining blacklisted devices in an RTA system as described in claim 1, characterized in that, the step of extracting the original blacklist text data from the blacklisted device data table includes: obtaining the device ID from the blacklisted device data table by executing an SQL query, and obtaining a device ID result set cursor; obtaining a device ID text line data stream from the blacklisted device data table according to the device ID result set cursor; and obtaining text data from a preset server according to the device ID text line data stream and a preset target file path to obtain the original blacklist text data.3. The method for determining blacklisted devices in an RTA system as described in claim 1, characterized in that, the step of constructing a serialized Bloom filter instance file based on the original blacklist text data includes: initializing the instance based on preset Bloom filter parameters to obtain a blank Bloom filter instance; obtaining a device ID line read stream based on the original blacklist text data; filling the blank Bloom filter instance with the device ID line read stream to obtain a filled Bloom filter instance; and serializing the filled Bloom filter instance into a file to obtain a serialized Bloom filter instance file. 4. The method for determining blacklisted devices in an RTA system as described in claim 3, characterized in that, the step of serializing the filled Bloom filter instance into a file to obtain a serialized Bloom filter instance file includes: extracting metadata and a bit array from the Bloom filter instance; generating a Protobuf Java class according to a predefined message format; generating a Protobuf message object according to the metadata, the bit array, and the Protobuf Java class; converting the Protobuf message object into binary to obtain a serialized binary byte array; and writing the serialized binary byte array into a preset specified path to obtain a serialized Bloom filter instance file. 5. The method for determining blacklisted devices in an RTA system as described in claim 1, characterized in that, the step of transmitting the serialized Bloom filter instance file to a preset file server, using the file server to perform integrity verification on the serialized Bloom filter instance file, and recording version information after successful verification, to obtain a Bloom filter instance file stored on the file server containing version information, further includes: HK 20137564 A 3 Calculating the verification information of the serialized Bloom filter instance file to obtain first verification information; Converting the serialized Bloom filter instance file into binary stream data; Uploading the binary stream data to a temporary storage area of the preset file server; Calculating the verification information of the Bloom filter instance file in the temporary storage area of the file server to obtain second verification information; If the first verification information is consistent with the second verification information, recording the filename, size, checksum, upload time, and status of the temporarily stored Bloom filter instance file to obtain metadata records; Updating the version information of the Bloom filter instance file in the temporary storage area based on the metadata records.6. The method for determining blacklisted devices in an RTA system as described in claim 1, characterized in that, the step of using the RTA application server to detect and receive RTA requests sent by users, extracting the device identifier of the corresponding device from the RTA request after receiving an RTA request, inputting the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performing a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device, includes: parsing the device ID in the RTA request to obtain an ID string; performing a hash calculation on the ID string to obtain an array index position; checking whether the value of each index position in the array index position is 1; if the value of each index position in the array index position is 1, the judgment result is that the corresponding device in the RTA request is a blacklisted device; if the value of each index position in the array index position is not 1, the judgment result is that the corresponding device in the RTA request is not a blacklisted device. 7. The method for determining blacklisted devices in an RTA system as described in claim 1, characterized in that, after the step of using the RTA application server to detect and receive RTA requests sent by the user, extracting the device identifier of the corresponding device from the RTA request after receiving an RTA request, inputting the device identifier HK 20137564 A 4 into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performing a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device, the method further includes: if the judgment result determines that the corresponding device in the RTA request is a blacklisted device, then confirming the cancellation of advertising; if the judgment result determines that the corresponding device in the RTA request is not a blacklisted device, then obtaining the user's profile data; matching candidate advertisements according to the profile data and a preset advertising plan configuration to obtain a candidate advertisement list; and delivering advertisements from the candidate advertisement list to the user.8. A blacklist device identification device in an RTA system, characterized in that it comprises: a data extraction module, used to obtain the latest blacklist device data table from a preset table in real time or at regular intervals, and extract original blacklist text data from the blacklist device data table; a filter construction module, used to construct a serialized Bloom filter instance file based on the original blacklist text data; a file transfer module, used to transfer the serialized Bloom filter instance file to a preset file server, use the file server to perform integrity verification on the serialized Bloom filter instance file, and record version information after successful verification, thereby obtaining a Bloom filter instance file stored on the file server containing version information; and a filter loading module, used to broadcast a file update notification to a preset RTA application server using the file server, wherein after receiving the notification, the RTA application server compares the version of the Bloom filter instance file in its local memory with the latest version, and if the versions are inconsistent, requests to download the serialized Bloom filter instance file from the file server, and loads the Bloom filter instance file into the local memory through deserialization, thereby obtaining the latest version of the Bloom filter instance; A device identification module is used to detect and receive HK 20137564 A 5 RTA requests sent by users using the RTA application server. After receiving an RTA request, it extracts the device identifier of the corresponding device from the RTA request, inputs the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier, and performs a consistency judgment between the calculation result and a preset value to determine whether the corresponding device is a blacklisted device. 9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, when the processor executes the computer program, it implements the blacklisted device identification method in the RTA system as described in any one of claims 1 to 7. 10. A computer-readable storage medium storing a computer program, characterized in that, when the computer program is executed by a processor, it implements the blacklisted device identification method in the RTA system as described in any one of claims 1 to 7.HK 20137564 A 1 Instruction Manual Drawings: Network Client / Server Diagram 1 HK 20137564 A 2 Real-time or periodic retrieval of the latest blacklist device data table from a preset table; extraction of original blacklist text data from the blacklist device data table; construction of a serialized Bloom filter instance file based on the original blacklist text data S1; transmission of the serialized Bloom filter instance file to a preset file server; integrity verification of the serialized Bloom filter instance file using the file server; recording version information after successful verification; obtaining a Bloom filter instance file stored on the file server containing version information; detection and reception of RTA requests sent by users using the RTA application server; extraction of the device identifier of the corresponding device from the RTA request upon receipt; input of the device identifier into the latest version of the Bloom filter instance to perform a hash calculation on the device identifier; consistency judgment between the calculation result and a preset value; determination of whether the corresponding device is a blacklist device S2 S3 S4 S5 The file server broadcasts a file update notification to a preset RTA application server. After receiving the notification, the RTA application server compares the version of the Bloom filter instance file in its local memory with the version of the Bloom filter instance file in the file server. If the versions are inconsistent, it requests the file server to download the serialized Bloom filter instance file and loads the Bloom filter instance file into its local memory through deserialization to obtain the latest version of the Bloom filter instance. Figure 2 HK 20137564 A 3 Filter construction module File transfer module Filter loading module Data extraction module RTA system blacklist device judgment device Device judgment module 101 102 103 104 105 Figure 3 Computer device Non-volatile storage medium Operating system Computer program In-memory Processor Network interface System bus Database Figure 4 HK 20137564 A 4 Computer device Non-volatile storage medium Operating system Computer program In-memory Processor Network interface System bus Input device Display screen Figure 5 HK 20137564 A.
