refactor: prepare for token refreshing
This MR contains several commits that make sure that the whole extension uses RefreshingGitLabService
to access the GitLab API.
This is important because once we introduce the token refreshing, we'll have to check the token validity before every API call.
The way we'll refresh token in the future MR
graph TD
A[Client code] --"get data from API"--> B[RefreshingGitLabService]
B --"getCredentials"--> C{Is token valid?}
C --yes--> D[Use the token]
C --no--> E[TokenExchangeService]
D --"with old token" --> F[API Call]
E --"with refreshed token" --> F
This MR is best-reviewed commit-by-commit.
Related to #561 (closed)
Edited by Tomas Vik