File uploading method, device, apparatus and storage medium

By introducing mapping relationships and RPA robots into the file upload process, and dynamically traversing tests to execute file uploads in parallel, the problems of low efficiency and high error rate in existing technologies are solved, achieving efficient and reliable automated file uploads.

CN122160371APending Publication Date: 2026-06-05CHINA MOBILE GROUP DESIGN INST +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA MOBILE GROUP DESIGN INST
Filing Date
2026-02-09
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

Existing file upload methods rely on manual operations, resulting in low efficiency, high error rates, and a lack of automation mechanisms, which affects task reliability and traceability.

Method used

By determining the mapping relationship between the file to be uploaded and the upload location on the target server, the robot uses Robotic Process Automation (RPA) to operate the browser, dynamically traverse and test the opening of tabs in parallel, and allocate tasks according to environmental parameters and attribute information to achieve parallel file upload.

Benefits of technology

A fully automated upload chain, from centralized file information management to RPA-driven processes, was built, improving the efficiency and stability of batch uploads and solving the problems of low processing efficiency and high error rate caused by manual intervention in traditional methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122160371A_ABST
    Figure CN122160371A_ABST
Patent Text Reader

Abstract

The application discloses a file uploading method and device, equipment and storage medium, and specifically discloses the following: a mapping relationship between a to-be-uploaded file and a target server uploading position is determined, and attribute information of the to-be-uploaded file and the mapping relationship are recorded in a centralized management file; through dynamic traversal testing, a target number of browser tab pages that can be opened simultaneously and used for file uploading is determined, and browser types, actual uploading speeds and target server response times obtained in the testing are taken as environment parameters and recorded in the centralized management file; based on the mapping relationship, an RPA (robotic process automation) robot is used to operate a browser to log in to the target server and simultaneously open the target number of tab pages; according to the attribute information, the mapping relationship and the environment parameters recorded in the centralized management file, the opened tab pages are allocated uploading tasks, and the RPA robot is used to control all the opened tab pages to perform file uploading operations in parallel.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer software technology, and in particular to a file upload method, apparatus, device and storage medium. Background Technology

[0002] Currently, file uploads are typically done manually. Specifically, operators need to manually identify the files to be uploaded, repeatedly open browser pages, locate the upload interface of the target server one by one, and submit the files to the server by manually selecting them.

[0003] While the manual method described above can achieve file upload, it is extremely inefficient, especially when processing large batches or large files, as it is time-consuming. Furthermore, due to its heavy reliance on manual operation, the process is highly susceptible to errors such as incorrect or missed file selection due to human fatigue or negligence, resulting in a high error rate. In addition, manual operation lacks automated error handling and status logging mechanisms. If the upload process is interrupted due to network fluctuations or other reasons, it is difficult to detect and recover in a timely manner, severely impacting the reliability and traceability of the upload task. Summary of the Invention

[0004] The main objective of this invention is to provide a file upload method, apparatus, device, and storage medium, which aims to solve the problems of low efficiency and high error rate caused by the complete reliance on manual operation in existing file upload methods, as well as the impact on task reliability and traceability due to the lack of automation mechanisms.

[0005] In a first aspect, embodiments of this disclosure provide a file upload method, including: The mapping relationship between the file to be uploaded and the upload location on the target server is determined, and the attribute information of the file to be uploaded and the mapping relationship are recorded in a centralized management file; the attribute information includes file size and file type; By dynamically traversing the test, the target number of browser tabs that can be opened simultaneously for file upload is determined, and the browser type, actual upload speed, and target server response time obtained in the test are recorded as environmental parameters in the centralized management file. Based on the mapping relationship, the Robotic Process Automation (RPA) robot is used to log in to the target server via a browser and simultaneously open the target number of tabs. Based on the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file, upload tasks are assigned to the open tabs, and the RPA robot controls all open tabs to perform file upload operations in parallel.

[0006] Secondly, embodiments of this disclosure provide a file uploading device, including: The first determining module is used to determine the mapping relationship between the file to be uploaded and the upload location of the target server, and to record the attribute information of the file to be uploaded and the mapping relationship in a centralized management file; the attribute information includes file size and file type; The second determination module is used to determine the target number of browser tabs that can be opened simultaneously for file upload by dynamically traversing the test, and to record the browser type, actual upload speed, and target server response time obtained in the test as environmental parameters in the centralized management file. The control module is used to log in to the target server using a robot browser operated by a robot in the Robotic Process Automation (RPA) system based on the mapping relationship, and simultaneously open the target number of tabs. The allocation module is used to allocate upload tasks to open tabs based on the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file. The RPA robot controls all open tabs to perform file upload operations in parallel.

[0007] Thirdly, embodiments of this disclosure provide an electronic device, including: a processor; and a memory configured to store computer-executable instructions, which, when executed, cause the processor to perform the steps of the method described in the first aspect above.

[0008] Fourthly, embodiments of this disclosure provide a computer-readable storage medium for storing computer-executable instructions that, when executed by a processor, implement the steps of the method described in the first aspect.

[0009] Fifthly, embodiments of this disclosure provide a computer program product, the computer program product including a computer program, which, when executed by a processor, implements the steps of the method described in the first aspect above.

[0010] The at least one technical solution provided by the embodiments of the present invention can achieve the following technical effects: In this embodiment of the invention, firstly, the mapping relationship between the file to be uploaded and the upload location on the target server is determined, and the attribute information of the file to be uploaded and this mapping relationship are recorded in a centralized management file. Then, through dynamic traversal testing, the target number of browser tabs that can be opened simultaneously for file uploads is determined, and the browser type, actual upload speed, and target server response time obtained during the test are recorded as environmental parameters in the same centralized management file. Based on the recorded mapping relationship, an RPA robot is used to operate the browser to log in to the target server and simultaneously open the target number of tabs. Finally, according to the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file, upload tasks are assigned to all open tabs, and the RPA robot controls these tabs to perform file upload operations in parallel.

[0011] This invention enables the construction of a fully automated upload process, from centralized file information management and dynamic environment testing and optimization to RPA-driven parallel execution of multiple tasks. This solves the problems of low processing efficiency and high error rates caused by the complete reliance on manual operation in existing methods. By introducing dynamic traversal testing, real-time evaluation of the current network environment, browser performance, and server responsiveness is achieved. Based on the evaluation results, the optimal number of concurrent tabs is intelligently determined, overcoming the technical shortcomings of traditional fixed-concurrency modes, which suffer from insufficient resource utilization or overload crashes due to their inability to adapt to dynamic environments. This fundamentally improves the efficiency and stability of batch uploads. Through RPA robots automatically operating the browser and centralized management of file-driven task allocation, a complete and reliable automated closed loop is achieved from file identification and environment adaptation to batch uploads. This completely solves the problems of cumbersome operation, error-proneness, and lack of reliable state management and error recovery mechanisms in existing technologies due to frequent manual intervention. Attached Figure Description

[0012] Figure 1 This is one of the flowcharts illustrating a file upload method provided in an embodiment of the present invention; Figure 2 This is a second schematic flowchart of a file upload method provided in one embodiment of the present invention; Figure 3 The third schematic flowchart of a file upload method provided in an embodiment of the present invention; Figure 4 The fourth flowchart illustrates a file upload method according to an embodiment of the present invention. Figure 5 A schematic diagram of the module composition of a file upload device 500 provided in one embodiment of the present invention; Figure 6 This is a schematic diagram of the hardware structure of an electronic device provided in one embodiment of the present invention. Detailed Implementation

[0013] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0014] The technical solutions provided by the various embodiments of the present invention will be described in detail below with reference to the accompanying drawings.

[0015] Please see Figure 1 , Figure 1 This is one of the flowcharts illustrating a file upload method provided in an embodiment of the present invention, such as... Figure 1 As shown, the method includes the following steps: Step 102: Determine the mapping relationship between the file to be uploaded and the upload location on the target server, and record the attribute information of the file to be uploaded and the mapping relationship in a centralized management file; the attribute information includes file size and file type.

[0016] Step 104: Through dynamic traversal testing, determine the target number of browser tabs that can be opened simultaneously for file upload, and record the browser type, actual upload speed, and target server response time obtained in the test as environment parameters in a centralized management file.

[0017] Step 106: Based on the mapping relationship, use the Robotic Process Automation (RPA) robot to log in to the target server via browser and open the target number of tabs simultaneously.

[0018] Step 108: Based on the attribute information, mapping relationships, and environmental parameters recorded in the centralized management file, assign upload tasks to the open tabs. The RPA robot controls all open tabs to perform file upload operations in parallel.

[0019] In one embodiment of the present invention, such as Figure 2The diagram illustrates the main file upload process in this embodiment of the invention, including file preprocessing, resource assessment, RPA (Robotic Process Automation) robot design, and collaborative upload. Specifically, file preprocessing is the starting point of the entire process, involving extracting the attribute information of the files to be uploaded and establishing a mapping relationship between them and the upload location on the target server. All information is recorded in a centralized management file, laying the data foundation for automation. Then, the resource assessment stage proceeds, determining the optimal parallel upload strategy through dynamic testing and analysis of the current system environment. Based on the determined parallel upload strategy, the RPA robot design stage begins, designing and building a robot program that can automatically simulate manual browser operation according to the determined business logic and operation steps. Finally, in the collaborative upload stage, the RPA robot drives multiple browser tabs to upload all files to the target server in parallel and collaboratively according to pre-assigned tasks, thereby maximizing upload efficiency. The following will combine... Figure 2 The processing flow shown provides a detailed explanation of the file upload method of this embodiment of the invention.

[0020] In this embodiment of the invention, a mapping relationship between the file to be uploaded and the upload location on the target server can be determined, and the attribute information of the file to be uploaded and the mapping relationship can be recorded in a centralized management file. The attribute information may include file size and file type. Furthermore, to meet the different urgency requirements of file processing in business operations, this embodiment of the invention introduces a file upload priority mechanism. A "Priority" field can be added to the centralized management file. The priority setting can be based on one or more of the following dimensions: File type: for example, configuration files and emergency patches can be set to "high" priority; daily log files can be set to "low" priority; File size: can be set according to a strategy of "smaller files, higher priority" (quickly completing small tasks) or "larger files, higher priority" (avoiding large task blocking); Business urgency: priority levels can be specified according to the explicit requirements of the business department, such as "urgent," "high," "medium," and "low." Weights can be assigned to each dimension, and a comprehensive priority score can be obtained through weighted calculation, or the corresponding rule engine can be directly used to map to a preset priority level, such as 1-5 levels, with 1 being the highest priority.

[0021] In this embodiment of the invention, the file to be uploaded can be processed first. During processing, the attribute information of the offline file to be uploaded can be processed according to the requirements of the target server. The file attribute information may include file type, size, storage location, file name information, file number, etc. Using this attribute information, the matching relationship between the file to be uploaded and the upload location on the target server can be found. Typically, the file to be uploaded and the upload location on the target server have a uniquely associated field, Data Code Id. This field is a unique file number contained in the file content or attribute information, preset according to a uniform rule. The target server usually establishes a work order list based on the Data Code Id, corresponding one-to-one with local files. Through these work orders, the corresponding local files can be quickly matched offline.

[0022] In one example, files to be uploaded can be preprocessed. First, a new folder can be created on the computer to store all files to be uploaded, enabling centralized file management. Then, the Data Code ID field can be determined based on the target server and file content attribute information, and the filenames can be uniformly modified to include the Data Code ID field. The centralized management file can be displayed in, but is not limited to, Excel format for easy retrieval and updating later. After uniformly modifying the filenames, the file information of the files to be uploaded can be read, including file path, filename, Data Code ID field, file size, file type, and other attribute information, and recorded line by line in the centralized management file. This ensures that the attribute information and mapping relationships of all files to be uploaded are recorded, laying the foundation for subsequent automated uploads. In the attribute information of the files to be uploaded, the file size is in bytes, and the file type is represented using encoding. This information can be used as input for subsequent resource evaluation and pre-trained machine learning models.

[0023] In one embodiment of the present invention, the target number of browser tabs that can be opened simultaneously for file upload can be determined by dynamically traversing the test, and the browser type, actual upload speed and target server response time obtained in the test are recorded as environmental parameters in a centralized management file.

[0024] In this embodiment of the invention, the optimal number of independent processes and threads can be determined by assessing the current resource status. Specifically, the optimal number of independent processes and threads can be determined by assessing factors such as computer system resource status and webpage loading speed, thereby determining the optimal number of browser tabs that can be opened simultaneously. The speed of uploading a single file to the target server is affected by various factors, including network bandwidth during upload, network congestion, website server performance, webpage loading speed, file size, network quality, browser performance, and client hardware performance. In addition to these factors, fully utilizing the browser's multi-threading capabilities can greatly improve upload efficiency.

[0025] In this embodiment of the invention, the target number of browser tabs can be determined through dynamic traversal testing. Specifically, the number of browser tabs simultaneously uploading files can be increased incrementally, and the total time required to upload the specified file is tested after each increase. When the total time exceeds a preset waiting threshold, the increase in the number of browser tabs simultaneously uploading files stops, and the maximum number of browser tabs that did not cause the total time to exceed the preset waiting threshold is determined as the maximum number that can be opened simultaneously. Based on a pre-trained machine learning model used to establish the mapping relationship between the number of browser tabs and the total file upload time, the optimal number of tabs is calculated, and the smaller of the optimal number and the maximum number is selected as the target number.

[0026] As can be seen from the above embodiments of the invention, the dynamic traversal algorithm can dynamically determine the optimal browser type and the maximum number of tabs through experimental testing, combined with mathematical models and prediction algorithms. The first step is to use RPA to open any locally installed browser. The second step is to allow the browser to open n upload pages simultaneously in new tabs, upload test files, and record the time it takes for all files on all n pages to be successfully uploaded. The initial value of n is 1. The third step is to set the upload waiting time threshold. If the upload time of files in n tabs is... Less than the waiting time threshold If the result is positive, then n is incremented by 1; otherwise, the algorithm terminates. Fourth step: Repeat steps two and three above until the algorithm terminates, recording the maximum number of open tabs Nmax and the successful upload time. Then close n tabs. Here... It is a preset value. For example, in testing, it can be set to 600 seconds to prevent system lag or upload failure due to too many tabs.

[0027] This invention can introduce a pre-trained machine learning model to predict the optimal number of tabs based on existing test results. Specifically, this invention can introduce a pre-trained machine learning model and determine the optimal number of tabs based on the maximum number and the pre-trained machine learning model. The pre-trained machine learning model is trained based on the different number of tabs recorded in historical dynamic traversal tests and the corresponding total upload time, and is incrementally updated based on the actual number of tabs recorded after each file upload task is completed, along with the total upload time.

[0028] Specifically, an original model can be determined based on a machine learning-based regression model, and trained using a dataset recorded during historical dynamic traversal tests. The dataset can include multiple data samples. These data samples can include the number of sample tags as input features, and the actual total upload time corresponding to the number of sample tags as the prediction target. After training the original model, the trained model can be incrementally updated using the actual number of tags and the total upload time recorded after each file upload task, resulting in the aforementioned pre-trained machine learning model.

[0029] After obtaining the pre-trained machine learning model, the browser type, actual upload speed, target server response time, and attribute information of the file to be uploaded obtained in the test can be used as input features. These can be input into the pre-trained machine learning model to obtain the total predicted file upload time under different numbers of tabs. The number of tabs corresponding to the shortest predicted total file upload time is determined as the optimal number of tabs.

[0030] Specifically, a function can be defined. This represents the predicted total file upload time as the number of tabs n increases. The changing trend. To make the prediction results more accurate, precise pre-trained machine learning models, such as support vector regression models or neural network models, can be used to fit the data. The formula can be expressed as:

[0031] Here, X is the feature matrix, which includes factors such as file size, file type, browser type, upload speed, and target server response time. For example, the feature matrix X is constructed as follows: .here, It represents the file size in bytes; it is a numerical characteristic, and the file size value is used directly. The file type is represented using one-hot encoding. For example, if there are m file types, such as PDF, DOCX, and TXT, then... It is an m-dimensional vector, where only one element is 1 and the rest are 0, indicating the type of the file; This represents the browser type, also using one-hot encoding. For example, if there are p browser types, such as Google Chrome, Firefox, and Edge, then... It is a p-dimensional vector, where only one element is 1 and the rest are 0, representing the browser type; It represents upload speed, measured in bits per second, and is a numerical characteristic. This represents the target server's response time, measured in milliseconds, and is a numerical characteristic. For example, suppose there are three file types: PDF, DOCX, and TXT, and three browsers: Google Chrome, Firefox, and Edge. A file is 1,000,000 bytes in size, of type PDF, uploaded using Google Chrome at a speed of 100,000 bps, and the target server's response time is 200 ms. Then... =1,000,000 =[1,0,0] (because PDF is the first type). =[1,0,0] (because Google Chrome was the first browser). =100000, =200. Therefore, the characteristic matrix... It can be represented as = [1000000, 1, 0, 0, 1, 0, 0, 100000, 200]. This characteristic matrix It can comprehensively consider multiple influencing factors, thereby improving the accuracy of prediction.

[0032] In this embodiment of the invention, a pre-trained machine learning model can be trained based on the feature matrix X and historical test data. Then, calculate the optimal number of tabs. The formula is:

[0033] Right now, Is to make The minimum value of n is found. The solution process includes building a pre-trained machine learning model. For example, after training with an SVR model, It might be a function of n; then calculate... derivative with respect to n Solve the equation Find the extreme points and confirm whether they are minimum points. For example, suppose... Approximated by a simple quadratic function model:

[0034] Where a, b, and c are model parameters, obtained by fitting the model to the training data. Then the derivative... Solve the equation The extreme point is obtained. If the coefficient of the quadratic term a > 0, then this extreme point is also a minimum point. Finally, comparison and the maximum number obtained from the experiment :if Then choose As the optimal number of tabs; otherwise, select... This is to ensure optimal performance within practical constraints.

[0035] In one embodiment of the present invention, before determining the target number through dynamic traversal testing, multiple locally installed browsers can be used sequentially to perform dynamic traversal testing to obtain the total time taken by all browsers to complete all test file upload tasks. Then, the browser with the smallest total time among the obtained total times can be determined as the browser that performs the file upload operation of the file to be uploaded.

[0036] Specifically, other locally installed browsers, such as Google Chrome, Firefox, IE, 360, Opera, and Microsoft Edge, can be opened sequentially to repeat the dynamic traversal test described in the above embodiments. The most efficient browser is determined based on the number of files to be uploaded, the maximum number of browser tabs, and the upload success time. For example, the test environment parameters could be: a local computer running Win10 64-bit, a target server platform response time of approximately 1.3 seconds, test file sizes of 20MB, 40MB, 80MB, and 160MB, file type as PDF, upload speed of 0.5~0.9 Mbit / s, and a waiting time threshold. The test duration is set to 600 seconds. The results are displayed in chart format, such as... Figure 3 As shown, Figure 3 The horizontal axis represents the number of browser tabs open simultaneously, and the vertical axis represents the total file upload time in seconds, including curves for different browsers such as Google Chrome, Firefox, and Microsoft Edge. From... Figure 3The following conclusions can be drawn: 1. Google Chrome browser has the shortest upload time and the highest upload efficiency; its curve is located at the bottom of the chart, indicating that it has the shortest upload time with the same number of tabs; 2. When there is an upload task, Google Chrome, Microsoft Edge, and IE browsers can open a maximum of 10 tabs simultaneously, i.e. =10; other browsers (such as Firefox and Opera) can only open fewer than 10 tabs simultaneously. When the number of tabs exceeds... At that time, the chart showed a sharp rise in the curve, indicating a significant slowdown, and the upload time of a certain tab exceeded the waiting time threshold. This caused the upload task to fail; 3. When the number of new tabs opened is less than At that time, the upload speed of a single file is negatively correlated with the file size, meaning that the larger the file, the longer the upload time; however, the number of open tabs has little impact on the upload speed of a single file. Figure 2 The growth curve is relatively flat; under the same conditions, when the number of tabs is less than... At that time, the number of open tabs is a direct factor affecting the overall file upload speed. Figure 3 The total upload time shows a slow increase with the number of tabs. Based on these test results, specific browser information, such as Google Chrome, and maximum tab count information can be used. Update to the centralized management file, and follow the instructions. The uploaded files are grouped line by line, and each file is assigned a Group ID to facilitate subsequent parallel uploads.

[0037] In one example, such as Figure 4The diagram illustrates the process of dynamic traversal testing, model prediction, and decision-making described above. Specifically, first, a browser is opened, and an upload test is performed, collecting raw performance data through actual upload operations. After obtaining the test data, the number of tabs can be evaluated. During evaluation, the maximum number of tabs that can be stably supported can be identified by monitoring the total upload time under different concurrent tab counts. Then, a pre-trained machine learning model can be built for accurate prediction. Machine learning algorithms can be used to model and analyze multi-dimensional environmental parameters such as browser type, upload speed, and response time to predict the theoretical upload efficiency under different tab counts. The model output will help determine the optimal number of tabs, i.e., the number of concurrent uploads that minimizes overall upload time while ensuring stability. Simultaneously, during the test, a browser can be selected; by comparing the performance of different browsers under the same test conditions, the optimal browser for the current environment is selected. Finally, based on the evaluation and selection results, grouped uploads can be performed, providing precise concurrency guidance and browser type configuration for the upcoming parallel upload tasks.

[0038] In one embodiment of the present invention, based on the mapping relationship, an RPA robot can be used to operate a browser to log in to the target server and open the target number of tabs at the same time.

[0039] In this embodiment of the invention, an RPA designer component can be used for interface element identification and location. Specifically, firstly, OCR technology or HTML parsing can be used to identify and locate interface elements, including operations such as opening a browser, opening a browser tab, locating the file upload interface, clicking a button, locating a folder, reading and writing centrally managed files, and waiting for the upload to complete. This ensures that the RPA robot can accurately simulate human operations and avoid incorrect or missed selections. Then, the RPA designer can be used for business process analysis and modeling. By analyzing the operational logic and steps of the target server and combining the interface element identification results, a drag-and-drop design and modeling of the RPA visual process can be performed, forming a clear and executable set of operational steps. These steps include locating the file upload interface using a browser tab, clicking the file upload button, reading centrally managed file information, uploading the file, recording the upload, and closing the window after the file is uploaded. Since RPA requires clear operational steps to be implemented, it must be refined down to each step of the target server's upload function module. For example, logging into the system first, then navigating to the upload page, and then selecting a file. Then, based on business process modeling, rules and decision-making processes such as exception handling, condition judgment, waiting for refresh and display, and delay waiting can be provided, enabling RPA robots to take expected actions when facing various complex situations. For example, if the upload fails, it can automatically retry or log to ensure that the upload is completed smoothly.

[0040] After completing the RPA robot design described above, the optimal browser type, such as Google Chrome, and the optimal number of tabs can be determined. For example, 10. Start the robot, automatically open the browser, and simultaneously open... Each tab leads to the upload interface on the target server.

[0041] In this embodiment of the invention, a dynamic concurrency adjustment mechanism based on server load feedback can be introduced to ensure that the upload process optimizes efficiency while taking into account the stability of the target server, and avoids server overload due to excessive concurrency.

[0042] Specifically, during the process of the RPA robot controlling all tabs to perform file upload operations in parallel, the load feedback indicators of the target server can be monitored in real time. These indicators may include, but are not limited to: the rate of change of server response time, that is, the rate at which server response latency increases per unit time; the error rate or failure rate of upload requests: such as the frequency of occurrence of HTTP 5xx status codes; specific error codes: such as "Server Busy" (HTTP 503), etc.

[0043] Based on the above load feedback, the actual number of concurrent tabs running can be dynamically adjusted, i.e., the current effective concurrency. Its adjustment strategies may include: 1. Load Assessment: A safe threshold for server response time can be set. For example, set it to twice the initial response time, and an error rate threshold. During the upload process, the average response time and error rate are calculated periodically (e.g., every 30 seconds).

[0044] 2. Dynamic Degradation: If the average response time is continuously exceeded... or error rate exceeding If this is the case, the server is likely under high load. In this situation, the number of concurrent tabs can be automatically reduced, for example, by... Halve the concurrency (but not lower than 1) to reduce server load. By reducing concurrency, you can pause initiating new upload tasks and prioritize processing tasks that are already in progress.

[0045] 3. Gradual Recovery: After reducing concurrency and waiting for a cooldown period (e.g., 60 seconds), the server status can be reassessed. If response time and error rate return to normal levels, try gradually increasing the concurrency (e.g., adding one tab at a time), slowly restoring to the previously determined optimal number. or By focusing on the vicinity, we can continuously explore the optimal solution for efficiency while ensuring server stability.

[0046] The above-mentioned feedback mechanism enables the embodiments of the present invention to no longer rely solely on initial static testing, but to sense environmental changes and make intelligent responses, making them well applicable to shared enterprise server environments with frequent load fluctuations.

[0047] In one embodiment of the present invention, upload tasks can be assigned to open tabs based on attribute information, mapping relationships, and environmental parameters recorded in a centralized management file, and the RPA robot controls all open tabs to perform file upload operations in parallel.

[0048] In this embodiment of the invention, an RPA robot can be invoked to work collaboratively based on the optimal number of tabs, utilizing the browser's multi-process and threading capabilities to perform parallel tasks and improve upload efficiency. Using browser tabs allows for simple and direct use of multi-processing and threading for tasks. Specifically, based on the optimal browser type and the optimal number of tabs obtained above for uploading files, the optimal number of tabs is determined. Start the robot, automatically open the browser, and simultaneously open... Each tab is a separate page. Each tab directs users to the upload ticket interface for their respective server file based on the Data Code ID. The Data Code ID serves as a unique identifier, ensuring the file and server location are correctly matched.

[0049] In one embodiment of the present invention, when assigning upload tasks to open tabs, a set of upload tasks with different mapping relationships can be assigned to each open tab according to the mapping relationship recorded in the centralized management file.

[0050] In assigning upload tasks to open tabs, file priorities can be fully considered. Specifically, after reading the upload task list from the centralized management file, the entire task list can be sorted according to preset priority rules. After sorting, the RPA robot can prioritize high-priority tasks and assign them to idle browser tabs. That is, the robot can control the tab to prioritize locating and uploading the work order interface corresponding to the highest-priority file. After each tab uploads a file, it is not fixed to a certain group, but immediately requests the next highest-priority available task from the globally sorted task queue. This method ensures that even if a high-priority file is added to the task list late, it will always be processed first. By introducing a priority mechanism, this embodiment of the invention can achieve intelligent task scheduling, ensuring that critical business files are uploaded first.

[0051] In this embodiment of the invention, an RPA robot can control each open tab, locate the corresponding upload interface of the target server according to the assigned mapping relationship, and upload all files in the assigned set of upload tasks in sequence.

[0052] Specifically, Each tab corresponds to a Group ID for each task, and the robot is responsible for file uploads within that group. Files with different Data Code IDs corresponding to the same Group ID in the centrally managed file are uploaded to the server, and upload status information is recorded for each file. Regardless of whether a file upload is successful, the robot navigates to the next Data Code ID's upload interface within the same tab and continues uploading the next matching file until all files with the same Group ID have been uploaded. This allocation method ensures parallelism while avoiding the overhead of frequent tab switching. For example, if... =10. If there are 100 files in the centralized management file, the files are divided into 10 groups, with Group IDs ranging from 1 to 10. Each tab processes a group of 10 files, which are uploaded sequentially.

[0053] In one embodiment of the present invention, after the RPA robot controls all open tabs and performs file upload operations in parallel, the upload status of each file can be monitored, and for files that fail to upload, the upload task can be re-initiated until all files are successfully uploaded to the target server.

[0054] Specifically, the robot only initiates re-upload tasks for the Group ID containing the files that failed to upload, continuing this process until all uploaded files are successfully uploaded. This enhances the error handling mechanism and improves system stability and reliability. For example, if a file fails to upload due to network fluctuations, the RPA robot will detect the failure and automatically re-trigger the re-upload for the group containing that file until it succeeds. Meanwhile, centralized file management updates the upload status in real time, facilitating monitoring and auditing.

[0055] In this embodiment of the invention, firstly, the mapping relationship between the file to be uploaded and the upload location on the target server is determined, and the attribute information of the file to be uploaded and this mapping relationship are recorded in a centralized management file. Then, through dynamic traversal testing, the target number of browser tabs that can be opened simultaneously for file uploads is determined, and the browser type, actual upload speed, and target server response time obtained during the test are recorded as environmental parameters in the same centralized management file. Based on the recorded mapping relationship, an RPA robot is used to operate the browser to log in to the target server and simultaneously open the target number of tabs. Finally, according to the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file, upload tasks are assigned to all open tabs, and the RPA robot controls these tabs to perform file upload operations in parallel.

[0056] This invention enables the construction of a fully automated upload process, from centralized file information management and dynamic environment testing and optimization to RPA-driven parallel execution of multiple tasks. This solves the problems of low processing efficiency and high error rates caused by the complete reliance on manual operation in existing methods. By introducing dynamic traversal testing, real-time evaluation of the current network environment, browser performance, and server responsiveness is achieved. Based on the evaluation results, the optimal number of concurrent tabs is intelligently determined, overcoming the technical shortcomings of traditional fixed-concurrency modes, which suffer from insufficient resource utilization or overload crashes due to their inability to adapt to dynamic environments. This fundamentally improves the efficiency and stability of batch uploads. Through RPA robots automatically operating the browser and centralized management of file-driven task allocation, a complete and reliable automated closed loop is achieved from file identification and environment adaptation to batch uploads. This completely solves the problems of cumbersome operation, error-proneness, and lack of reliable state management and error recovery mechanisms in existing technologies due to frequent manual intervention.

[0057] Figure 5 The file upload device 500 shown can achieve Figure 1 The method described in the embodiment achieves the same technical effect, and can be specifically referred to in the above description. Figure 1 The file upload method of the illustrated embodiment will not be described in detail here. The file upload device 500 includes: The first determining module 501 is used to determine the mapping relationship between the file to be uploaded and the upload location of the target server, and to record the attribute information of the file to be uploaded and the mapping relationship in a centralized management file; the attribute information includes file size and file type; The second determining module 502 is used to determine the target number of browser tabs that can be opened simultaneously for file upload by dynamically traversing the test, and to record the browser type, actual upload speed, and target server response time obtained in the test as environmental parameters in the centralized management file. The control module 503 is used to log in to the target server using a robot browser operated by a robot in the Robotic Process Automation (RPA) system based on the mapping relationship, and simultaneously open the target number of tabs. The allocation module 504 is used to allocate upload tasks to open tabs according to the attribute information, mapping relationship and environmental parameters recorded in the centralized management file, and the RPA robot controls all open tabs to perform file upload operations in parallel.

[0058] Optionally, the second determining module 502 is used to: The number of browser tabs that can upload files simultaneously is increased incrementally, and the total time required to upload a specified file is tested after each increase. When the total duration exceeds a preset waiting threshold, the number of browser tabs that are simultaneously uploading files will stop increasing, and the maximum number of browser tabs that do not cause the total duration to exceed the preset waiting threshold will be determined as the maximum number that can be opened simultaneously. The optimal number of tabs is calculated based on a pre-trained machine learning model. The pre-trained machine learning model is trained based on the different number of tabs recorded in historical dynamic traversal tests and the corresponding total upload time, and is incrementally updated based on the actual number of tabs recorded after each file upload task is completed and the total upload time. The smaller of the optimal number of tabs and the maximum number is selected as the target number.

[0059] Optionally, the second determining module 502 is used to: The original model is determined based on the machine learning-based regression model; The original model is trained using the dataset recorded in the historical dynamic traversal test, and the trained model is incrementally updated using the actual number of tabs and the total upload time recorded after each file upload task is completed, to obtain the pre-trained machine learning model; the dataset includes multiple data samples; the data samples include the number of sample tabs as input features, and the actual total upload time corresponding to the number of sample tabs as the prediction target; The browser type, actual upload speed, target server response time, and attribute information of the file to be uploaded obtained in the test are used as input features and input into the pre-trained machine learning model to obtain the total predicted file upload time under different number of tabs output by the pre-trained machine learning model. The number of tabs corresponding to the shortest predicted total upload time for the file is determined as the optimal number of tabs.

[0060] Optionally, the allocation module 504 is used for: Based on the mapping relationship recorded in the centralized management file, a set of upload tasks with different mapping relationships are assigned to each open tab; The RPA robot controls each opened tab, locates the corresponding upload interface of the target server according to the assigned mapping relationship, and uploads all files in the assigned set of upload tasks in sequence.

[0061] Optionally, the device further includes ( Figure 5 (not shown in the image) The monitoring module 505 is used to monitor the upload status of each file after the RPA robot controls all open tabs to perform file upload operations in parallel. The retransmission module 506 is used to re-initiate the upload task for files that failed to upload, until all files are successfully uploaded to the target server.

[0062] Optionally, the second determining module 502 is used for: Before determining the target number, the dynamic traversal test was performed sequentially using multiple locally installed browsers. Get the total time taken for all browsers to complete all test file upload tasks; The browser with the smallest total time value among the obtained total time is determined as the browser that will perform the file upload operation for the file to be uploaded.

[0063] In this embodiment of the invention, firstly, the mapping relationship between the file to be uploaded and the upload location on the target server is determined, and the attribute information of the file to be uploaded and this mapping relationship are recorded in a centralized management file. Then, through dynamic traversal testing, the target number of browser tabs that can be opened simultaneously for file uploads is determined, and the browser type, actual upload speed, and target server response time obtained during the test are recorded as environmental parameters in the same centralized management file. Based on the recorded mapping relationship, an RPA robot is used to operate the browser to log in to the target server and simultaneously open the target number of tabs. Finally, according to the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file, upload tasks are assigned to all open tabs, and the RPA robot controls these tabs to perform file upload operations in parallel.

[0064] This invention enables the construction of a fully automated upload process, from centralized file information management and dynamic environment testing and optimization to RPA-driven parallel execution of multiple tasks. This solves the problems of low processing efficiency and high error rates caused by the complete reliance on manual operation in existing methods. By introducing dynamic traversal testing, real-time evaluation of the current network environment, browser performance, and server responsiveness is achieved. Based on the evaluation results, the optimal number of concurrent tabs is intelligently determined, overcoming the technical shortcomings of traditional fixed-concurrency modes, which suffer from insufficient resource utilization or overload crashes due to their inability to adapt to dynamic environments. This fundamentally improves the efficiency and stability of batch uploads. Through RPA robots automatically operating the browser and centralized management of file-driven task allocation, a complete and reliable automated closed loop is achieved from file identification and environment adaptation to batch uploads. This completely solves the problems of cumbersome operation, error-proneness, and lack of reliable state management and error recovery mechanisms in existing technologies due to frequent manual intervention.

[0065] Figure 6 This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application. Please refer to it. Figure 6At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and memory. The memory may include main memory, such as high-speed random-access memory (RAM), or non-volatile memory, such as at least one disk drive. Of course, the electronic device may also include other hardware required for other business operations.

[0066] The processor, network interface, and memory can be interconnected via an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 6 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.

[0067] Memory is used to store programs. Specifically, programs may include program code, which includes computer operation instructions. Memory may include main memory and non-volatile memory, and provides instructions and data to the processor.

[0068] The processor reads the corresponding computer program from non-volatile memory into main memory and then executes it, forming a non-contiguous transfer configuration at the logical level. The processor executes the program stored in memory and specifically performs the following operations: The mapping relationship between the file to be uploaded and the upload location on the target server is determined, and the attribute information of the file to be uploaded and the mapping relationship are recorded in a centralized management file; the attribute information includes file size and file type; By dynamically traversing the test, the target number of browser tabs that can be opened simultaneously for file upload is determined, and the browser type, actual upload speed, and target server response time obtained in the test are recorded as environmental parameters in the centralized management file. Based on the mapping relationship, the Robotic Process Automation (RPA) robot is used to log in to the target server via a browser and simultaneously open the target number of tabs. Based on the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file, upload tasks are assigned to the open tabs, and the RPA robot controls all open tabs to perform file upload operations in parallel.

[0069] The above is as stated in this application. Figure 1 The file upload method disclosed in the embodiments described above can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The processor can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in one or more embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in one or more embodiments of this application can be directly embodied in the execution of a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software module can reside in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method.

[0070] The electronic device can also perform Figure 1 The file upload method described herein will not be repeated here.

[0071] This application also proposes a computer-readable storage medium that stores one or more programs, the programs including instructions that, when executed by a portable electronic device including multiple applications, enable the portable electronic device to perform... Figure 1 The methods of the embodiments shown are not described in detail here.

[0072] This application also proposes a computer program product, which is stored in a storage medium and executed by at least one processor to implement... Figure 1 The methods of the embodiments shown are not described in detail here.

[0073] Of course, in addition to software implementation, the electronic device of this application does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. In other words, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.

[0074] In summary, the above description is merely a preferred embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of one or more embodiments of this application should be included within the scope of protection of one or more embodiments of this application.

[0075] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, a computer can be, for example, a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or any combination of these devices.

[0076] Computer-readable media, including both permanent and non-permanent, removable and non-removable media, can store information using any method or technology. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined in the embodiments of this application, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0077] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0078] The various embodiments in this application are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions of the method embodiments.

Claims

1. A file upload method, characterized in that, include: The mapping relationship between the file to be uploaded and the upload location on the target server is determined, and the attribute information of the file to be uploaded and the mapping relationship are recorded in a centralized management file; the attribute information includes file size and file type; By dynamically traversing the test, the target number of browser tabs that can be opened simultaneously for file upload is determined, and the browser type, actual upload speed, and target server response time obtained in the test are recorded as environmental parameters in the centralized management file. Based on the mapping relationship, the Robotic Process Automation (RPA) robot is used to log in to the target server via a browser and simultaneously open the target number of tabs. Based on the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file, upload tasks are assigned to the open tabs, and the RPA robot controls all open tabs to perform file upload operations in parallel.

2. The method according to claim 1, characterized in that, The process of determining the target number of browser tabs that can be opened simultaneously for file uploads through dynamic traversal testing includes: The number of browser tabs that can upload files simultaneously is increased incrementally, and the total time required to upload a specified file is tested after each increase. When the total duration exceeds a preset waiting threshold, the number of browser tabs that are simultaneously uploading files will stop increasing, and the maximum number of browser tabs that do not cause the total duration to exceed the preset waiting threshold will be determined as the maximum number that can be opened simultaneously. The optimal number of tabs is calculated based on a pre-trained machine learning model. The pre-trained machine learning model is trained based on the different number of tabs recorded in historical dynamic traversal tests and the corresponding total upload time, and is incrementally updated based on the actual number of tabs recorded after each file upload task is completed and the total upload time. The smaller of the optimal number of tabs and the maximum number is selected as the target number.

3. The method according to claim 2, characterized in that, The calculation of the optimal number of tabs based on the pre-trained machine learning model includes: The original model is determined based on the machine learning-based regression model; The original model is trained using the dataset recorded in the historical dynamic traversal test, and the trained model is incrementally updated using the actual number of tabs and the total upload time recorded after each file upload task is completed, to obtain the pre-trained machine learning model; the dataset includes multiple data samples; the data samples include the number of sample tabs as input features, and the actual total upload time corresponding to the number of sample tabs as the prediction target; The browser type, actual upload speed, target server response time, and attribute information of the file to be uploaded obtained in the test are used as input features and input into the pre-trained machine learning model to obtain the total predicted file upload time under different number of tabs output by the pre-trained machine learning model. The number of tabs corresponding to the shortest predicted total upload time for the file is determined as the optimal number of tabs.

4. The method according to claim 1, characterized in that, Assigning upload tasks to the opened tabs includes: Based on the mapping relationship recorded in the centralized management file, a set of upload tasks with different mapping relationships are assigned to each open tab; The RPA robot controls each opened tab, locates the corresponding upload interface of the target server according to the assigned mapping relationship, and uploads all files in the assigned set of upload tasks in sequence.

5. The method according to claim 1, characterized in that, After the RPA robot controls all open tabs to perform file upload operations in parallel, the method further includes: Monitor the upload status of each file; For files that fail to upload, re-initiate the upload task until all files are successfully uploaded to the target server.

6. The method according to claim 1, characterized in that, The process of determining the target number of browser tabs that can be opened simultaneously for file uploads through dynamic traversal testing includes: Before determining the target number, the dynamic traversal test was performed sequentially using multiple locally installed browsers. Get the total time taken for all browsers to complete all test file upload tasks; The browser with the smallest total time value among the obtained total time is determined as the browser that will perform the file upload operation for the file to be uploaded.

7. A file upload device, characterized in that, include: The first determining module is used to determine the mapping relationship between the file to be uploaded and the upload location of the target server, and to record the attribute information of the file to be uploaded and the mapping relationship in a centralized management file; the attribute information includes file size and file type; The second determination module is used to determine the target number of browser tabs that can be opened simultaneously for file upload by dynamically traversing the test, and to record the browser type, actual upload speed, and target server response time obtained in the test as environmental parameters in the centralized management file. The control module is used to log in to the target server using a robot browser operated by a robot in the Robotic Process Automation (RPA) system based on the mapping relationship, and simultaneously open the target number of tabs. The allocation module is used to allocate upload tasks to open tabs based on the attribute information, mapping relationship, and environmental parameters recorded in the centralized management file. The RPA robot controls all open tabs to perform file upload operations in parallel.

8. An electronic device, characterized in that, include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the method as described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium is used to store computer-executable instructions that, when executed by a processor, implement the steps of the method described in any one of claims 1 to 6.

10. A computer program product, characterized in that, The computer program product includes a computer program that, when executed by a processor, implements the steps of the method described in any one of claims 1 to 6.