You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -33,20 +30,42 @@ public override IEnumerable<ValidationResult> Validate(ValidationContext validat
33
30
yieldreturnnewValidationResult("RBAC auth does not support Container creation",new[]{nameof(UseRbacAuth)});
34
31
}
35
32
36
-
if(string.IsNullOrWhiteSpace(PartitionKeyPath))
33
+
if(MissingPartitionKeys())
37
34
{
38
-
yieldreturnnewValidationResult("PartitionKeyPath must be specified when RecreateContainer is true",new[]{nameof(PartitionKeyPath)});
35
+
yieldreturnnewValidationResult("PartitionKeyPath must be specified when RecreateContainer is true",new[]{nameof(PartitionKeyPath),nameof(PartitionKeyPaths)});
yieldreturnnewValidationResult("PartitionKeyPath must start with /",new[]{nameof(PartitionKeyPath)});
48
+
if(!PartitionKeyPath.StartsWith("/"))
49
+
{
50
+
yieldreturnnewValidationResult("PartitionKeyPath must start with /",new[]{nameof(PartitionKeyPath)});
51
+
}
44
52
}
45
53
46
-
if(string.IsNullOrWhiteSpace(PartitionKeyPath)&&WriteModeisDataWriteMode.InsertStream or DataWriteMode.UpsertStream)
54
+
if(MissingPartitionKeys()&&WriteModeisDataWriteMode.InsertStream or DataWriteMode.UpsertStream)
47
55
{
48
-
yieldreturnnewValidationResult("PartitionKeyPath must be specified when WriteMode is set to InsertStream or UpsertStream",new[]{nameof(PartitionKeyPath),nameof(WriteMode)});
56
+
yieldreturnnewValidationResult("PartitionKeyPath must be specified when WriteMode is set to InsertStream or UpsertStream",new[]{nameof(PartitionKeyPath),nameof(PartitionKeyPaths),nameof(WriteMode)});
0 commit comments