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
Copy file name to clipboardExpand all lines: Extensions/Cosmos/README.md
+22-4Lines changed: 22 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,14 @@ Source and sink settings also both require parameters to specify the data locati
16
16
-`Database`
17
17
-`Container`
18
18
19
-
Source supports an optional `IncludeMetadataFields` parameter (`false` by default) to enable inclusion of built-in Cosmos fields prefixed with `"_"`, for example `"_etag"` and `"_ts"`. An optional PartitionKeyValue setting allows for filtering to a single partition. The optional Query setting allows further filtering using a Cosmos SQL statement. An optional `WebProxy` parameter (`null` by default) enables connections through a proxy.
19
+
Source supports the following optional parameters:
20
+
-`IncludeMetadataFields` (`false` by default) - Enables inclusion of built-in Cosmos fields prefixed with `"_"`, for example `"_etag"` and `"_ts"`.
21
+
-`PartitionKeyValue` - Allows for filtering to a single partition.
22
+
-`Query` - Allows further filtering using a Cosmos SQL statement.
23
+
-`WebProxy` (`null` by default) - Enables connections through a proxy.
24
+
-`UseDefaultProxyCredentials` (`false` by default) - When `true`, includes default credentials in the WebProxy request. Use this when connecting through an authenticated proxy that returns [`407 Proxy Authentication Required`](https://learn.microsoft.com/dotnet/api/system.net.webproxy.credentials?view=net-10.0#remarks).
25
+
-`UseDefaultCredentials` (`false` by default) - When `true`, configures the underlying HttpClient with default network credentials. Use this when the connection to CosmosDB requires authentication through a proxy.
26
+
-`PreAuthenticate` (`false` by default) - When `true`, enables pre-authentication on the HttpClient, which sends credentials with the initial request rather than waiting for a 401/407 challenge. This can save extra round-trips but should only be used when the endpoint is trusted.
20
27
21
28
### Always Encrypted
22
29
@@ -36,7 +43,10 @@ The extension will also automatically handle the encryption keys and encryption
36
43
"IncludeMetadataFields": false,
37
44
"PartitionKeyValue":"123",
38
45
"Query":"SELECT * FROM c WHERE c.category='event'",
39
-
"WebProxy":"http://yourproxy.server.com/"
46
+
"WebProxy":"http://yourproxy.server.com/",
47
+
"UseDefaultProxyCredentials": true,
48
+
"UseDefaultCredentials": true,
49
+
"PreAuthenticate": true
40
50
}
41
51
```
42
52
@@ -52,8 +62,11 @@ Or with RBAC:
52
62
"IncludeMetadataFields": false,
53
63
"PartitionKeyValue":"123",
54
64
"Query":"SELECT * FROM c WHERE c.category='event'",
55
-
"InitClientEncryption": false
56
-
"WebProxy":"http://yourproxy.server.com/"
65
+
"InitClientEncryption": false,
66
+
"WebProxy":"http://yourproxy.server.com/",
67
+
"UseDefaultProxyCredentials": true,
68
+
"UseDefaultCredentials": true,
69
+
"PreAuthenticate": true
57
70
}
58
71
```
59
72
@@ -85,6 +98,11 @@ Or with RBAC:
85
98
-`Gateway` (default)
86
99
-`Direct`
87
100
101
+
-**`WebProxy`**: Optional. Specifies the proxy server URL to use for connections (e.g., `http://yourproxy.server.com/`).
102
+
-**`UseDefaultProxyCredentials`**: Optional, defaults to `false`. When `true`, includes default credentials in the WebProxy request. Use this when connecting through an authenticated proxy that returns [`407 Proxy Authentication Required`](https://learn.microsoft.com/dotnet/api/system.net.webproxy.credentials?view=net-10.0#remarks).
103
+
-**`UseDefaultCredentials`**: Optional, defaults to `false`. When `true`, configures the underlying HttpClient with default network credentials. Use this when the connection to CosmosDB requires authentication through a proxy.
104
+
-**`PreAuthenticate`**: Optional, defaults to `false`. When `true`, enables pre-authentication on the HttpClient, which sends credentials with the initial request rather than waiting for a 401/407 challenge. This can save extra round-trips but should only be used when the endpoint is trusted.
105
+
88
106
-**`LimitToEndpoint`**: Optional, defaults to `false`. When the value of this property is false, the Cosmos DB SDK will automatically discover
89
107
write and read regions, and use them when the configured application region is not available.
90
108
When set to `true`, availability is limited to the endpoint specified.
0 commit comments