[rules-dev] Potential multi thread error and "smal" memory leak