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

ModelAdmin has_many searchForm queueing causes hang #9091

Closed
mikeyc7m opened this issue Jun 25, 2019 · 3 comments
Closed

ModelAdmin has_many searchForm queueing causes hang #9091

mikeyc7m opened this issue Jun 25, 2019 · 3 comments

Comments

@mikeyc7m
Copy link
Contributor

Affected Version

4.3.1

Description

The new ModelAdmin searchForm uses a graphql search lookup service. It is being applied to has_many relationships on a dataobject in modeladmin and this can cause queueing and the user experiences delays. Also when the search field is exposed, the "Link Existing" field disappears.

Steps to Reproduce

We've got a complex data model with 41 has_many relationships on a particular dataobject. When we use ModelAdmin to edit that object, we see an explosion of graphql queries to load the search forms for those 41 relationships. The browser can only handle a handful of queries at a time, so they all get queued up and the user has to wait for them all to complete. Many of the requests return 400 error anyway (response is "No search form could be generated"). Is there a way to disable the search lookup per relationship?

Perhaps it would be more preactical if the searchForm schema was queried on demand (when someone clicks the search icon) rather than all relationships queried on page load?

@mikeyc7m
Copy link
Contributor Author

mikeyc7m commented Jul 1, 2019

yeah the cms is unusable because of this, any ideas on how to correct?

@mikeyc7m mikeyc7m changed the title ModelAdmin has_many searchForm queueing ModelAdmin has_many searchForm queueing causes hang Jul 31, 2019
@maxime-rainville
Copy link
Contributor

This is probably related to silverstripe/silverstripe-admin#700

If we could update the react search component when you actually click the search button, that would probably solve your problem as well.

@ScopeyNZ
Copy link
Contributor

Yeah I'm going to close this as a duplicate of silverstripe/silverstripe-admin#700. Hopefully we can get to this with priority...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants