DB Shell: Fix User Consent Message as per Privacy Guidlines and enable this for customers (#2173)

* Fix user Consent msg and fix issues

* fix format

* test fix

* fix snap file
This commit is contained in:
Sourabh Jain 2025-07-07 21:13:34 +05:30 committed by GitHub
parent 45c8d70c77
commit f8231600d6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 55 additions and 28 deletions

View File

@ -44,32 +44,26 @@ export const startCloudShellTerminal = async (terminal: Terminal, shellType: Ter
resolvedRegion = determineCloudShellRegion();
resolvedRegion = determineCloudShellRegion();
terminal.writeln(formatWarningMessage("⚠️ IMPORTANT: Azure Cloud Shell Region Notice ⚠️"));
terminal.writeln(
formatInfoMessage(
"The Cloud Shell environment will operate in a region that may differ from your database's region.",
),
);
terminal.writeln(formatInfoMessage("This has two potential implications:"));
terminal.writeln(formatInfoMessage("By using this feature, you acknowledge and agree to the following"));
terminal.writeln(formatInfoMessage("1. Performance Impact:"));
terminal.writeln(
formatInfoMessage(" Commands may experience higher latency due to geographic distance between regions."),
);
terminal.writeln(formatInfoMessage("2. Data Compliance Considerations:"));
terminal.writeln(formatInfoMessage("2. Data Transfers:"));
terminal.writeln(
formatInfoMessage(
" Data processed through this shell could temporarily reside in a different geographic region,",
" Data processed through this Cloud Shell service can be processed outside of your tenant's geographical region, compliance boundary or national cloud instance.",
),
);
terminal.writeln(
formatInfoMessage(" which may affect compliance with data residency requirements or regulations specific"),
);
terminal.writeln(formatInfoMessage(" to your organization."));
terminal.writeln("");
terminal.writeln("\x1b[94mFor more information on Azure Cosmos DB data governance and compliance, please visit:");
terminal.writeln("\x1b[94mFor more information on Azure Cosmos DB data residency, please visit:");
terminal.writeln("\x1b[94mhttps://learn.microsoft.com/en-us/azure/cosmos-db/data-residency\x1b[0m");
// Ask for user consent for region

View File

@ -258,14 +258,7 @@ Key limitations:
### Data Residency
Data residency requirements may not be fully satisfied when using CloudShell due to limited regional availability. CloudShell services are currently available in the following regions:
| Geography | Regions |
|-----------|---------|
| Americas | East US, West US 2, South Central US, West Central US |
| Europe | West Europe, North Europe |
| Asia Pacific | Southeast Asia, Japan East, Australia East |
| Middle East | UAE North |
Data residency requirements may not be fully satisfied when using CloudShell due to limited regional availability.
**Note:** For up-to-date supported regions, refer to the region configuration in:
`src/Explorer/CloudShell/Configuration/RegionConfig.ts`

View File

@ -13,7 +13,7 @@ export const DISABLE_HISTORY = `set +o history`;
* Command that displays an error message and exits the shell session.
* Used when shell initialization or connection fails.
*/
export const EXIT_COMMAND = ` printf "\\033[1;31mSession ended. Please close this tab and initiate a new shell session if needed.\\033[0m\\n" && exit`;
export const EXIT_COMMAND = ` printf "\\033[1;31mSession ended. Please close this tab and initiate a new shell session if needed.\\033[0m\\n" && disown -a && exit`;
/**
* Abstract class that defines the interface for shell-specific handlers

View File

@ -8,6 +8,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
"children": [
{
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -23,6 +28,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
],
"className": "collectionNode",
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -45,6 +55,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
"children": [
{
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -65,6 +80,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
],
"className": "collectionNode",
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -123,6 +143,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
"children": [
{
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -138,6 +163,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
],
"className": "collectionNode",
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -187,6 +217,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
"children": [
{
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -257,6 +292,11 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Ca
],
"className": "collectionNode",
"contextMenu": [
{
"iconSrc": {},
"label": "Open Cassandra Shell",
"onClick": [Function],
},
{
"iconSrc": {},
"label": "Delete Table",
@ -323,7 +363,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -354,7 +394,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -386,7 +426,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -422,7 +462,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -490,7 +530,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -521,7 +561,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -580,7 +620,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{
@ -666,7 +706,7 @@ exports[`createDatabaseTreeNodes generates the correct tree structure for the Mo
},
{
"iconSrc": {},
"label": "New Shell",
"label": "Open Mongo Shell",
"onClick": [Function],
},
{

View File

@ -111,7 +111,7 @@ export function extractFeatures(given = new URLSearchParams(window.location.sear
copilotChatFixedMonacoEditorHeight: "true" === get("copilotchatfixedmonacoeditorheight"),
enablePriorityBasedExecution: "true" === get("enableprioritybasedexecution"),
disableConnectionStringLogin: "true" === get("disableconnectionstringlogin"),
enableCloudShell: "true" === get("enablecloudshell"),
enableCloudShell: true,
};
}