Notice: Function wpdb::prepare was called incorrectly. The query does not contain the correct number of placeholders (6) for the number of arguments passed (4). Please see Debugging in WordPress for more information. (This message was added in version 4.8.3.) in /var/www/wp-includes/functions.php on line 6078

How To Manage Neo4j Connections

How To Manage Neo4j Connections In NodeEra

The first thing you need to do in NodeEra is define your Neo4j connections. This allows NodeEra to login and run queries against a Neo4j Database.

Watch The Video

To define connections, you select the Schema / Neo4j Connection Manager menu option (see above). This will display the Connection Manager dialog box (see below).

The grid displays a list of all the defined connections.  The following table describes the columns in the Grid:

Column TitleDefinition
ConnectionThis is the name you give to the connection definition.
Host NameThe host name or IP address of the server hosting the Neo4j database.
UserIDThe userid that NodeEra will use to login to Neo4j.
URLThis is the URL returned by Neo4j after NodeEra successfully connects to the database.  For newly defined connections, this will say “Never Connected” until a connection is made.

The buttons to the right define the major use cases for this dialog:

Add – This will add a new connection definition

Edit – This will edit the selected connection

Test – This will test the selected connection

Remove – This will remove the selected connection definition from NodeEra

How To Add A New Neo4j Connection

Click the Add… button on the right-hand side of the screen.  This will prompt you for a connection name (see below).

Enter a name for the new connection and press OK.  This will display the edit connection dialog box (see below).

Enter the fields on the screen and press OK to save the definition.

The following table describes the fields on the screen:

Field NameDefinition
Connection Type:This defines the protocol that NodeEra will use to talk to Neo4j.
  • Bolt – The preferred choice is Bolt which is Neo4j’s native protocol which is faster than HTTP.
  • Bolt + Routing – select this if your Neo4j instance is a cluster that supports different servers for read/write operations.
  • HTTP/HTTPS – the traditional HTTP interface.
Use Secure ConnectionIf your server connection supports encryption (either BOLT or HTTPS) then check this checkbox.
Host Name:This is the hostname or the IP address of the server that is hosting Neo4j. Use localhost if you are accessing a Neo4j Desktop server running on your laptop/desktop machine.
Port:This is the port that the Neo4j server will respond on.  The standard ports are:Bolt – 7687HTTP – 7474HTTPS – 7473
User ID:This is the user ID that NodeEra will use to log in to Neo4j. NodeEra uses basic auth to authenticate to the server.
Password:This is the password that NodeEra will use to log in to Neo4j.

Managing Passwords

NodeEra stores the passwords you enter for each connection in clear text and stores them with the other NodeEra system settings (location varies by platform).

Passwords will not display as you enter them.  You can change this by clicking on the “Show” button.  This will show you the password that has been entered.

If you don’t want NodeEra to store the password, click on the “Prompt For Password” check box.  This will clear any password that has been entered.  When NodeEra uses this connection, it will prompt the user to enter the password, but will not store the password anywhere.

How To Define A Connection To A Local Neo4j Desktop Database.

You may have installed the Neo4j Desktop.  This is a full enterprise Neo4j database that runs on your laptop and is free from Neo4j.

To define a connection that will work with your locally installed Neo4j Desktop simply use the values shown above.  The password is what you defined when you created the graph database in the Neo4j Desktop.

Related Tutorial: How To Install The Neo4j Desktop

How To Edit A Neo4j Connection In NodeEra

To edit an existing connection simply click on the connection you want to edit and then click on the Edit… button on the right hand side.  This will display the Edit Connection dialog box.

See the previous section How To Add A Neo4j Connection In NodeEra for an explanation of the fields on the Edit Connection dialog box.

How To Test A Neo4j Connection In NodeEra

To test a connection simply click on the connection you want to edit and then click on the Test… button on the right hand side. This will cause NodeEra to connect to the Neo4j database using the values provided in the connection definition. NodeEra will log in using the supplied credentials and will also run a simple query that attempts to return one node. This validates both the authentication and the ability to run queries.

Some common results are described below:

It Worked!

This message will appear if the connection attempt worked. Bad Host Name

In this scenario we used an invalid host name (“localhostx”) and we got the following error back:

Base Exception :AddressError(“Cannot resolve address Address(host=’localhostx’, port=7687)”) – Graph Object Error

Correct the host name and try again.

Bad Port

In this scenario we used an invalid port and we got the following error back:

Base Exception: ServiceUnavailable(“Failed to establish connection to (‘127.0.0’,7688)

Correct the port number and try again.

Bad User ID or password

In this scenario we used an invalid user ID and we got the following error back:

Base Exception :AuthError(‘The client is unauthorized due to authentication failure.’) – Graph Object Error

Providing an invalid password will cause the same message to appear.

Correct the user ID and/or password and try again.

Total
0
Shares
Previous Post

NodeEra – Neo4j Schema Object Generation


Notice: Function wpdb::prepare was called incorrectly. The query does not contain the correct number of placeholders (6) for the number of arguments passed (4). Please see Debugging in WordPress for more information. (This message was added in version 4.8.3.) in /var/www/wp-includes/functions.php on line 6078
Next Post

How To Reverse Engineer a Neo4j Database


Notice: Function wpdb::prepare was called incorrectly. The query does not contain the correct number of placeholders (6) for the number of arguments passed (4). Please see Debugging in WordPress for more information. (This message was added in version 4.8.3.) in /var/www/wp-includes/functions.php on line 6078
Related Posts