Relationship index

Permission: Settings management

Data in Graphlytic are indexed. You can select which relationship attributes are indexed, what attributes are used for fulltext search in search page and more. You have to have at least one valid DB property defined in propertiesFullText in order to Graphlytic work properly, mainly the search functions.

  1. Left menu - settings

  2. See panel "Relationship index"

Panel contains information:

  • Status: ENABLED / DISABLED - if indexer is enabled and all relationships are indexed automatically or not

  • Reindex status: REINDEX_RUNNING, REINDEX_SUCCESS, REINDEX_ERROR, REINDEX_INTERRUPTED

  • Reindex start: start date of reindex

  • Reindex end: end date of reindex

  • Reindex items: estimated number of all relationships, current number of processed relationships, progress

  • Configuration of indexer (see configuration JSON in next chapter).

Configure

  1. Press button Configure

  2. Enter configuration into form. Or you can use default or automatic configuration by pressing one of the buttons Default or Automatic.

  3. Confirm by pressing button Save.

  4. All new added relationships are indexed automatically during storing into Neo4j from this moment.

Because you changed configuration of indexer it is strictly recommended to reindex all relationships with new configuration. Explanation: only new created relationships will be indexed with new configuration from this moment. Existing relationships stay indexed by previous configuration and could lead to data inconsistency.

Configuration is entered as JSON. Example of JSON:

{
"types": ["RELATED"],
"indexTypes": true,
 "properties": ["type"],
"propertiesFullText": ["title", "type", "subtype"],
"propertiesSort": ["title"]
}

Explanation of attributes:

  • types - relationships with these types are indexed. mandatory

  • indexTypes - type of every indexed relationship will be indexed. If true, then search based on relationship types can be created in Search tabs. mandatory

  • properties - these properties are indexed and can be used in Search tabs. The exact value is inserted into index. mandatory

  • propertiesFullText - these properties are indexed and used for fulltext search. Property value is normalized and transformed to lower case before insert into index. Normalization means NFD normalization with removing not ASCII characters. mandatory

  • propertiesSort - these properties will be sortable in search page. Property value is normalized before insert into index and all spaces are removed. Normalization means NFD normalization with removing not ASCII characters. mandatory

Explanation of automatic configuration:

Automatic configuration is used to generate configuration which contains attributes of several random relationships. Random relationships are selected as first 1000 relationships.

Enable

After activation of index, relationships will be indexed automatically based on configuration.

  1. Press button Enable.

  2. Index of relationships is enabled if index was disabled.

Because you enabled indexer it is strictly recommended to reindex all relationships. Explanation: only new created relationships will be indexed from this moment. relationships added when indexer was disabled were not indexed and could lead to data inconsistency.

Disable

After deactivation of index, relationships won't be indexed. Deactivation is useful if you need make large amount of changes for data. Disable index before these changes will be executed and enable after these changes to reindex all relationships after all changes are done. This way can be more effective because it can takes a longer time if index is enabled during changes of large amount of data.

  1. Press button Disable

  2. Index of relationships is disabled if index is was enabled.

Reindex

Indexing of all relationships can take a while. It depends on number of indexed relationships and attributes. Use button "Refresh" to view actual status of indexing. Data are indexed in commit size 10 000 relationships.

  1. Press button Reindex

  2. Reindex of all relationships is started.

  3. Check progress of reindex by pressing "Refresh" icon in the top right corner of "Relationship index" panel. Panel contains information: start date, end date, estimated number of all relationships, current number of indexed relationships, progress.

Interrupt

It is useful if reindex takes long time and you forget to change some data or you make incorrect configuration of indexer.

  1. Press button Interrupt to interrupt current running reindex.

  2. Reindex is interrupted.

Because you interrupt reindex it is strictly recommended to reindex all relationships again after you make all required changes. Explanation: interrupting indexing will result in undesired state. All relationships are not indexed, so searching will not work correctly (it will only search the indexed relationships)

Status

  1. Press button Status

  2. Status of relationship index is shown. There are the same information which are shown in "Relationship index" panel but in JSON format.

Refresh

  1. Use icon "Refresh" in the top right corner of "Relationship index" panel to refresh status of indexer.