Neo4j adapter
Neo4j adapter allows CADMATIC eShare to access a Neo4j graph database, retrieve data from the database, and add the retrieved data to object attributes or Smart Points.
Creating a Neo4j adapter
Create a Neo4j adapter to enable CADMATIC eShare to connect to a Neo4j server using the Bolt protocol.
Prerequisites
- Address, username, and password to the required Neo4j server.
Do the following:
-
Navigate to the project to edit, and then click Project Admin in the main menu. The project administration view opens.
-
Click Adapters and Data Sources. The Adapters and Data Sources configuration view opens.
-
In the Adapters section, click Add.
-
In the Available Adapter Types section, select Neo4J Adapter, and then click Create adapter.
-
In the Adapter section, specify the following settings:
- Name – Enter a name for the adapter.
- Description (optional) – Enter a description for the adapter.
- State – Specify whether the adapter is disabled or enabled (default).
-
In the Adapter Configuration section, specify the following settings:
- Neo4J server address – Specify the Neo4j server address in this format:
bolt://servername:port - Neo4J server username – Specify the username for the Neo4j server.
- Neo4J server password – Specify the password for the Neo4j server.
- Neo4J server address – Specify the Neo4j server address in this format:
-
Click Test to test the connection.
-
Click Save.
Creating an object attributes data source for Neo4j adapter
Create an object attributes data source to allow a Neo4j adapter to use a Cypher query to retrieve data from a graph database and add the data to object attributes or Smart Points.
Prerequisites
- To retrieve data to object attributes, you know which tags to use. See Using attributes and tags in adapters.
- To retrieve data to Smart Points, the Smart Point Type to use has External ID set to "Yes". See Creating a Smart Point type.
Do the following:
-
Navigate to the project to edit, and then click Project Admin in the main menu. The project administration view opens.
-
Click Adapters and Data Sources. The Adapters and Data Sources configuration view opens.
-
On the Adapters list, click the Neo4j adapter to which to add the data source.
-
In the Data Sources section of the adapter settings, click Add data source.
-
Select Object Attributes Data Source, and click Create data source.
-
In the Data Source section, specify the following settings:
- Name – Enter a name for the data source.
- Description (optional) – Enter a description for the data source.
- State – Specify whether the data source is disabled or enabled (default).
-
In the Groups allowed to see the data section, select user groups that should be allowed to see the data that this data source provides.
-
If no groups are selected, only administrators will see the data.
-
Add user groups with Add.
-
Remove user groups with the remove
button.
-
If the All Users group is selected, other group selections will be ignored.
-
-
The Adapter Configuration section is read-only.
-
In the Data Source Configuration section, specify the following settings:
-
Provide data for – Select whether the retrieved data is for model objects or Smart Points.
If you selected "Model Objects", then in Serving Tags specify the tags to which to add the data, each tag on a separate row.
If you selected "Smart Points", then in Smart Point type served select the Smart Point Type to which to add the data.
-
Cypher Query – Specify the Cypher query to use for retrieving data.
-
Test object ID – To test the query, enter an object ID that is found in the database and in the 3D model in eShare, and then click Execute Query.
-
Displayed Attributes – Displays the attributes retrieved by the query.
-
Test Results – Displays test results from the query.
-
Allow Search Queries – Select Enabled if the data source can be used in search queries.
If search queries are enabled, define Maximum Number of Data Source Queries, which determines the number of queries the data source can be included in. The field can be left empty for no limit. The default is 250.
-
-
Click Save.