bcgov / foi-flow

Freedom of Information modernization
Apache License 2.0
5 stars 3 forks source link

Stuck Loading - Accessing Comment from a Notification #3828

Open KyEggleston opened 1 year ago

KyEggleston commented 1 year ago

Describe the bug in current situation

Posted in Teams channel:

"MOD is freezing when I use the comment notification to go to a request and sometimes when I have entered a request normally but click on comments. Today, I am clicking on a comment notification that a file has been moved to the response state. It opens the request with the comments section on the left highlighted, but there is just a spinning "flower". The file is HSG-2023-30793. This has happened maybe 5 or 6 times in the last week ~ week and a half. I have to log out of MOD and sign back in in order to access the comments. But if I was to go back to the home page and go anywhere else everything works, and then I go back into the same request I originally tried, click on comments and it still hangs up."

Link bug to the User Story

Impact of this bug Describe the impact, i.e. what the impact is, and number of users impacted.

Chance of Occurring (high/medium/low/very low)

Pre Conditions: which Env, any pre-requesites or assumptions to execute steps?

Steps to Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Actual/ observed behaviour/ results

Expected behaviour A clear and concise description of what you expected to happen. Use the gherking language.

Screenshots/ Visual Reference/ Source If applicable, add screenshots to help explain your problem. You an use screengrab.

nkan-aot commented 1 year ago

After some investigation, it appears it is caused by getting the list of users for tagging purposes and related cache entry. There has been a recent influx of keycloak users due to onboarding new ministries, so this may be why it is only happening in prod and not dev or test.

Also theoretically it should still not cause slowness, since every morning at 5am the cache is repopulated with the list of users. In order to confirm we will need to play around with the cache in prod after hours.

Suggested front end fix would be to have a separate loader for the tag list, so users can still view comments while tag list is loading. Presumably users more often will only need to view comments vs needing to tag a user.

lmullane commented 1 year ago

Thanks, @nkan-aot. Keep us posted