mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-21 09:51:11 +00:00
Added rough button to command bar to allow switching of client endpoint.
This commit is contained in:
@@ -265,25 +265,13 @@ async function configureHostedWithAAD(config: AAD): Promise<Explorer> {
|
||||
throw new Error(`List keys failed: ${e.message}`);
|
||||
}
|
||||
}
|
||||
// Updating database account endpoint for testing purposes.
|
||||
const updatedDatabaseAccount = {
|
||||
...config.databaseAccount,
|
||||
properties: {
|
||||
...config.databaseAccount.properties,
|
||||
documentEndpoint: "https://test-craig-nosql-periodic.documents.azure.com:443/",
|
||||
},
|
||||
};
|
||||
updateUserContext({
|
||||
subscriptionId,
|
||||
resourceGroup,
|
||||
aadToken,
|
||||
databaseAccount: updatedDatabaseAccount,
|
||||
databaseAccount: config.databaseAccount,
|
||||
masterKey: keys.primaryMasterKey,
|
||||
});
|
||||
console.log(`INITIALIZED ENDPOINT: ${JSON.stringify(userContext.databaseAccount.properties.documentEndpoint)}`);
|
||||
userContext.databaseAccount.properties.readLocations.forEach((readLocation) => {
|
||||
console.log(`REGIONAL READ ENDPOINT(S): ${JSON.stringify(readLocation)}`);
|
||||
});
|
||||
const explorer = new Explorer();
|
||||
return explorer;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user