Skip to content

Commit

Permalink
feat!: add timeout for core to release project lock (#1982) (#2025)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: Requires renku-core v1.7.0 or greater
  • Loading branch information
cramakri authored and ciyer committed Sep 15, 2022
1 parent 6426f1d commit 332a052
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion client/src/api-client/project.js
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,8 @@ function addProjectMethods(client) {
*/
client.getProjectLockStatus = async (projectRepositoryUrl, versionUrl = null) => {
const url = client.versionedCoreUrl("project.lock_status", versionUrl);
const queryParams = { git_url: projectRepositoryUrl };
// wait up to 2s if a project is locked to give it time to free
const queryParams = { git_url: projectRepositoryUrl, timeout: 2.0 };
const headers = client.getBasicHeaders();
headers.append("Content-Type", "application/json");
headers.append("X-Requested-With", "XMLHttpRequest");
Expand Down

0 comments on commit 332a052

Please sign in to comment.