use finalizer for elasticsearch_process