Skip to content

Commit

Permalink
[Web] Increase polling frequency
Browse files Browse the repository at this point in the history
At a recent meeting, there were incidences of simultanous checkouts
within the poll interval--i.e. mentor A checked out a student right
after mentor B checked out the same student, before mentor A's device
had polled for the updated information. This causes desync, and a 422
http error. The temporary solution is to poll more frequently, so that
the issue is less likely.

We should also probably handle the 422 errors gracefully, but if I
decide to do that, that'll happen in a separate commit.
  • Loading branch information
lost1227 committed Jan 23, 2024
1 parent f5b8a7f commit 64be506
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion attendance-web/src/environments/environment.prod.ts
Expand Up @@ -2,5 +2,5 @@ export const environment = {
production: true,
apiRoot: "/attendance/api",
authRoot: "/attendance/auth",
pollInterval: 5000
pollInterval: 500
};
2 changes: 1 addition & 1 deletion attendance-web/src/environments/environment.ts
Expand Up @@ -6,7 +6,7 @@ export const environment = {
production: false,
apiRoot: "/api",
authRoot: "/auth",
pollInterval: 5000
pollInterval: 500
};

/*
Expand Down

0 comments on commit 64be506

Please sign in to comment.