CN109542640B - Picture uploading method and device, computer equipment and storage medium - Google Patents

Picture uploading method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN109542640B
CN109542640B CN201811346905.9A CN201811346905A CN109542640B CN 109542640 B CN109542640 B CN 109542640B CN 201811346905 A CN201811346905 A CN 201811346905A CN 109542640 B CN109542640 B CN 109542640B
Authority
CN
China
Prior art keywords
thread
uploaded
pictures
current
picture
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811346905.9A
Other languages
Chinese (zh)
Other versions
CN109542640A (en
Inventor
何兵
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201811346905.9A priority Critical patent/CN109542640B/en
Publication of CN109542640A publication Critical patent/CN109542640A/en
Application granted granted Critical
Publication of CN109542640B publication Critical patent/CN109542640B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/543User-generated data transfer, e.g. clipboards, dynamic data exchange [DDE], object linking and embedding [OLE]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5011Pool
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/541Client-server
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a picture uploading method, a picture uploading device, computer equipment and a storage medium. The method comprises the following steps: if a picture uploading instruction is detected, acquiring a current network connection state and correspondingly acquiring the maximum thread number, and creating a thread pool with the thread number being the maximum thread number; judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool; if the number of the pictures is larger than the number of the idle threads in the thread pool, obtaining the pictures to be uploaded, and storing the pictures to be uploaded in an array by taking the pictures as a request body; transmitting the stored request body to a server through threads corresponding to the array, and subtracting the idle thread number of the thread pool from the current residual number to update the current residual number; and if the current number of the remaining pictures is not equal to 0, executing the step of judging whether the current number of the remaining pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool. The method realizes the maximum utilization of network resources, thereby improving the image uploading efficiency and effectively reducing the memory occupancy rate.

Description

Picture uploading method and device, computer equipment and storage medium
Technical Field
The present invention relates to the field of cloud storage technologies, and in particular, to a method and apparatus for uploading a picture, a computer device, and a storage medium.
Background
In the conventional process of uploading pictures by using the mobile terminal iOS system (iOS system is an operating system developed by apple corporation) occupies a large amount of share, the pictures to be uploaded are transferred into a memory, that is, the pictures to be uploaded are directly copied and packaged into a request body when uploaded, and then sent to a background server (which can be understood as a cloud server). Under normal conditions, the memory meets the uploading requirement when uploading small batches of pictures at one time, but if a large batch of pictures (more than 100 pictures) are required to be uploaded, the following problems still exist by using a conventional method:
1. the memory does not meet the use requirement, because the size of the picture in the memory is related to the length, width and byte number occupied by unit pixel of the picture, one 1500 x 1500 picture occupies about 2M of the memory, and in the uploading process, one copy is copied to a request body, and other places such as preview are needed to be used, and the uploading of 100 pictures 1500 x 1500 may need more than 600M of memory;
2. the efficiency is low, too few threads are started to cause the network bandwidth to be fully utilized, and too many threads are started to cause the system allocation to be laborious;
3. Uncontrollable, once the picture uploading is started, the picture uploading cannot be canceled and paused.
Disclosure of Invention
The embodiment of the invention provides a picture uploading method, a device, computer equipment and a storage medium, which aim to solve the problems that a large amount of picture memories uploaded in the prior art cannot meet the use requirement and the efficiency of an uploading process is low due to the fact that network bandwidth cannot be effectively utilized.
In a first aspect, an embodiment of the present invention provides a method for uploading a picture, including:
if a picture uploading instruction is detected, acquiring a current network connection state, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool;
judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool;
if the current number of remaining pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies and stored in an array; the request body at least comprises a target address and original picture data for uploading pictures;
Transmitting the request body stored in each array to a server through threads corresponding to each array, and subtracting the idle thread number of the thread pool from the current remaining number of sheets to update the current remaining number of sheets;
judging whether the current number of the remaining sheets is equal to 0, if the current number of the remaining sheets is not equal to 0, executing the step of judging whether the current number of the remaining sheets of the picture to be uploaded is larger than the idle thread number of the thread pool in the thread pool; if the current number of the remaining sheets is equal to 0, ending the flow;
and if the current number of the remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, packaging each picture to be uploaded into a corresponding request body, storing the corresponding request body in an array, and sending the request bodies stored in each array to a server through threads corresponding to each array.
In a second aspect, an embodiment of the present invention provides a device for uploading a picture, including:
the thread pool creation unit is used for acquiring the current network connection state if the picture uploading instruction is detected, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool;
The comparison unit is used for judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool;
the picture packaging unit is used for obtaining pictures to be uploaded, of which the number of pictures is equal to the number of idle threads in the thread pool, if the current number of remaining pictures to be uploaded is larger than the number of idle threads in the thread pool, so as to package the pictures to be uploaded into corresponding request bodies and store the corresponding request bodies in an array; the request body at least comprises a target address and original picture data for uploading pictures;
the first request body sending unit is used for sending the request bodies stored in each array to a server through threads corresponding to each array, and subtracting the idle thread numbers of the thread pools from the current remaining number of the sheets so as to update the current remaining number of the sheets;
the current remaining number judging unit is used for executing the step of judging whether the current remaining number of the pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool if the current remaining number of the pictures is not equal to 0; if the current number of the remaining sheets is equal to 0, ending the flow;
and the second request body sending unit is used for packaging each picture to be uploaded into a corresponding request body to be stored in an array if the current number of remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, and sending the request bodies stored in each array to a server through threads corresponding to each array.
In a third aspect, an embodiment of the present invention further provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor executes the computer program to implement the method for uploading a picture according to the first aspect.
In a fourth aspect, an embodiment of the present invention further provides a computer readable storage medium, where the computer readable storage medium stores a computer program, where the computer program when executed by a processor causes the processor to perform the method for uploading a picture according to the first aspect.
The embodiment of the invention provides a picture uploading method, a picture uploading device, computer equipment and a storage medium. If a picture uploading instruction is detected, acquiring a current network connection state, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool; judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool; if the current number of remaining pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies and stored in an array; the request body at least comprises a target address and original picture data for uploading pictures; transmitting the request body stored in each array to a server through threads corresponding to each array, and subtracting the idle thread number of the thread pool from the current remaining number of sheets to update the current remaining number of sheets; judging whether the current number of the remaining sheets is equal to 0, if the current number of the remaining sheets is not equal to 0, executing the step of judging whether the current number of the remaining sheets of the picture to be uploaded is larger than the idle thread number of the thread pool in the thread pool; if the current number of the remaining sheets is equal to 0, ending the flow; and if the current number of the remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, packaging each picture to be uploaded into a corresponding request body, storing the corresponding request body in an array, and sending the request bodies stored in each array to a server through threads corresponding to each array. The method realizes the maximum utilization of network resources, thereby improving the image uploading efficiency and effectively reducing the memory occupancy rate.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flow chart of a picture uploading method according to an embodiment of the present invention;
fig. 2 is a schematic sub-flowchart of a picture uploading method according to an embodiment of the present invention;
fig. 3 is another schematic sub-flowchart of a picture uploading method according to an embodiment of the present invention;
fig. 4 is another flow chart of a picture uploading method according to an embodiment of the present invention;
fig. 5 is another flow chart of a picture uploading method according to an embodiment of the present invention;
fig. 6 is a schematic block diagram of a picture uploading device provided by an embodiment of the present invention;
fig. 7 is a schematic block diagram of a subunit of a picture uploading device according to an embodiment of the present invention;
fig. 8 is a schematic block diagram of another subunit of the image uploading apparatus provided in the embodiment of the present invention;
FIG. 9 is another schematic block diagram of a picture uploading device provided by an embodiment of the present invention;
FIG. 10 is another schematic block diagram of a picture uploading device provided by an embodiment of the present invention;
fig. 11 is a schematic block diagram of a computer device according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
It should be understood that the terms "comprises" and "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It is also to be understood that the terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be further understood that the term "and/or" as used in the present specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
Referring to fig. 1, fig. 1 is a flowchart of a picture uploading method according to an embodiment of the present invention, where the picture uploading method is applied to an intelligent terminal, and the method is executed by application software installed in the intelligent terminal.
As shown in fig. 1, the method includes steps S110 to S160.
S110, if a picture uploading instruction is detected, acquiring a current network connection state, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool.
In this embodiment, the application scenario for uploading multiple pictures is: when a user needs to upload a plurality of field photos shot through the intelligent terminal in the claim settlement process, selecting the pictures as pictures to be uploaded to a cloud server corresponding to the claim settlement system so as to perform claim settlement (such as car insurance claim settlement).
Because the plurality of live photos taken by the intelligent terminal are initially stored in the hard disk area (which can be understood as a non-IOS system storage area in the ROM area of the intelligent terminal), the hard disk storage paths (the hard disk storage paths are also known as picture local storage addresses) of the plurality of photos stored in the hard disk area are correspondingly stored in the memory (which can be understood as the RAM area of the intelligent terminal), and thus, the problem that the memory is seriously occupied due to the fact that the pictures to be uploaded are directly loaded into the memory is avoided.
When a picture uploading instruction is detected (that is, a user operates the intelligent terminal and selects a plurality of pictures to be uploaded), the current network connection state needs to be judged first (that is, the intelligent terminal is judged to be in a Wi-Fi connection state or in a non-Wi-Fi connection state, wherein the non-Wi-Fi connection state is generally that the intelligent terminal is connected with a server by using data traffic provided by a communication carrier), different thread strategies are generated according to the current network connection state, and therefore the maximum number of pictures which can be uploaded at a time is controlled.
In one embodiment, as shown in fig. 2, step S110 includes:
s111, judging whether the current network connection state is a Wi-Fi connection state or not;
s112, if the current network connection state is a Wi-Fi connection state, setting the maximum thread number as a preset first thread value;
S113, if the current network connection state is not the Wi-Fi connection state, setting the maximum thread number as a preset second thread value; wherein the second thread value is less than the first thread value.
In this embodiment, the current network connection state of the intelligent terminal is detected and obtained through the IOS system (for example, in the IOS system, the network state is obtained and can be obtained through a system tool provided by an apple, and a specific library is Reachability); different thread policies are generated according to the network conditions: if the current network connection state of the intelligent terminal is a Wi-Fi connection state, the maximum number of opened threads is 5; if the current network connection state of the intelligent terminal is not the Wi-Fi connection state, the maximum number of opened threads is 3; that is, the first thread value is 5 and the second thread value is 3; when in the Wi-Fi connection state, the number of pictures to be uploaded by the intelligent terminal is 5, and when in the non-Wi-Fi connection state, the number of pictures to be uploaded by the intelligent terminal is 3. Through the set maximum thread number, the number of pictures uploaded by the intelligent terminal at a time is effectively limited, the occupation of the memory is reduced, and the network condition is fully considered to generate a corresponding thread policy.
S120, judging whether the current number of remaining pictures to be uploaded is larger than the number of idle threads in the thread pool.
In this embodiment, the initial value of the current number of remaining pictures to be uploaded is generally much larger than the thread Chi Kongxian thread number in the thread pool, the initial value of the current number of remaining pictures to be uploaded is 100, and the maximum value of the thread Chi Kongxian thread number in the thread pool is the maximum thread number (and the maximum thread number is generally set to 3-5).
S130, if the current remaining number of the pictures to be uploaded is greater than the idle thread number of the thread pool, obtaining the pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, so as to package the pictures to be uploaded into corresponding request bodies and store the request bodies in an array; the request body at least comprises a target address for uploading the picture and original picture data.
In this embodiment, the pictures are uploaded in a large batch, so the total number of pictures to be uploaded is a large probability exceeding the maximum thread number (for example, 100 corresponding to 100 pictures to be uploaded is much larger than 5 corresponding to the maximum thread number). If the total number of the pictures to be uploaded is larger than the maximum thread number, firstly, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, according to the sequence of the pictures to be uploaded selected by a user, and then distributing a request body packaged by each picture to be uploaded to a corresponding thread for storage. The picture is converted into the request body, so that the picture is accurately uploaded correspondingly, and the original picture is not directly uploaded.
And if the total number of the pictures to be uploaded is smaller than or equal to the maximum thread number of the thread pool, indicating that the pictures to be uploaded are about to be uploaded. If the total number of pictures to be uploaded is smaller than the current thread Chi Kongxian thread number, directly uploading the rest pictures to be uploaded to a server by randomly distributing an idle state thread pool to a request body; if the total number of the pictures to be uploaded is larger than the current idle thread number of the thread pool, obtaining the pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies, and storing the corresponding request bodies in an array for uploading to a server.
In one embodiment, as shown in fig. 3, step S130 includes:
s131, obtaining pictures to be uploaded, of which the number of pictures is equal to the number of idle threads of a thread pool, from a hard disk according to a picture local storage address stored in a memory;
s132, packaging each picture to be uploaded into a request body, and storing each request body into a corresponding array.
In this embodiment, for example, when the image upload is started initially, the idle thread number of the thread pool is 5, and at this time, 5 images to be uploaded are obtained from the hard disk according to the image local storage address stored in the memory. Each thread in the thread pool receives a request body of a picture to be uploaded, and the request body is uploaded to a server through running the thread so as to realize the picture uploading process.
S140, transmitting the request body stored in each array to a server through threads corresponding to each array, and subtracting the idle thread number of the thread pool from the current remaining number of sheets to update the current remaining number of sheets.
In this embodiment, an array may be understood as a block of memory area in a thread for storing a request bank. Each requestor may be considered a task object, which is a task that is in progress. Creating a request body, packaging the request address, the picture data to be uploaded and other parameters into the request body, calling a starting method corresponding to the request body, and sending the request body out through a network at the bottom layer after the intelligent terminal receives the starting method.
If N (N is a positive integer not more than 5) pictures are uploaded first in the subsequent picture uploading process, the idle thread number of the thread pool is N at this time, and then N pictures to be uploaded are obtained in the hard disk according to the picture local storage address stored in the memory to continue uploading, that is, each time a round of picture uploading is completed, the current remaining number is subtracted by the idle thread number of the thread pool to update the current remaining number.
S150, judging whether the current number of the remaining sheets is equal to 0, and if the current number of the remaining sheets is not equal to 0, executing the step S120; and if the current number of the remaining sheets is equal to 0, ending the flow.
In this embodiment, the current number of remaining pictures to be uploaded is obtained, and whether the current number of remaining pictures is equal to 0 is determined, if the current number of remaining pictures is not equal to 0, it indicates that the remaining pictures still need to be uploaded continuously, and at this time, the step S120 is executed again. And if the current number of the remaining pictures is equal to 0, the pictures to be uploaded are completely uploaded, and the process is ended.
In one embodiment, as shown in fig. 4, step S140 further includes:
s141, if a pause uploading instruction of the array is detected, pausing the sending of the request body;
and S142, if a continuous uploading instruction of the array is detected, acquiring the data which is not uploaded in the request body, and sending the data which is not uploaded to the server.
In this embodiment, when the user needs to suspend the uploading of the request body in a certain array, the method of "suspending" and "continuing" carried by the array can be called. In the uploading process, when a user needs to pause the uploading of one or more pictures, the pause uploading and the continuous uploading of the pictures are controlled by the virtual buttons mapped on the operation interface of the intelligent terminal, so that the flexible control of the picture uploading process is realized.
In one embodiment, as shown in fig. 5, step S140 further includes:
s143, if a request body uploading completion instruction in the array is detected, updating a picture local storage address corresponding to the request body into a picture URL address sent by the server.
When one picture is uploaded to the server, the local storage address of the picture stored in the memory is set as the picture URL address sent by the server, and the picture is displayed instead of the local picture stored in the hard disk, so that the local picture stored in the hard disk can be downloaded and checked again from the server even if the local picture stored in the hard disk is deleted.
And S160, if the current number of remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, packaging each picture to be uploaded into a corresponding request body, storing the corresponding request body in an array, and sending the request body stored in each array to a server through threads corresponding to each array.
In this embodiment, if the current number of remaining pictures to be uploaded is less than or equal to the thread Chi Kongxian number of threads in the thread pool, it indicates that the number of remaining pictures to be uploaded does not exceed the thread pool idle number of threads, and at this time, each picture is correspondingly allocated with a thread to complete uploading.
The method realizes the maximum utilization of network resources, thereby improving the image uploading efficiency and effectively reducing the memory occupancy rate.
The embodiment of the invention also provides a picture uploading device which is used for executing any embodiment of the picture uploading method. Specifically, referring to fig. 6, fig. 6 is a schematic block diagram of a picture uploading device according to an embodiment of the present invention. The image uploading device 100 can be configured in a desktop computer, a tablet computer, a portable computer, and other intelligent terminals.
As shown in fig. 6, the picture uploading apparatus 100 includes a thread pool creation unit 110, a comparison unit 120, a picture encapsulation unit 130, a first requester transmission unit 140, a current remaining number judgment unit 150, and a second requester transmission unit 160.
The thread pool creation unit 110 is configured to obtain a current network connection state if a picture upload instruction is detected, correspondingly obtain a maximum number of threads according to the current network connection state, and create a thread pool with the number of threads being the maximum number of threads, where each thread in the thread pool creates an array for storing data.
In this embodiment, the application scenario for uploading multiple pictures is: when a user needs to upload a plurality of field photos shot through the intelligent terminal in the claim settlement process, selecting the pictures as pictures to be uploaded to a cloud server corresponding to the claim settlement system so as to perform claim settlement (such as car insurance claim settlement).
Because the plurality of live photos taken by the intelligent terminal are initially stored in the hard disk area (which can be understood as a non-IOS system storage area in the ROM area of the intelligent terminal), the hard disk storage paths (the hard disk storage paths are also known as picture local storage addresses) of the plurality of photos stored in the hard disk area are correspondingly stored in the memory (which can be understood as the RAM area of the intelligent terminal), and thus, the problem that the memory is seriously occupied due to the fact that the pictures to be uploaded are directly loaded into the memory is avoided.
When a picture uploading instruction is detected (that is, a user operates the intelligent terminal and selects a plurality of pictures to be uploaded), the current network connection state needs to be judged first (that is, the intelligent terminal is judged to be in a Wi-Fi connection state or in a non-Wi-Fi connection state, wherein the non-Wi-Fi connection state is generally that the intelligent terminal is connected with a server by using data traffic provided by a communication carrier), different thread strategies are generated according to the current network connection state, and therefore the maximum number of pictures which can be uploaded at a time is controlled.
In one embodiment, as shown in fig. 7, the thread pool creation unit 110 includes:
a network connection judging unit 111 for judging whether the current network connection state is a Wi-Fi connection state;
A first thread number setting unit 112, configured to set the maximum thread number to a preset first thread value if the current network connection state is a Wi-Fi connection state;
a second thread number setting unit 113, configured to set the maximum thread number to a preset second thread value if the current network connection state is not a Wi-Fi connection state; wherein the second thread value is less than the first thread value.
In this embodiment, the current network connection state of the intelligent terminal is detected and obtained through the IOS system (for example, in the IOS system, the network state is obtained and can be obtained through a system tool provided by an apple, and a specific library is Reachability); different thread policies are generated according to the network conditions: if the current network connection state of the intelligent terminal is a Wi-Fi connection state, the maximum number of opened threads is 5; if the current network connection state of the intelligent terminal is not the Wi-Fi connection state, the maximum number of opened threads is 3; that is, the first thread value is 5 and the second thread value is 3; when in the Wi-Fi connection state, the number of pictures to be uploaded by the intelligent terminal is 5, and when in the non-Wi-Fi connection state, the number of pictures to be uploaded by the intelligent terminal is 3. Through the set maximum thread number, the number of pictures uploaded by the intelligent terminal at a time is effectively limited, the occupation of the memory is reduced, and the network condition is fully considered to generate a corresponding thread policy.
And the comparing unit 120 is configured to determine whether the current remaining number of pictures to be uploaded is greater than the idle number of threads in the thread pool.
In this embodiment, the initial value of the current number of remaining pictures to be uploaded is generally much larger than the thread Chi Kongxian thread number in the thread pool, the initial value of the current number of remaining pictures to be uploaded is 100, and the maximum value of the thread Chi Kongxian thread number in the thread pool is the maximum thread number (and the maximum thread number is generally set to 3-5).
The picture packaging unit 130 is configured to obtain a picture to be uploaded, the number of pictures being equal to the number of idle threads in the thread pool, if the current number of remaining pictures to be uploaded is greater than the number of idle threads in the thread pool, so as to package the picture to be uploaded into a corresponding request body, and store the request body in an array; the request body at least comprises a target address for uploading the picture and original picture data.
In this embodiment, the pictures are uploaded in a large batch, so the total number of pictures to be uploaded is a large probability exceeding the maximum thread number (for example, 100 corresponding to 100 pictures to be uploaded is much larger than 5 corresponding to the maximum thread number). If the total number of the pictures to be uploaded is larger than the maximum thread number, firstly, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, according to the sequence of the pictures to be uploaded selected by a user, and then distributing a request body packaged by each picture to be uploaded to a corresponding thread for storage. The picture is converted into the request body, so that the picture is accurately uploaded correspondingly, and the original picture is not directly uploaded.
And if the total number of the pictures to be uploaded is smaller than or equal to the maximum thread number of the thread pool, indicating that the pictures to be uploaded are about to be uploaded. If the total number of pictures to be uploaded is smaller than the current thread Chi Kongxian thread number, directly uploading the rest pictures to be uploaded to a server by randomly distributing an idle state thread pool to a request body; if the total number of the pictures to be uploaded is larger than the current idle thread number of the thread pool, obtaining the pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies, and storing the corresponding request bodies in an array for uploading to a server.
In one embodiment, as shown in fig. 8, the picture packaging unit 130 includes:
the local image obtaining unit 131 is configured to obtain, from the hard disk, an image to be uploaded, where the number of images is equal to the number of idle threads in the thread pool, according to the image local storage address stored in the memory;
the picture packaging storage unit 132 is configured to package each picture to be uploaded as a request body, and store each request body into a corresponding array.
In this embodiment, for example, when the image upload is started initially, the idle thread number of the thread pool is 5, and at this time, 5 images to be uploaded are obtained from the hard disk according to the image local storage address stored in the memory. Each thread in the thread pool receives a request body of a picture to be uploaded, and the request body is uploaded to a server through running the thread so as to realize the picture uploading process.
The first request body sending unit 140 is configured to send, by a thread corresponding to each array, the request body stored in each array to the server, and subtract the current remaining number of threads by the idle number of threads in the thread pool to update the current remaining number of threads.
In this embodiment, an array may be understood as a block of memory area in a thread for storing a request bank. Each requestor may be considered a task object, which is a task that is in progress. Creating a request body, packaging the request address, the picture data to be uploaded and other parameters into the request body, calling a starting method corresponding to the request body, and sending the request body out through a network at the bottom layer after the intelligent terminal receives the starting method.
If N (N is a positive integer not more than 5) pictures are uploaded first in the subsequent picture uploading process, the idle thread number of the thread pool is N at this time, and then N pictures to be uploaded are obtained in the hard disk according to the picture local storage address stored in the memory to continue uploading, that is, each time a round of picture uploading is completed, the current remaining number is subtracted by the idle thread number of the thread pool to update the current remaining number.
The current remaining number judging unit 150 is configured to execute a step of judging whether the current remaining number of the pictures to be uploaded is greater than the idle thread number of the thread pool in the thread pool if the current remaining number of the pictures is not equal to 0; and if the current number of the remaining sheets is equal to 0, ending the flow.
In this embodiment, the current number of remaining pictures to be uploaded is obtained, and whether the current number of remaining pictures is equal to 0 is determined, if the current number of remaining pictures is not equal to 0, it indicates that the remaining multiple pictures to be uploaded still need to be continuously uploaded, and at this time, the step of obtaining the pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, is performed again, so as to package the pictures to be uploaded into corresponding request bodies and store the request bodies in an array is only required. And if the current number of the remaining pictures is equal to 0, the pictures to be uploaded are completely uploaded, and the process is ended.
In an embodiment, as shown in fig. 9, the image uploading device 100 further includes:
a pause upload control unit 141, configured to pause the sending of the request body if a pause upload instruction of the array is detected;
and the continuous uploading control unit 142 is configured to, if detecting a continuous uploading instruction of the array, obtain the data that is not uploaded in the request body, and send the data that is not uploaded to the server.
In this embodiment, when the user needs to suspend the uploading of the request body in a certain array, the method of "suspending" and "continuing" carried by the array can be called. In the uploading process, when a user needs to pause the uploading of one or more pictures, the pause uploading and the continuous uploading of the pictures are controlled by the virtual buttons mapped on the operation interface of the intelligent terminal, so that the flexible control of the picture uploading process is realized.
In an embodiment, as shown in fig. 10, the image uploading device 100 further includes:
and the picture cache address updating unit 143 is configured to update the picture local storage address corresponding to the request body to the picture URL address sent by the server if the request body upload completion instruction in the array is detected.
When one picture is uploaded to the server, the local storage address of the picture stored in the memory is set as the picture URL address sent by the server, and the picture is displayed instead of the local picture stored in the hard disk, so that the local picture stored in the hard disk can be downloaded and checked again from the server even if the local picture stored in the hard disk is deleted.
And the second request body sending unit 160 is configured to package each picture to be uploaded into a corresponding request body and store the corresponding request body in an array if the current remaining number of pictures to be uploaded is less than or equal to the idle number of threads in the thread pool, and send the request body stored in each array to the server through threads corresponding to each array.
In this embodiment, if the current number of remaining pictures to be uploaded is less than or equal to the thread Chi Kongxian number of threads in the thread pool, it indicates that the number of remaining pictures to be uploaded does not exceed the thread pool idle number of threads, and at this time, each picture is correspondingly allocated with a thread to complete uploading.
The device realizes the maximum utilization of network resources, thereby improving the image uploading efficiency and effectively reducing the memory occupancy rate.
The above-described picture uploading means may be implemented in the form of a computer program which is executable on a computer device as shown in fig. 11.
Referring to fig. 11, fig. 11 is a schematic block diagram of a computer device according to an embodiment of the present invention. The computer device 500 is a terminal. The terminal can be an electronic device with a communication function, such as a smart phone, a tablet computer, a notebook computer, a desktop computer, a personal digital assistant, a wearable device and the like.
With reference to FIG. 11, the computer device 500 includes a processor 502, memory, and a network interface 505 connected by a system bus 501, where the memory may include a non-volatile storage medium 503 and an internal memory 504.
The non-volatile storage medium 503 may store an operating system 5031 and a computer program 5032. The computer program 5032, when executed, may cause the processor 502 to perform a picture upload method.
The processor 502 is used to provide computing and control capabilities to support the operation of the overall computer device 500.
The internal memory 504 provides an environment for the execution of a computer program 5032 in the non-volatile storage medium 503, which computer program 5032, when executed by the processor 502, causes the processor 502 to perform a picture upload method.
The network interface 505 is used for network communication, such as providing for transmission of data information, etc. It will be appreciated by those skilled in the art that the structure shown in FIG. 11 is merely a block diagram of some of the structures associated with the present inventive arrangements and does not constitute a limitation of the computer device 500 to which the present inventive arrangements may be applied, and that a particular computer device 500 may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
Wherein the processor 502 is configured to execute a computer program 5032 stored in a memory to perform the following functions: if a picture uploading instruction is detected, acquiring a current network connection state, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool; judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool; if the current number of remaining pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies and stored in an array; the request body at least comprises a target address and original picture data for uploading pictures; transmitting the request body stored in each array to a server through threads corresponding to each array, and subtracting the idle thread number of the thread pool from the current remaining number of sheets to update the current remaining number of sheets; judging whether the current number of the remaining sheets is equal to 0, if the current number of the remaining sheets is not equal to 0, executing the step of judging whether the current number of the remaining sheets of the picture to be uploaded is larger than the idle thread number of the thread pool in the thread pool; if the current number of the remaining sheets is equal to 0, ending the flow; and if the current number of the remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, packaging each picture to be uploaded into a corresponding request body, storing the corresponding request body in an array, and sending the request bodies stored in each array to a server through threads corresponding to each array.
In one embodiment, the processor 502 performs the following operations when performing the step of obtaining the maximum number of threads according to the current network connection state: judging whether the current network connection state is a Wi-Fi connection state or not; if the current network connection state is a Wi-Fi connection state, setting the maximum thread number as a preset first thread value; if the current network connection state is not the Wi-Fi connection state, setting the maximum thread number as a preset second thread value; wherein the second thread value is less than the first thread value.
In one embodiment, when executing the step of obtaining the pictures to be uploaded, where the number of pictures is equal to the number of idle threads in the thread pool, to package the pictures into the corresponding request body and store the corresponding request body in the array, the processor 502 performs the following operations: according to the local storage address of the pictures stored in the memory, obtaining pictures to be uploaded, wherein the number of the pictures is equal to the number of idle threads of the thread pool, from the hard disk; and packaging each picture to be uploaded into a request body, and storing each request body into a corresponding array.
In one embodiment, after executing the step of subtracting the thread number of idle threads of the thread pool from the current remaining number of threads to update the current remaining number of threads, the processor 502 further performs the following operations: if a pause uploading instruction of the array is detected, pausing the sending of the request body; if a continuous uploading instruction of the array is detected, acquiring the data which is not uploaded in the request body, and sending the data which is not uploaded to the server.
In one embodiment, after executing the step of subtracting the thread number of idle threads of the thread pool from the current remaining number of threads to update the current remaining number of threads, the processor 502 further performs the following operations: if a request body uploading completion instruction in the array is detected, updating a picture local storage address corresponding to the request body into a picture URL address sent by the server.
Those skilled in the art will appreciate that the embodiment of the computer device shown in fig. 11 is not limiting of the specific construction of the computer device, and in other embodiments, the computer device may include more or less components than those shown, or certain components may be combined, or a different arrangement of components. For example, in some embodiments, the computer device may include only a memory and a processor, and in such embodiments, the structure and function of the memory and the processor are consistent with the embodiment shown in fig. 11, and will not be described again.
It should be appreciated that in embodiments of the present invention, the processor 502 may be a central processing unit (Central Processing Unit, CPU), the processor 502 may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf Programmable gate arrays (FPGAs) or other Programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. Wherein the general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
In another embodiment of the invention, a computer-readable storage medium is provided. The computer readable storage medium may be a non-volatile computer readable storage medium. The computer readable storage medium stores a computer program, wherein the computer program when executed by a processor performs the steps of: if a picture uploading instruction is detected, acquiring a current network connection state, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool; judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool; if the current number of remaining pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies and stored in an array; the request body at least comprises a target address and original picture data for uploading pictures; transmitting the request body stored in each array to a server through threads corresponding to each array, and subtracting the idle thread number of the thread pool from the current remaining number of sheets to update the current remaining number of sheets; judging whether the current number of the remaining sheets is equal to 0, if the current number of the remaining sheets is not equal to 0, executing the step of judging whether the current number of the remaining sheets of the picture to be uploaded is larger than the idle thread number of the thread pool in the thread pool; if the current number of the remaining sheets is equal to 0, ending the flow; and if the current number of the remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, packaging each picture to be uploaded into a corresponding request body, storing the corresponding request body in an array, and sending the request bodies stored in each array to a server through threads corresponding to each array.
In an embodiment, the obtaining the maximum thread number according to the current network connection state includes: judging whether the current network connection state is a Wi-Fi connection state or not; if the current network connection state is a Wi-Fi connection state, setting the maximum thread number as a preset first thread value; if the current network connection state is not the Wi-Fi connection state, setting the maximum thread number as a preset second thread value; wherein the second thread value is less than the first thread value.
In an embodiment, the obtaining the pictures to be uploaded, the number of which is equal to the number of idle threads in the thread pool, to be packaged into the corresponding request body, is stored in the array, and includes: according to the local storage address of the pictures stored in the memory, obtaining pictures to be uploaded, wherein the number of the pictures is equal to the number of idle threads of the thread pool, from the hard disk; and packaging each picture to be uploaded into a request body, and storing each request body into a corresponding array.
In an embodiment, after the sending, by the thread corresponding to each array, the request body stored in each array to the server and subtracting the idle thread number of the thread pool from the current remaining number of threads to update the current remaining number of threads, the method further includes: if a pause uploading instruction of the array is detected, pausing the sending of the request body; if a continuous uploading instruction of the array is detected, acquiring the data which is not uploaded in the request body, and sending the data which is not uploaded to the server.
In an embodiment, after the current remaining number of threads is subtracted from the thread pool idle number of threads to update the current remaining number of threads, the method further includes: if a request body uploading completion instruction in the array is detected, updating a picture local storage address corresponding to the request body into a picture URL address sent by the server.
It will be clearly understood by those skilled in the art that, for convenience and brevity of description, specific working procedures of the apparatus, device and unit described above may refer to corresponding procedures in the foregoing method embodiments, which are not repeated herein. Those of ordinary skill in the art will appreciate that the elements and algorithm steps described in connection with the embodiments disclosed herein may be embodied in electronic hardware, in computer software, or in a combination of the two, and that the elements and steps of the examples have been generally described in terms of function in the foregoing description to clearly illustrate the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the several embodiments provided by the present invention, it should be understood that the disclosed apparatus, device and method may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, and for example, the division of the units is merely a logical function division, there may be another division manner in actual implementation, or units having the same function may be integrated into one unit, for example, multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or not performed. In addition, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices, or elements, or may be an electrical, mechanical, or other form of connection.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiment of the present invention.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units may be stored in a storage medium if implemented in the form of software functional units and sold or used as stand-alone products. Based on such understanding, the technical solution of the present invention is essentially or a part contributing to the prior art, or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a magnetic disk, an optical disk, or other various media capable of storing program codes.
While the invention has been described with reference to certain preferred embodiments, it will be understood by those skilled in the art that various changes and substitutions of equivalents may be made and equivalents will be apparent to those skilled in the art without departing from the scope of the invention. Therefore, the protection scope of the invention is subject to the protection scope of the claims.

Claims (10)

1. A picture uploading method, comprising:
if a picture uploading instruction is detected, acquiring a current network connection state, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool;
judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool;
if the current number of remaining pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool, obtaining pictures to be uploaded, the number of which is equal to the idle thread number of the thread pool, to be packaged into corresponding request bodies and stored in an array; the request body at least comprises a target address and original picture data for uploading pictures;
Transmitting the request body stored in each array to a server through threads corresponding to each array, and subtracting the idle thread number of the thread pool from the current remaining number of sheets to update the current remaining number of sheets;
judging whether the current number of the remaining sheets is equal to 0, if the current number of the remaining sheets is not equal to 0, executing the step of judging whether the current number of the remaining sheets of the picture to be uploaded is larger than the idle thread number of the thread pool in the thread pool; if the current number of the remaining sheets is equal to 0, ending the flow;
and if the current number of the remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, packaging each picture to be uploaded into a corresponding request body, storing the corresponding request body in an array, and sending the request bodies stored in each array to a server through threads corresponding to each array.
2. The picture uploading method according to claim 1, wherein the obtaining the maximum number of threads according to the current network connection state includes:
judging whether the current network connection state is a Wi-Fi connection state or not;
if the current network connection state is a Wi-Fi connection state, setting the maximum thread number as a preset first thread value;
if the current network connection state is not the Wi-Fi connection state, setting the maximum thread number as a preset second thread value; wherein the second thread value is less than the first thread value.
3. The method for uploading pictures according to claim 1, wherein obtaining pictures to be uploaded having a number of pictures equal to the number of idle threads in the thread pool, to be packaged as a corresponding request body, is stored in an array, and includes:
according to the local storage address of the pictures stored in the memory, obtaining pictures to be uploaded, wherein the number of the pictures is equal to the number of idle threads of the thread pool, from the hard disk;
and packaging each picture to be uploaded into a request body, and storing each request body into a corresponding array.
4. The picture uploading method according to claim 1, wherein after the step of transmitting the request body stored in each array to the server by the thread corresponding to each array and subtracting the thread pool idle thread number from the current remaining number to update the current remaining number, the method further comprises:
if a pause uploading instruction of the array is detected, pausing the sending of the request body;
if a continuous uploading instruction of the array is detected, acquiring the data which is not uploaded in the request body, and sending the data which is not uploaded to the server.
5. The picture uploading method according to claim 1, wherein after the step of transmitting the request body stored in each array to the server by the thread corresponding to each array and subtracting the thread pool idle thread number from the current remaining number to update the current remaining number, the method further comprises:
If a request body uploading completion instruction in the array is detected, updating a picture local storage address corresponding to the request body into a picture URL address sent by the server.
6. A picture uploading device, comprising:
the thread pool creation unit is used for acquiring the current network connection state if the picture uploading instruction is detected, correspondingly acquiring the maximum thread number according to the current network connection state, and creating a thread pool with the thread number being the maximum thread number, wherein an array for storing data is created in each thread in the thread pool;
the comparison unit is used for judging whether the current number of remaining pictures to be uploaded is larger than the number of threads Chi Kongxian in the thread pool;
the picture packaging unit is used for obtaining pictures to be uploaded, of which the number of pictures is equal to the number of idle threads in the thread pool, if the current number of remaining pictures to be uploaded is larger than the number of idle threads in the thread pool, so as to package the pictures to be uploaded into corresponding request bodies and store the corresponding request bodies in an array; the request body at least comprises a target address and original picture data for uploading pictures;
the first request body sending unit is used for sending the request bodies stored in each array to a server through threads corresponding to each array, and subtracting the idle thread numbers of the thread pools from the current remaining number of the sheets so as to update the current remaining number of the sheets;
The current remaining number judging unit is used for executing the step of judging whether the current remaining number of the pictures to be uploaded is larger than the idle thread number of the thread pool in the thread pool if the current remaining number of the pictures is not equal to 0; if the current number of the remaining sheets is equal to 0, ending the flow;
and the second request body sending unit is used for packaging each picture to be uploaded into a corresponding request body to be stored in an array if the current number of remaining pictures to be uploaded is smaller than or equal to the number of idle threads in the thread pool, and sending the request bodies stored in each array to a server through threads corresponding to each array.
7. The picture uploading apparatus according to claim 6, wherein the thread pool creation unit comprises:
the network connection judging unit is used for judging whether the current network connection state is a Wi-Fi connection state or not;
the first thread number setting unit is used for setting the maximum thread number as a preset first thread value if the current network connection state is a Wi-Fi connection state;
the second thread number setting unit is used for setting the maximum thread number as a preset second thread value if the current network connection state is not the Wi-Fi connection state; wherein the second thread value is less than the first thread value.
8. The picture uploading device of claim 6, wherein the picture packaging unit comprises:
the local image acquisition unit is used for acquiring images to be uploaded, the number of which is equal to the number of idle threads of the thread pool, from the hard disk according to the image local storage address stored in the memory;
and the picture packaging storage unit is used for packaging each picture to be uploaded into a request body and storing each request body into a corresponding array.
9. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the picture upload method according to any one of claims 1 to 5 when executing the computer program.
10. A computer readable storage medium, characterized in that the computer readable storage medium stores a computer program which, when executed by a processor, causes the processor to perform the picture uploading method according to any of claims 1 to 5.
CN201811346905.9A 2018-11-13 2018-11-13 Picture uploading method and device, computer equipment and storage medium Active CN109542640B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811346905.9A CN109542640B (en) 2018-11-13 2018-11-13 Picture uploading method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811346905.9A CN109542640B (en) 2018-11-13 2018-11-13 Picture uploading method and device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109542640A CN109542640A (en) 2019-03-29
CN109542640B true CN109542640B (en) 2023-08-11

Family

ID=65846948

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811346905.9A Active CN109542640B (en) 2018-11-13 2018-11-13 Picture uploading method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109542640B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110798702B (en) * 2019-10-15 2022-04-15 平安科技(深圳)有限公司 Video decoding method, device, equipment and computer readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103634352A (en) * 2012-08-24 2014-03-12 腾讯科技(深圳)有限公司 Picture upload method and system and client
CN105162863A (en) * 2015-09-01 2015-12-16 北京皮尔布莱尼软件有限公司 Picture uploading device and method and computing equipment
CN107463439A (en) * 2017-08-21 2017-12-12 山东浪潮通软信息科技有限公司 A kind of thread pool implementation method and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103634352A (en) * 2012-08-24 2014-03-12 腾讯科技(深圳)有限公司 Picture upload method and system and client
CN105162863A (en) * 2015-09-01 2015-12-16 北京皮尔布莱尼软件有限公司 Picture uploading device and method and computing equipment
CN107463439A (en) * 2017-08-21 2017-12-12 山东浪潮通软信息科技有限公司 A kind of thread pool implementation method and device

Also Published As

Publication number Publication date
CN109542640A (en) 2019-03-29

Similar Documents

Publication Publication Date Title
WO2021142609A1 (en) Information reporting method, apparatus and device, and storage medium
CN107832100B (en) APK plug-in loading method and terminal thereof
KR102107708B1 (en) Automatic application updates
US10334047B2 (en) Remote direct memory access with reduced latency
US9781206B2 (en) Blended storage allocation on a storage agent
CN110659151B (en) Data verification method and device and storage medium
CN106302780B (en) Method, device and system for batch data transmission of cluster equipment and server
CN109992406B (en) Picture request method, picture request response method and client
CN111198759A (en) Memory optimization method, system, terminal equipment and readable storage medium
CN108205498B (en) Memory recovery method and device, computer device and computer readable storage medium
CN106385377B (en) Information processing method and system
CN111190854A (en) Communication data processing method, device, equipment, system and storage medium
CN115964319A (en) Data processing method for remote direct memory access and related product
CN109542640B (en) Picture uploading method and device, computer equipment and storage medium
CN113810433A (en) File uploading method and device and computer equipment
TW201329728A (en) System on chip, electronic system including the same, and method of operating the same
WO2013154540A1 (en) Continuous information transfer with reduced latency
CN107547593B (en) Method, device and distributed system for realizing log synchronization
CN110019372B (en) Data monitoring method, device, server and storage medium
US11189003B2 (en) Graphics processing method and related apparatus, and device for unidirectionally transmitting calling information of a graphics API to a client
CN108897639B (en) File processing method and device
CN112653713A (en) Image downloading protection method and device and computing equipment
CN111939562A (en) Shared storage method, electronic device and computer readable storage medium
JP2003036435A (en) Device and method for processing image
CN110633141A (en) Memory management method and device of application program, terminal equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant