API Explorer hangs on large service layer

I have 2 service layer projects, in the smaller one, the API Explorer works very well. In my larger one (550+ services), the API explorer page takes a very long time (20-30 minutes) before it will come up for any service. The last step of the console log reads:

info: Microsoft.AspNetCore.Hosting.Diagnostics[1]
      Request starting HTTP/1.1 GET http://localhost:5000/DVSvc/ui/AdvLookups - -

Unfortunately we’ve exercised previous efforts in getting API Explorer to work with large APIs where it no longer uses JSONP to workaround the exceeded JS method callstack errors, so now you’re just hitting the resource limits of your browser & pc for handling the App metadata & render its UI.

Only real solution I can recommend is splitting your App into smaller microservices to reduce the App size & resources burden.

There’s also a potential for reducing the APIs you want to show up in API Explorer by modifying the metadata returned to reduce the APIs included in API Explorer, e.g. by not including APIs grouped within a tag:

this.AddToAppMetadata(meta => {
    meta.Api.Operations.RemoveAll(x => x.Tags?.Contains(tagName) != true);

Out of curiosity how large is your /metadata/app.json?

It’s 9.5 MB. Thanks for the info, I think we can use the tagging to get what we need

1 Like

In the latest v6.1.1 on MyGet I’ve added the ability to restrict the metadata & ui to only display the tag groups by adding ?IncludeTypes to the URL, e.g:


This follows the Include Types pattern where you can view multiple tag groups with:


This can also be used in Locode and Admin UI

1 Like

This is now integrated on the /metadata page where if you select a tag the API Explorer link will be updated with ?IncludeTypes={tag}

So your customers will be able to open API Explorer restricted to APIs with that tag without needing to manually craft the URL.

1 Like