Jump to content

swagger-UI REALLY SLOW


Recommended Posts

Posted

Hi,

 

I seem to be experiencing an issue where the Swagger-UI is incredibly slow. It can take over 3 minutes to load. During this time the page is totally unresponsive.

 

Any help would be great.

 

Thanks,

Posted

Yes I've noticed that. haven't had a chance to look into it. i think it has some UI libraries that are really slow.

  • 2 weeks later...
ctrlaltdefeat
Posted

Any updates on this? I don't see any other documents available and the swaggerui as it is, is impossible to use

Posted

Any updates on this? I don't see any other documents available and the swaggerui as it is, is impossible to use

 

I haven't found that to be the case.

 

It does freeze the page so badly that Chrome asks if you want to kill it when you first bring it up but, if you just let it get through that, I find it completely responsive once it is up.

Angelblue05
Posted (edited)

I can't get swagger to work anymore. No matter the api key I put in, it just gives me security exception when trying the api. :( It also crashes a lot.

Edited by Angelblue05
ctrlaltdefeat
Posted (edited)

I haven't found that to be the case.

 

It does freeze the page so badly that Chrome asks if you want to kill it when you first bring it up but, if you just let it get through that, I find it completely responsive once it is up.

When opening it in chrome I don't even get the choice to kill it or not; http://i.imgur.com/FSfOURQ.png

In any other browser I've tried(IE, Edge, FF) it just hangs for minutes every time I click something

 

#edit;

by hanging I mean the entire browser becoming unresponsive 

Edited by ctrlaltdefeat
Posted

Where do you apply the auth-token in the swagger UI?

Posted

When opening it in chrome I don't even get the choice to kill it or not; http://i.imgur.com/FSfOURQ.png

In any other browser I've tried(IE, Edge, FF) it just hangs for minutes every time I click something

 

#edit;

by hanging I mean the entire browser becoming unresponsive 

 

Don't click on anything until moving your mouse across the items on the page causes them to "light up".

Posted

Where do you apply the auth-token in the swagger UI?

 

It will fill in automatically if you open it with the "Api" link on the dashboard (bottom).

Angelblue05
Posted (edited)

It will fill in automatically if you open it with the "Api" link on the dashboard (bottom).

 

It doesn't work. I just tried GET /users and I get this: 

{
  "ResponseStatus": {
    "ErrorCode": "SecurityException",
    "Message": "Access token is invalid or expired.",
    "StackTrace": "   at MediaBrowser.Server.Implementations.HttpServer.Security.AuthService.ValidateSecurityToken(IServiceRequest request, String token)\r\n   at MediaBrowser.Server.Implementations.HttpServer.Security.AuthService.ValidateUser(IServiceRequest request, IAuthenticationAttributes authAttribtues)\r\n   at MediaBrowser.Server.Implementations.HttpServer.Security.AuthService.Authenticate(IServiceRequest request, IAuthenticationAttributes authAttribtues)\r\n   at MediaBrowser.Controller.Net.AuthenticatedAttribute.RequestFilter(IRequest request, IResponse response, Object requestDto)\r\n   at ServiceStack.ServiceStackHost.ApplyRequestFiltersSingle(IRequest req, IResponse res, Object requestDto)\r\n   at ServiceStack.ServiceStackHost.ApplyRequestFilters(IRequest req, IResponse res, Object requestDto)\r\n   at ServiceStack.Host.RestHandler.ProcessRequestAsync(IRequest httpReq, IResponse httpRes, String operationName)"
  }
}
Edited by Angelblue05
Posted

Is there an api key filled in at the top of the page?  If not go get one out of the server dashboard and paste it in there.

  • Like 1
Angelblue05
Posted (edited)

@@ebr

 

No, there's no api key filled at the top. But when I put one in, click explore to reload with the api key, I get the same error. I know the api key is valid. It used to work correctly, until recently. :)

 

Edit: Actually, this time I put in the key, and it didn't crash like post #6, so I think it accepted the key because now it works. However the auto-fill of the api key doesn't work in my case (dashboard > api at the bottom).

Edited by Angelblue05
Posted

there is a bug in swagger itself, however there must be some others here who have skill with html and javascript and can help. swagger uses a number of third party libraries. maybe if it's being caused by something non-essential we can just take it out.

  • 1 year later...
Posted

Swagger will be back for the next release and will look better than ever:

 

59b0c60cc1e30_Untitled.png

 

59b35afcb8e16_Untitled.png

  • 9 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...