Refactored query_object_server to use external processes instead of threading.