Skip to content
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

Add migration task for composite views #4195

Merged
merged 1 commit into from
Aug 24, 2023
Merged
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
20 changes: 19 additions & 1 deletion docs/src/main/paradox/docs/releases/v1.8-to-v1.9-migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,22 @@ Nexus Fusion also allows to restart the indexing for the different views.

## Composite views

TODO
The introduction of @ref:[partial reindexing](./v1.9-release-notes.md#partial-reindexing) for composite views required a model
change of composite views.

If your Nexus deployment relies on composite views or search, the following environment variable need to be set
when launching Delta v1.9 for the first time:

* `MIGRATE_COMPOSITE_VIEWS`: true

The following logs should appear in Delta:

```
2023-08-24 07:38:24 INFO c.e.b.n.d.p.c.m.MigrateCompositeViews - Starting composite views migration
2023-08-24 07:38:28 INFO c.e.b.n.d.p.c.m.MigrateCompositeViews - '500' composite views events have been migrated
2023-08-24 07:38:28 INFO c.e.b.n.d.p.c.m.MigrateCompositeViews - '31' composite views states have been migrated
2023-08-24 07:38:28 INFO c.e.b.n.d.p.c.m.MigrateCompositeViews - '62' composite views states have been migrated
2023-08-24 07:38:34 INFO c.e.b.n.d.p.c.m.MigrateCompositeViews - Composite views migration is now complete with (500,62) events/states updated
```

After this completes, the environment variable can be removed and Delta restarted.
25 changes: 24 additions & 1 deletion docs/src/main/paradox/docs/releases/v1.9-release-notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

TODO add link to full changes on github

TODO add potential migration page
If you are currently using Nexus Delta from 1.8.x, please
visit the @ref:[migration instructions](v1.8-to-v1.9-migration.md) for the necessary steps to successfully upgrade.

## Nexus Delta

Expand Down Expand Up @@ -47,6 +48,28 @@ Indexing errors can now be listed and filtered for a given view.

@ref:[More information](../delta/api/views/index.md#listing-indexing-failures)

### Composite views

To enhance performance of indexing of composite views, Nexus Delta introduces the following features.

#### Batching queries to the intermediate space

Construct queries to the intermediate space can now be batched.

@ref:[More information](../delta/api/views/composite-view-api.md#batching-queries-to-the-intermediate-space)

#### Partial reindexing

When a composite view is updated, a diff is performed and only the necessary spaces are reindexed.

For example, if a source is added/updated/removed, all the spaces (intermediate space and projection spaces) get reindexed.
However if a projection is added/updated/removed, now only the space related to this projection is reindexed which reduces the
number of operations and consequently speed up the indexing.

Preserving the intermediate space also reduces the fragmentation of the Blazegraph journal.

@ref:[More information](../delta/api/views/composite-view-api.md#batching-queries-to-the-intermediate-space)

### Elasticsearch Views

The Elasticsearch mapping of an Elasticsearch View can be retrieved.
Expand Down