[DSL] Adapt to multi thread