Upload operation using multiple connections
First Claim
Patent Images
1. A computer implemented method to receive data through a plurality of connections, the method comprising:
- receiving a request to establish the plurality of connections;
sending a response to the request comprising an identifier of an upload operation and a location to be polled for status of the upload operation;
creating a plurality of connection reader threads corresponding to the plurality of connections, wherein the plurality of connection reader threads corresponds to a plurality of server buffers;
receiving a sequence of chunks at the plurality of connection reader threads through the plurality of connections, wherein each of the plurality of connections is associated with the identifier of the upload operation;
reading, via a connection reader thread of the plurality of connection reader threads, one or more chunks from the sequence of chunks;
writing the one or more chunks from the sequence of chunks to a server buffer of the plurality of server buffers, wherein the connection reader thread from the plurality of connection reader threads corresponds to the server buffer;
searching in the plurality of server buffers for a chunk with a consecutive number expected next for an output data stream;
when the chunk with the consecutive number expected next is missing in the plurality of server buffers, blocking the connection reader thread and the server buffer until the chunk with the consecutive number expected next is read by a different connection reader thread of the plurality of connection reader threads;
when the chunk with the consecutive number next expected is read by the different connection reader thread, adding the chunk with the consecutive number expected next to the output data stream; and
merging chunks from the plurality of server buffers into the output data stream according to the sequence.
2 Assignments
0 Petitions
Accused Products
Abstract
A client system requests to upload an input data stream to a server system. The input data stream is split to a sequence of chunks. The chunks are transferred in parallel by a number of connections from the client system to the server system. At the server system, the transferred chunks are merged into an output stream according to the sequence. The output stream represents the rebuilt input stream.
-
Citations
12 Claims
-
1. A computer implemented method to receive data through a plurality of connections, the method comprising:
-
receiving a request to establish the plurality of connections; sending a response to the request comprising an identifier of an upload operation and a location to be polled for status of the upload operation; creating a plurality of connection reader threads corresponding to the plurality of connections, wherein the plurality of connection reader threads corresponds to a plurality of server buffers; receiving a sequence of chunks at the plurality of connection reader threads through the plurality of connections, wherein each of the plurality of connections is associated with the identifier of the upload operation; reading, via a connection reader thread of the plurality of connection reader threads, one or more chunks from the sequence of chunks; writing the one or more chunks from the sequence of chunks to a server buffer of the plurality of server buffers, wherein the connection reader thread from the plurality of connection reader threads corresponds to the server buffer; searching in the plurality of server buffers for a chunk with a consecutive number expected next for an output data stream; when the chunk with the consecutive number expected next is missing in the plurality of server buffers, blocking the connection reader thread and the server buffer until the chunk with the consecutive number expected next is read by a different connection reader thread of the plurality of connection reader threads; when the chunk with the consecutive number next expected is read by the different connection reader thread, adding the chunk with the consecutive number expected next to the output data stream; and merging chunks from the plurality of server buffers into the output data stream according to the sequence. - View Dependent Claims (2, 3, 4, 5)
-
-
6. A computer system to receive data by a plurality of connections, the system comprising:
-
a memory to store computer executable instructions; at least one computer processor coupled to the memory to execute the instructions, to perform operations comprising; receiving a request to establish the plurality of connections; sending a response to the request comprising an identifier of an upload operation and a location to be polled for status of the upload operation; creating a plurality of connection reader threads corresponding to the plurality of connections, wherein the plurality of connection reader threads corresponds to a plurality of server buffers; receiving a sequence of chunks at the plurality of connection reader threads through the plurality of connections, wherein each of the plurality of connections is associated with the identifier of the upload operation; reading, via a connection reader thread of the plurality of connection reader threads, one or more chunks from the sequence of chunks; writing the one or more chunks from the sequence of chunks to a server buffer of the plurality of server buffers, wherein the connection reader thread from the plurality of connection reader threads corresponds to the server buffer; searching in the plurality of server buffers for a chunk with a consecutive number expected next for an output data stream; when the chunk with the consecutive number expected next is missing in the plurality of server buffers, blocking the connection reader thread and the server buffer until the chunk with the consecutive number expected next is read by a different connection reader thread of the plurality of connection reader threads; when the chunk with the consecutive number expected next is read by the different connection reader thread, adding the chunk with the consecutive number expected next to the output data stream; and merging chunks from the plurality of server buffers into the output data stream. - View Dependent Claims (7, 8, 9, 10, 11)
-
-
12. A non-transitory computer readable storage medium having instructions encoded thereon that, when executed by a processor, cause the processor to perform operations comprising:
-
receive a request to establish a plurality of connections; send a response to the request comprising an identifier of an upload operation and a location to be polled for status of the upload operation; create a plurality of connection reader threads corresponding to the plurality of connections, wherein the plurality of connection reader threads corresponds to a plurality of server buffers; receive a sequence of chunks at the plurality of connection reader threads through the plurality of connections, wherein each of the connections of the plurality of connections is associated with the identifier of the upload operation; read, via a connection reader thread of the plurality of connection reader threads, one or more chunks from the sequence of chunks; write the one or more chunks from the sequence of chunks to a server buffer of the plurality of server buffers, wherein the connection reader thread from the plurality of connection reader threads corresponds to the server buffer; search in the plurality of server buffers for a chunk with a consecutive number expected next for an output data stream; when the chunk with the consecutive number expected next is missing in the plurality of server buffers, block the connection reader thread and the server buffer until the chunk with the consecutive number expected next is read by a different connection reader thread of the plurality of connection reader threads; when the chunk with the consecutive number expected next is read by the different connection reader thread, add the chunk with the consecutive number expected next to the output data stream; and merge chunks from the plurality of server buffers into the output data stream.
-
Specification