Skip to content

Commit 4cd6b32

Browse files
toswedluisra-fel
andauthored
[CosmosDB] Changing the warning message for AnalyticalStorageSchemaType (Azure#15723)
* changing the warning message for AnalyticalStorageSchemaType to only display when a value has been explicitly provided * adjusting the changelog * Update changelog Co-authored-by: Yeming Liu <[email protected]>
1 parent dee07ec commit 4cd6b32

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/CosmosDB/CosmosDB/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
-->
2020

2121
## Upcoming Release
22+
* Fixed when a warning about the value of AnalyticalStorageSchemaType is displayed when no value was given.
2223

2324
## Version 1.4.0
2425
* Introduced Get-AzCosmosDBMongoDBBackupInformation to retrieve latest backup information for MongoDB.

src/CosmosDB/CosmosDB/CosmosDBAccount/NewOrUpdateAzCosmosDBAccount.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,11 @@ protected AnalyticalStorageConfiguration CreateAnalyticalStorageConfiguration(st
170170
break;
171171

172172
default:
173-
string message = $"Invalid value for AnalyticalStorageSchemaType. Valid values are '{SDKModel.AnalyticalStorageSchemaType.WellDefined}' and '{SDKModel.AnalyticalStorageSchemaType.FullFidelity}'.";
174-
WriteWarning(message);
173+
if (!string.IsNullOrWhiteSpace(param))
174+
{
175+
string message = $"Invalid value for AnalyticalStorageSchemaType. Valid values are '{SDKModel.AnalyticalStorageSchemaType.WellDefined}' and '{SDKModel.AnalyticalStorageSchemaType.FullFidelity}'.";
176+
WriteWarning(message);
177+
}
175178
break;
176179
}
177180
return retval;

0 commit comments

Comments
 (0)