cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Neo4j Interacting with Elasticsearch using username and password?

Hi,
I connect to elasticsearch using apoc

call apoc.es.get("http://localhost:9200","index_name","doc",'size=1&scroll=5m',null) yield value

May I how should I specify username and password if elastic has credentials

I can find this below

ElasticSearch Shield Support

If Shield plugin is installed and enabled on Elasticsearch node, it is possible to add authentication parameters in the configuration. Here an example:

#optional, specify the Shield user
com.graphaware.module.ES.authUser=neo4j_user

#optional, specify the Shield password
com.graphaware.module.ES.authPassword=123456

Both of them MUST be specified to enabling Authentication. The user must be able to perform writes on the elasticsearch instance.

How to install Shield plugin?

1 REPLY 1

found it

call apoc.es.stats("http://elastic:password@localhost:9200")