better way of making it use the es_server setting for the es server to connect to