The present invention relates to the field of
big data technology, and discloses an optimization method for traffic merging and computing merging for
SQL tasks. First, multiple tasks are submitted at one time on the
Client side, and the
Server side executes the multiple tasks submitted by the
Client; on the
Server side, multiple real-time
SQL tasks of the same type are parsed to obtain the
annotation structures of Source, Rule, and Sink, and specifically, the
SQL statements, input and output information, and optimization options are parsed through
Json syntax parsing or SQL
syntax parsing Rule parameters; the information of the multiple real-time SQL statements parsed are all in SELECT WHERE format, and the expressions contained in the WHERE
condition part of the multiple real-time SQL task statements are all expressions that can be optimized, and then the Source part is judged; it is judged whether the Topics of the Sources of the multiple real-time SQLs are the same; if yes, multiple SQL tasks are merged. For a
Server configured with the same computing resources, the present invention can achieve a multiple increase in the number of supported real-time SQL tasks when only the computing resources are considered.