plugin: support plugin operations on multi-threading

Mroonga uses groonga on multi-threading.