rl-cloud-api-sdk
Advanced tools
Comparing version 1.3.0 to 1.3.1
@@ -272,2 +272,10 @@ import { CreateSubscriptionParameters, SubscriptionUpdateParameters, CidrUpdateParameters, VpcPeeringCreationParameters } from './types/parameters/subscription'; | ||
/** | ||
* Waiting for all databases status under subscription to change to the expected status | ||
* @param subscriptionId The id of the subscription | ||
* @param expectedStatus The expected status | ||
* @param timeoutInSeconds The timeout of waiting for the status. Default: 5 minutes | ||
* @param sleepTimeInSeconds The sleep time between requests. Default: 5 seconds | ||
*/ | ||
waitForSubscriptionDatabasesStatus(subscriptionId: number, expectedStatus?: DatabaseStatus, timeoutInSeconds?: number, sleepTimeInSeconds?: number): Promise<void>; | ||
/** | ||
* Waiting for cloud account status to change to a given status | ||
@@ -274,0 +282,0 @@ * @param cloudAccountId The id of the cloud account |
@@ -627,2 +627,17 @@ "use strict"; | ||
/** | ||
* Waiting for all databases status under subscription to change to the expected status | ||
* @param subscriptionId The id of the subscription | ||
* @param expectedStatus The expected status | ||
* @param timeoutInSeconds The timeout of waiting for the status. Default: 5 minutes | ||
* @param sleepTimeInSeconds The sleep time between requests. Default: 5 seconds | ||
*/ | ||
waitForSubscriptionDatabasesStatus(subscriptionId, expectedStatus = 'active', timeoutInSeconds = 5 * 60, sleepTimeInSeconds = 5) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
let databases = yield this.getDatabases(subscriptionId); | ||
for (const database of databases) { | ||
yield this.waitForDatabaseStatus(subscriptionId, database.databaseId, expectedStatus, timeoutInSeconds, sleepTimeInSeconds); | ||
} | ||
}); | ||
} | ||
/** | ||
* Waiting for cloud account status to change to a given status | ||
@@ -629,0 +644,0 @@ * @param cloudAccountId The id of the cloud account |
{ | ||
"name": "rl-cloud-api-sdk", | ||
"version": "1.3.0", | ||
"version": "1.3.1", | ||
"description": "This is a client for the Redislabs Cloud API", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
89620
1806