parallel
Processes input data in parallel using a subquery, and then combines the results of subquery and passes them along.
Syntax
parallel core=INT [ SUBQUERY ]
Required Parameter
[ SUBQUERY ]
- Subquery to be processed in parallel, enclosed in a pair of square brackets (
[ ]
). core=INT
- Number of logical cores in the CPU to be used for parallel processing of a subquery
Usage
First, create a data table creation for testing.
json "{}"
| repeat count=5000000
| set a=0 | evalc a=$("a") + 1
| eval b=$("a")
| fields b
| import create=t big_table
Execute the subquery in parallel.
table big_table
| parallel core=4 [eval i=int(b)]
| stats count by b | sort -count