Skip to content

Add Lab 3.5 release notes #1355

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: memgraph-3-5
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
186 changes: 94 additions & 92 deletions pages/memgraph-lab/configuration.mdx

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions pages/memgraph-lab/features.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ different environments:
| [Layout](/memgraph-lab/features/layout) | Adjust graph visualizations dynamically for better readability and insights. | ✅ | ✅ | ✅ |
| [Logs](/memgraph-lab/features/logs) | Monitor internal processes and troubleshoot issues with real-time access to query logs. | ✅ | ✅ | ✅ |
| [Monitoring](/memgraph-lab/features/monitoring) | Real-time monitoring of system, memory, and queries. | 🔒 | 🔒 | 🔒 |
| [Multi-tenancy](/memgraph-lab/features/multi-tenancy) | Switch between different databases within Memgraph Lab. | 🔒 | 🔒 | 🔒 |
| [Query modules](/memgraph-lab/features/query-modules) | Extend functionality with custom Cypher procedures and algorithms. | ✅ | ✅ | ✅ |
| [Run history](/memgraph-lab/features/run-history) | Access and re-run previously executed queries. | ✅ | ✅ | ✅ |
| [Sharing features](/memgraph-lab/features/sharing-features) | Share queries and styles with your team. | ❌ | ❌ | ✅ |
Expand Down
1 change: 1 addition & 0 deletions pages/memgraph-lab/features/_meta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export default {
"graph-style-script": "Graph Style Script (GSS)",
"layout": "Layout",
"logs": "Logs",
"multi-tenancy": "Multi-tenancy",
"monitoring": "Monitoring",
"run-history": "Run history",
"sharing-features": "Sharing features",
Expand Down
160 changes: 139 additions & 21 deletions pages/memgraph-lab/features/custom-configuration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {CommunityLinks} from '/components/social-card/CommunityLinks'
# Custom configuration

Lab offers a way to customize certain behaviors of the application through a
**configuration file**.
**configuration file**.
<Callout type="info">
This functionality is only available when Lab is running
inside a Docker container with the environment variable `CONFIG_URI` set.
Expand All @@ -28,15 +28,20 @@ You can currently configure the following segments:
2. [Sidebar navigation](#sidebar):
- Hide specific tabs in the sidebar, such as **Streams**, **Datasets**,
**Import**, **Export**, etc.
3. [Predefined datasets](#predefined-datasets):
3. [Predefined datasets](#predefined-datasets):
- Hide selected predefined datasets from the **Datasets** section.
- Mark a predefined dataset as **Featured**, which makes it more prominent in
the UI.
4. [Graph node actions](#graph-node-actions):
- Hide default node actions: **Expand**, **Collapse**, **Hide**.
- Hide default node actions: **Expand edges**, **Collapse edges**, **Hide node**.
- Add new custom graph node actions by defining a CYPHER query (**Enterprise
feature**).
5. [GSS Overrides](#system-default-gss-enterprise) (**Enterprise feature**)
5. [Graph relationship actions](#graph-relationship-actions):
- Hide default relationship actions: **Expand parallel edges**, **Collapse parallel edges**,
**Hide edge**.
- Add new custom graph relationship actions by defining a CYPHER query (**Enterprise
feature**).
6. [GSS Overrides](#system-default-gss-enterprise) (**Enterprise feature**)
- Override system default **GSS styles** and customize per theme if needed.


Expand All @@ -45,7 +50,7 @@ You can currently configure the following segments:
The configuration file must be written in YAML format. There are two
supported methods for supplying the file to Lab:

{<h3 className="custom-header">File protocol</h3>}
{<h3 className="custom-header">File protocol</h3>}

You can mount a configuration file inside the Lab Docker container
and reference it using the environment variable `CONFIG_URI`. Example:
Expand All @@ -71,7 +76,7 @@ docker run \
```
</Callout>

{<h3 className="custom-header">HTTP(S) protocol</h3>}
{<h3 className="custom-header">HTTP(S) protocol</h3>}

If the configuration file is hosted externally and the Lab container can
access it via HTTP or HTTPS, you can provide the URI like so:
Expand Down Expand Up @@ -178,7 +183,7 @@ However, you can lock specific settings to prevent users from changing them.
To lock a setting, simply add `isLocked: true` to the relevant parameter.
By default, all settings are unlocked.

{<h4 className="custom-header">Complete settings configuration example</h4>}
{<h4 className="custom-header">Complete settings configuration example</h4>}

Here is a complete example of the settings configuration:

Expand Down Expand Up @@ -215,7 +220,7 @@ settings:
value: true
```

{<h4 className="custom-header">Partial settings configuration example</h4>}
{<h4 className="custom-header">Partial settings configuration example</h4>}

You don’t need to define every parameter—only specify the ones you wish
to change or override. For example:
Expand Down Expand Up @@ -251,7 +256,7 @@ features:
isHidden: true
```

{<h4 className="custom-header">Complete list of features you can hide</h4>}
{<h4 className="custom-header">Complete list of features you can hide</h4>}

Below is a complete list of features that you can hide from the sidebar:

Expand Down Expand Up @@ -290,7 +295,7 @@ features:
Lab includes 36 predefined datasets by default. Using the configuration file,
you can customize how these datasets appear in the UI:

{<h4 className="custom-header">Hiding datasets</h4>}
{<h4 className="custom-header">Hiding datasets</h4>}

You can hide any predefined dataset by referencing its unique ID in the
configuration file.
Expand Down Expand Up @@ -387,7 +392,7 @@ features:
isHidden: true
```

{<h4 className="custom-header">Featuring datasets</h4>}
{<h4 className="custom-header">Featuring datasets</h4>}

You can also change whether a predefined dataset is featured on the datasets
page. Featured datasets are given more visibility and space in the UI.
Expand Down Expand Up @@ -421,13 +426,14 @@ features:

In Lab's graph view, when you click on a node, a sidebar appears with available
node actions. By default, the following actions are provided:
- **Expand**: Fetches relationships and neighboring nodes from the selected node

- **Expand edges**: Fetches relationships and neighboring nodes from the selected node
and adds them to the graph view.
- **Collapse**: Hides relationships and nodes that are only connected to the
- **Collapse edges**: Hides relationships and nodes that are only connected to the
selected node.
- **Hide**: Hides the selected node from the graph view.
- **Hide node**: Hides the selected node from the graph view.

{<h4 className="custom-header">Hiding default actions</h4>}
{<h4 className="custom-header">Hiding default actions</h4>}

You can hide any of these default actions using the configuration file. Each
action is referenced by its ID. For example, to hide all three default actions:
Expand All @@ -443,7 +449,7 @@ action is referenced by its ID. For example, to hide all three default actions:
isHidden: true
```

To hide only the "Hide" action:
To hide only the "Hide node" action:

```yaml
- name: graph.nodes.system.configure
Expand All @@ -452,7 +458,7 @@ To hide only the "Hide" action:
isHidden: true
```

{<h4 className="custom-header">Adding custom node actions (Enterprise)</h4>}
{<h4 className="custom-header">Adding custom node actions (Enterprise)</h4>}

You can also define custom node actions that appear in the sidebar when a node
is selected in the graph view. This feature requires an Enterprise license.
Expand Down Expand Up @@ -487,9 +493,98 @@ Here’s an example of two custom actions:
```

You can use the following parameters in your Cypher queries:

- `$selectedNodeId` — The ID of the node that was clicked.
- `$nodeIds` — A list of IDs of all nodes currently in the graph
view (including hidden ones).
- `$nodeIds` — A list of IDs of all nodes currently visible in
the graph view.
- `$edgeIds` — A list of IDs of all relationships currently
visible in the graph view.

Each action must have a `label` field, which will be displayed
on the UI button.

<Callout type="info">
**Important**: Lab does not validate Cypher queries during configuration
loading. Ensure your query is valid and returns the correct data structures
(nodes, relationships, and/or paths).
</Callout>

<Callout type="info">
This feature requires an Enterprise license.
</Callout>

### Graph relationship actions

In Lab's graph view, when you click on a relationship, a sidebar appears with available
relationship actions. By default, the following actions are provided:

- **Expand parallel edges**: Fetches relationships that share the same starting and ending
nodes as the selected relationship and adds them to the graph view.
- **Collapse parallel edges**: Hides relationships that share the same starting and ending
nodes as the selected relationship.
- **Hide edge**: Hides the selected relationship from the graph view.

{<h4 className="custom-header">Hiding default actions</h4>}

You can hide any of these default actions using the configuration file. Each
action is referenced by its ID. For example, to hide all three default actions:

```yaml
- name: graph.edges.system.configure
items:
- id: expand
isHidden: true
- id: collapse
isHidden: true
- id: hide
isHidden: true
```

To hide only the "Hide edge" action:

```yaml
- name: graph.edges.system.configure
items:
- id: hide
isHidden: true
```

{<h4 className="custom-header">Adding custom relationship actions (Enterprise)</h4>}

You can also define custom relationship actions that appear in the sidebar when a
relationship is selected in the graph view. This feature requires an Enterprise license.

Each custom action executes a Cypher query and should return nodes,
relationships, and/or paths - only these types of objects can be added to the
graph view.

Here’s an example of a custom actions:

- `Expand nodes` - Fetches nodes and relationships connected to the start and end
nodes of the selected relationship.

```yaml
- name: graph.edges.user.configure
items:
- label: Expand nodes
query:
code:
value: |
MATCH (n)-[e]-(m)
WHERE id(e) = $selectedEdgeId
WITH id(n) as start, id(m) as end
MATCH (n)-[r]-(m)
WHERE id(n) = start OR id(m) = end
RETURN n, r, m;
```

You can use the following parameters in your Cypher queries:

- `$selectedEdgeId` — The ID of the relationship that was clicked.
- `$nodeIds` — A list of IDs of all nodes currently visible in
the graph view.
- `$edgeIds` — A list of IDs of all relationships currently
visible in the graph view.

Each action must have a `label` field, which will be displayed
on the UI button.
Expand Down Expand Up @@ -525,7 +620,7 @@ case.
This feature requires an Enterprise license.
</Callout>

{<h4 className="custom-header">General override example</h4>}
{<h4 className="custom-header">General override example</h4>}

To override the system default GSS for all themes:

Expand All @@ -551,7 +646,7 @@ features:

```

{<h4 className="custom-header">Theme-specific GSS override</h4>}
{<h4 className="custom-header">Theme-specific GSS override</h4>}

To apply different GSS for light and dark themes, use the `theme` field
with values `light` or `dark`:
Expand Down Expand Up @@ -789,6 +884,15 @@ features:
- id: hide
isHidden: false

- name: graph.edges.system.configure
items:
- id: expand
isHidden: false
- id: collapse
isHidden: false
- id: hide
isHidden: false

# Enterprise feature
- name: graph.nodes.user.configure
items:
Expand All @@ -807,6 +911,20 @@ features:
WHERE id(n) = $selectedNodeId
RETURN p;

# Enterprise feature
- name: graph.edges.user.configure
items:
- label: Expand nodes
query:
code:
value: |
MATCH (n)-[e]-(m)
WHERE id(e) = $selectedEdgeId
WITH id(n) as start, id(m) as end
MATCH (n)-[r]-(m)
WHERE id(n) = start OR id(m) = end
RETURN n, r, m;

# Enterprise feature
- name: gss.system.configure
items:
Expand Down
Loading