diff --git a/src/backupcleaner.js b/src/backupcleaner.js index bbc09e19e..f3ea05b4b 100644 --- a/src/backupcleaner.js +++ b/src/backupcleaner.js @@ -276,7 +276,7 @@ async function run(progressCallback) { const backupConfig = await settings.getBackupConfig(); const { retention } = await settings.getBackupPolicy(); - const status = await storage.api(backupConfig.provider).getBackupProviderStatus(backupConfig); + const status = await storage.api(backupConfig.provider).getProviderStatus(backupConfig); debug(`clean: mount point status is ${JSON.stringify(status)}`); if (status.state !== 'active') throw new BoxError(BoxError.MOUNT_ERROR, `Backup endpoint is not mounted: ${status.message}`); diff --git a/src/backuptask.js b/src/backuptask.js index e85cef2f6..73f302387 100644 --- a/src/backuptask.js +++ b/src/backuptask.js @@ -52,7 +52,7 @@ async function checkPreconditions(backupConfig, dataLayout) { assert(dataLayout instanceof DataLayout, 'dataLayout must be a DataLayout'); // check mount status before uploading - const status = await storage.api(backupConfig.provider).getBackupProviderStatus(backupConfig); + const status = await storage.api(backupConfig.provider).getProviderStatus(backupConfig); debug(`upload: mount point status is ${JSON.stringify(status)}`); if (status.state !== 'active') throw new BoxError(BoxError.MOUNT_ERROR, `Backup endpoint is not active: ${status.message}`); diff --git a/src/storage/filesystem.js b/src/storage/filesystem.js index f40a664cd..498efc74b 100644 --- a/src/storage/filesystem.js +++ b/src/storage/filesystem.js @@ -2,7 +2,7 @@ exports = module.exports = { getBackupRootPath, - getBackupProviderStatus, + getProviderStatus, getAvailableSize, upload, @@ -62,7 +62,7 @@ function getBackupRootPath(apiConfig) { } } -async function getBackupProviderStatus(apiConfig) { +async function getProviderStatus(apiConfig) { assert.strictEqual(typeof apiConfig, 'object'); // Check filesystem is mounted so we don't write into the actual folder on disk diff --git a/src/storage/gcs.js b/src/storage/gcs.js index 85c756b54..a6f8eadcb 100644 --- a/src/storage/gcs.js +++ b/src/storage/gcs.js @@ -2,7 +2,7 @@ exports = module.exports = { getBackupRootPath, - getBackupProviderStatus, + getProviderStatus, getAvailableSize, upload, @@ -72,7 +72,7 @@ function getBackupRootPath(apiConfig) { return apiConfig.prefix; } -async function getBackupProviderStatus(apiConfig) { +async function getProviderStatus(apiConfig) { assert.strictEqual(typeof apiConfig, 'object'); return { state: 'active' }; diff --git a/src/storage/interface.js b/src/storage/interface.js index 55d21c125..03b1f0b63 100644 --- a/src/storage/interface.js +++ b/src/storage/interface.js @@ -12,7 +12,7 @@ // them to tune the concurrency based on failures/rate limits accordingly exports = module.exports = { getBackupRootPath, - getBackupProviderStatus, + getProviderStatus, getAvailableSize, upload, @@ -54,7 +54,7 @@ function getBackupRootPath(apiConfig) { return '/'; } -async function getBackupProviderStatus(apiConfig) { +async function getProviderStatus(apiConfig) { assert.strictEqual(typeof apiConfig, 'object'); return { state: 'active' }; diff --git a/src/storage/noop.js b/src/storage/noop.js index 4149889f8..80345e4cb 100644 --- a/src/storage/noop.js +++ b/src/storage/noop.js @@ -2,7 +2,7 @@ exports = module.exports = { getBackupRootPath, - getBackupProviderStatus, + getProviderStatus, getAvailableSize, upload, @@ -31,7 +31,7 @@ function getBackupRootPath(apiConfig) { return ''; } -async function getBackupProviderStatus(apiConfig) { +async function getProviderStatus(apiConfig) { assert.strictEqual(typeof apiConfig, 'object'); return { state: 'active' }; diff --git a/src/storage/s3.js b/src/storage/s3.js index a88a5453c..ba9a19944 100644 --- a/src/storage/s3.js +++ b/src/storage/s3.js @@ -2,7 +2,7 @@ exports = module.exports = { getBackupRootPath, - getBackupProviderStatus, + getProviderStatus, getAvailableSize, upload, @@ -101,7 +101,7 @@ function getBackupRootPath(apiConfig) { return apiConfig.prefix; } -async function getBackupProviderStatus(apiConfig) { +async function getProviderStatus(apiConfig) { assert.strictEqual(typeof apiConfig, 'object'); return { state: 'active' };