Logo
NeoArc Studio

Graph Validation Rules

18 validation rules (10 core plus 8 search-specific) check graph schemas for structural, semantic, domain, and search errors. Validation runs automatically with configurable severity levels including error, warning, and info.

The graph validation service (GraphValidationService) checks diagrams for errors, warnings, and improvement suggestions. Validation rules are organised into three categories: structural, semantic, and domain. Different authoring modes enable different validation categories.

Validation by Authoring Mode

Each authoring mode enables progressively more validation.

Core Validation Rules

The validation service applies 11 core rules with three severity levels.

Severity Levels

Rule Details

missing-primary-key

In Graph DB mode, every node should have a primary key for unique identification. This rule triggers when no property has the PK key role.

Error: Node 'Customer' has no primary key defined.
Fix: Add a property with key role 'primary' (e.g., id: uuid, PK).

orphan-node

Nodes without any connections may indicate incomplete modelling or leftover nodes from deleted relationships.

Warning: Node 'TempData' has no connections.
Fix: Connect to other nodes or remove if not needed.

missing-label

Every node requires a label for identification. Empty labels prevent meaningful schema export.

Error: Node has no label defined.
Fix: Double-click the node and enter a label.

duplicate-property-name

Property names must be unique within a node. Duplicates cause conflicts in Cypher export and queries.

Error: Node 'Order' has duplicate property name 'date'.
Fix: Rename one property (e.g., 'orderDate', 'deliveryDate').

invalid-foreign-key

Foreign key properties must reference valid target nodes and properties. This catches broken references after node deletion or property renaming.

Error: FK 'customerId' on 'Order' references non-existent node.
Fix: Update FK resolution to point to valid target.

missing-cardinality

Edges without cardinality may indicate incomplete relationship modelling. Cardinality (1:1, 1:N, N:1, N:M) clarifies relationship semantics.

Warning: Edge 'PLACED' has no cardinality defined.
Fix: Select the edge and set cardinality (e.g., 1:N for Customer-Order).

circular-dependency

Circular FK chains (A references B, B references C, C references A) can cause issues with data loading and integrity.

Warning: Circular FK dependency: Order -> Customer -> Account -> Order.
Fix: Review the relationship chain and consider breaking the cycle.

missing-index

Foreign key properties benefit from indexing for query performance. This info-level suggestion helps optimise the schema.

Info: FK property 'customerId' is not indexed.
Fix: Enable the 'indexed' constraint for better query performance.

naming-convention

Consistent naming improves schema readability. This rule checks for camelCase properties and PascalCase node labels.

Info: Property 'customer_id' uses snake_case instead of camelCase.
Fix: Rename to 'customerId' for consistency.

empty-description

Documentation helps future maintainers understand the schema. This rule encourages adding descriptions to nodes and properties.

Info: Node 'Order' has no description.
Fix: Add a description explaining the node's purpose.

Search-Specific Validation Rules

When properties have search projections enabled, 8 additional rules validate the search index configuration. These rules apply in Graph DB mode only.

search-missing-searchable-property

When a node has search projection enabled, at least one property must be marked as searchable. Without a searchable property, the node appears in the search index but returns no results for text queries.

Error: Node 'Product' has search projection enabled but no searchable properties.
Fix: Mark at least one text property (e.g. name, description) as searchable.

search-missing-display-property

Search results need a display property to render meaningful results to users. Without one, search results show only the node identifier.

Error: Node 'Customer' has no display property for search results.
Fix: Mark a descriptive property (e.g. name, title) as the display property.

search-incompatible-type

Certain property types cannot be directly indexed by search engines. Complex types like json, object, and array require transformation before indexing.

Error: Property 'metadata' (json) on 'Order' is incompatible with search indexing.
Fix: Use specific scalar properties instead of json for search-projected fields.

Viewing Validation Results

Disabling Specific Rules

Individual rules cannot be disabled, but you can switch to a simpler authoring mode to reduce validation strictness. Mind Map mode applies only structural validation, allowing free-form exploration without schema constraints. Search-specific rules only apply when properties have search projections enabled, so removing search projections from properties effectively disables those 8 rules for the affected nodes.