Patent ID: 8533730

Claim:
A stream data processing method carried out by a stream data processing apparatus for accepting stream data inputted continuously and executing query arithmetic processing on the stream data, wherein: the stream data processing apparatus includes: a storage configured to store the stream data; a stream control section configured to control the stream data processing apparatus; a query execution section configured to execute the query arithmetic processing on the stream data; and a scheduler configured to allocate computer resources of the stream data processing apparatus, and the scheduler is configured to perform the steps of: grouping one or more queries defining the query arithmetic processing as a first query group; allocating the first query group as one unit to a thread of the computer resources to make the query execution section execute the query arithmetic processing on the first query group; reading input flow rates and latencies of one or more queries of a second query group from the storage; and monitoring data stagnation in the second query group; when data stagnation is detected in the second query group as an input flow rate of the stream data to the second query group exceeding an average value of processing flow rate of the one or more queries of the second query group based on the input flow rate of the stream data, and the input flow rates and the latencies of the one or more queries of the second query group, the scheduler is further configured to perform the steps of: calculating estimated load values of each of the one or more queries of the second query group as products of the input flow rates and the latencies of the respective one or more queries of the second query group; dividing queries belonging to the second query group into a third query group and a fourth query group so that the sum of estimated load values of queries of the third query group can be substantially equalized to the sum of estimated load value of queries of the fourth query group; and giving an instruction to the stream control section to reallocate the third query group and the fourth query group to different threads of the computer resource respectively.