Skip to content

Conversation

Arnei
Copy link
Member

@Arnei Arnei commented Jul 22, 2025

Breaks without the associated backend changes opencast/opencast#6924

Hopefully helps with #1230.

If you have many series in your Opencast, any modal that displays event metadata can take several seconds to load. This patch aims at pushing the loading time back into millisecond terrritory no matter how many series there are.

The problem is that when fetching event metadata from the backend, the backend also fetch all series options, which can take too long. So we change the backend to not do that, and change the frontend to fetch the series options separately.

Ideally we could also do this for other metadata fields with options (notably contributors and presenters), but the endpoint lacks the necessary filter capabilities.

How to test this patch

Install together with the required backend PR. Try to change series for new or existing events.
If you want to check for performance benefits, use an Opencast with ~10000 series.

Bildschirmaufzeichnung.vom.2025-07-22.13-54-35.webm

Copy link
Contributor

Use docker or podman to test this pull request locally.

Run test server using develop.opencast.org as backend:

podman run --rm -it -p 127.0.0.1:3000:3000 ghcr.io/opencast/opencast-admin-interface:pr-1375

Specify a different backend like stable.opencast.org:

podman run --rm -it -p 127.0.0.1:3000:3000 -e PROXY_TARGET=https://stable.opencast.org ghcr.io/opencast/opencast-admin-interface:pr-1375

It may take a few seconds for the interface to spin up.
It will then be available at http://127.0.0.1:3000.
For more options you can pass on to the proxy, take a look at the README.md.

@gregorydlogan
Copy link
Member

gregorydlogan commented Aug 7, 2025

Should this be in develop when the backend changes will land in r/18.x?

When applied (front and back-end), new events don't seem to load the series at all - no series are ever listed.

@Arnei
Copy link
Member Author

Arnei commented Aug 8, 2025

Yes, they should go into the same branch, thanks for pointing that out.

Unless, of course, they are broken. Will check.

Arnei added 2 commits August 8, 2025 10:58
…usly

If you have many series in your Opencast, any modal that displays
event metadata can take several seconds to load. This patch aims at
pushing the loading time back into millisecond terrritory no matter
how many series there are.

The problem is that when fetching event metadata from the backend,
the backend also fetch all series options, which can take too long.
So we change the backend to not do that, and change the frontend to
fetch the series options separately.

ideally we could also do this for other metadata fields with options
(notably contributors and presenters), but the endpoint lacks
the necessary filter capabilities.
Apparently our textFilter is now automatically treated as wildcard
search and the "*" we used to trigger wildcard search are now breaking
it, so we can just remove them.
@Arnei Arnei force-pushed the async-select-for-collections branch from a33b909 to 59f7ae0 Compare August 8, 2025 09:30
@Arnei Arnei changed the base branch from develop to r/18.x August 8, 2025 09:31
@Arnei
Copy link
Member Author

Arnei commented Aug 8, 2025

Not quite sure why the build workflow is failing now. Builds on my machine. The issue with the series not loading should be fixed now though.

@gregorydlogan
Copy link
Member

Could this be node related? The workflows install a 20.x release, and when I use 20 I see this:

npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: 'vite@7.0.3',
npm WARN EBADENGINE   required: { node: '^20.19.0 || >=22.12.0' },
npm WARN EBADENGINE   current: { node: 'v20.12.2', npm: '10.5.0' }
npm WARN EBADENGINE }

@Arnei
Copy link
Member Author

Arnei commented Aug 11, 2025

Probably not? If I read the workflow logs correctly the workflow is using node v20.19.4 which should be fine with vite 7.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants