kthcloud / console

kthcloud web console
https://cloud.cbh.kth.se
MIT License
3 stars 3 forks source link

Fix resource not found when creating #259

Closed pierrelefevre closed 1 month ago

pierrelefevre commented 2 months ago

We currently use the number of loads (3) to determine if a resource on the /edit page exists or not.

When creating a resource, beginFastLoad() is called and the number of requests explodes. 3 loads does not give the backend enough time to create the new resource, resulting in a 404 error for the user on the console.

This could be fixed by using a timeout instead, or perhaps removing the redirect altogether.

pierrelefevre commented 1 month ago

Found a bug in fastLoad, hook was called each time the interval was changed - not after the set interval. Fixed and should now behave as intended. Perhaps this will solve the issue or we could just increase the threshold of failed attempts a bit.

pierrelefevre commented 1 month ago

seems we are using if (reloads > 10)

should be fine, closing for now