Occassional login and timeout

Hello~

I’m building an app with nextjs-auth0 SDK. I can sometimes successfully log in but sometimes get an “access_denied” error. Why does it happen? I am confused about the occassional success logins. I did some research on the issue but still cannot figure out the problem as info is limited.

{
  "error": "access_denied",
  "error_description": "Timeout awaiting 'response' for 10000ms"
}

Even after I cleared the browser’s cache and cookies, the problem still exists. I can log back in hours later, but will soon get into this trouble again if I logout and try to re-login.

This happens on both dev and production. I also find that each time the timeout error occurs, my server is slowed down significantly for 10+ seconds (or even stopped temporarily, I am not quite sure which case it is in).

I use the Try Connection button provided in the “Authentication > Database” section on the dashboard to try accessing the database directly but the same error still pops up. It says:

If you are seeing this, it means that your connection didn’t work.

These are the details:

{
  "error": "access_denied",
  "error_description": "Timeout awaiting 'response' for 10000ms"
}

Could you please give me some advice on how to check for potential issues that cause this problem?

Thank you.

  • Which SDK this is regarding: nextjs-auth0
  • SDK Version: 1.4.2
  • Platform Version: Node 12.19.0
  • Code Snippets/Error Messages/Supporting Details/Screenshots:

Hi @andydowell ,

Do you have any actions/rules/hooks that calls external endpoints? The access_denied error sounds like an error returned from an extensibility point. Could you kindly try disabling the actions/rules/hooks you have and try to reproduce this issue?

If you are able to perform logs after disabling actions/rules/hooks, then try to debug them using the Real-time Webtask Logs extension.

My suspicion is you have an action/rule/hook that calls an external API endpoint that timeouts.

Let us know how it goes. Thank you!

1 Like

I disable an action, which does call an external endpoint and is triggered upon login, and now the login system seems to be functioning smoothly.

Thank you so much for saving my day!

1 Like

No worries! We’re here for you!