A Cosmos DB response carries, besides its HTTP status code, a sub-status code in the x-ms-substatus header.
It tells apart failures that share a status code. For example, a point read answers 404 Not Found both
when the item does not exist and when its container does not exist; only the sub-status shows which one it is.
The SDK exposes the sub-status of a failed typed operation as CosmosException.SubStatusCode, but not on the
ResponseMessage returned by the stream APIs (ReadItemStreamAsync, CreateItemStreamAsync, …).
FSharp.Azure.Cosmos adds it there:
|
response.SubStatusCode is an F# extension property. The same value is returned by the
ResponseMessage.getSubStatusCode function, which C# calls as ResponseMessageModule.GetSubStatusCode.
It returns SubStatusCodes.Unknown (0) when the response has no sub-status.
The constants in SubStatusCodes are literals, so they can be used in F# patterns as above, and they compile to
const fields that C# can use in switch:
|
The same constants work with CosmosException.SubStatusCode from the typed APIs
(Person is the record from Getting Started):
|
A sub-status only has a meaning together with the HTTP status code. Some numbers are reused for different statuses:
Sub-status |
With status |
Constant |
|---|---|---|
1002 |
404 Not Found |
|
1002 |
410 Gone |
|
1007 |
410 Gone |
|
1007 |
503 Service Unavailable |
|
1008 |
403 Forbidden |
|
1008 |
410 Gone |
|
1012 |
403 Forbidden |
|
1012 |
503 Service Unavailable |
|
1013 |
400 Bad Request |
|
1013 |
404 Not Found |
|
1024 |
400 Bad Request |
|
1024 |
410 Gone |
|
1031 |
403 Forbidden |
|
1031 |
404 Not Found |
|
1034 |
403 Forbidden |
|
1034 |
404 Not Found |
|
2001 |
204 No Content |
|
2001 |
412 Precondition Failed |
|
2002 |
204 No Content |
|
2002 |
412 Precondition Failed |
|
2003 |
204 No Content |
|
2003 |
412 Precondition Failed |
|
2004 |
204 No Content |
|
2004 |
412 Precondition Failed |
|
2011 |
204 No Content |
|
2011 |
412 Precondition Failed |
|
2012 |
204 No Content |
|
2012 |
412 Precondition Failed |
|
3207 |
409 Conflict |
|
3207 |
429 Too Many Requests |
|
That is why SubStatusCodes is a set of constants rather than an enumeration, and why the examples above match
on the (status, sub-status) pair.
SubStatusCodes contains the codes from Microsoft Learn (the REST API HTTP status codes page, the troubleshooting
guides and the throughput buckets FAQ), from the SubStatusCodes enumeration of the .NET SDK and from the
sub-status tables of the official Python, Java and Rust SDKs. The names follow the .NET SDK.
The HTTP status of a code is the one stated by Learn or by the SDK sources; for the customer-managed key codes it comes from the data plane scenario of the customer-managed key troubleshooting guide. A status marked inferred is not stated by any of these sources and is derived from the family of the code, so treat it as a hint rather than a guarantee. Codes generated only by the Java or Rust SDK clients are not included, because the .NET SDK never returns them.
Status |
Sub-status |
Constant |
Meaning |
|---|---|---|---|
any |
0 |
|
No sub-status |
204 No Content |
2001 |
|
The replica has not reached the target LSN of a head request |
204 No Content |
2002 |
|
The replica is more than 100 LSNs behind the target of a head request |
204 No Content |
2003 |
|
The replica is more than 1000 LSNs behind the target of a head request |
204 No Content |
2004 |
|
The replica is more than 10000 LSNs behind the target of a head request |
204 No Content |
2011 |
|
The replica has not reached the target global committed LSN of a head request |
204 No Content |
2012 |
|
The replica is more than 100 global committed LSNs behind the target of a head request |
204 No Content |
2013 |
|
The replica is more than 1000 global committed LSNs behind the target of a head request |
204 No Content |
2014 |
|
The replica is more than 10000 global committed LSNs behind the target of a head request |
400 Bad Request |
1001 |
|
The partition key does not match the item or the container's partition key definition |
400 Bad Request |
1004 |
|
The cross-partition query cannot be served |
400 Bad Request |
1013 |
|
The partition key definition is not specified |
400 Bad Request |
1016 |
|
The schema owner id does not match |
400 Bad Request |
1017 |
|
The schema hash or id does not match |
400 Bad Request |
1018 |
|
The partition key definition is missing for an autoscale (autopilot) container |
400 Bad Request |
1024 |
|
The container resource id does not match the one the client cached, for example after the container was re-created with the same name |
400 Bad Request |
1101 |
|
The HTTP listener failed |
400 Bad Request |
1102 |
|
A transaction is already active |
400 Bad Request |
1103 |
|
The transaction id is invalid |
400 Bad Request |
1104 |
|
A transaction across containers is not supported |
400 Bad Request |
1105 |
|
The topology change request is invalid |
400 Bad Request |
3205 |
|
Another throughput replace operation is in progress |
400 Bad Request (inferred) |
13000 |
|
The thin client proxy does not allow multiple accounts on the same connection |
400 Bad Request (inferred) |
20007 |
|
Generated by the .NET SDK: the continuation token is malformed |
400 Bad Request |
65535 |
|
A stored procedure, trigger or user-defined function failed to compile |
401 Unauthorized (inferred) |
5000 |
|
The authorization header is missing |
401 Unauthorized (inferred) |
5001 |
|
The authorization header has an invalid format |
401 Unauthorized (inferred) |
5002 |
|
Microsoft Entra ID authentication is disabled for the account |
401 Unauthorized (inferred) |
5003 |
|
The Microsoft Entra ID token has an invalid format |
401 Unauthorized (inferred) |
5004 |
|
The Microsoft Entra ID token has an invalid signature |
401 Unauthorized (inferred) |
5005 |
|
The Microsoft Entra ID token is not valid yet |
401 Unauthorized (inferred) |
5006 |
|
The Microsoft Entra ID token has expired |
401 Unauthorized (inferred) |
5007 |
|
The Microsoft Entra ID token has an invalid issuer |
401 Unauthorized (inferred) |
5008 |
|
The Microsoft Entra ID token has an invalid audience |
401 Unauthorized (inferred) |
5009 |
|
The Microsoft Entra ID token has an invalid scope |
401 Unauthorized (inferred) |
5010 |
|
The Microsoft Entra ID token could not be obtained |
401 Unauthorized (inferred) |
5011 |
|
The Microsoft Entra ID token has no object identifier |
401 Unauthorized (inferred) |
5012 |
|
SAS token authentication is disabled for the account |
401 Unauthorized (inferred) |
5013 |
|
The Microsoft Entra ID token was revoked |
401 Unauthorized (inferred) |
5200 |
|
The Microsoft Entra ID token has an invalid signing key |
401 Unauthorized (inferred) |
5201 |
|
The groups of the Microsoft Entra ID token could not be expanded |
401 Unauthorized (inferred) |
5202 |
|
Key-based (local) authentication is disabled for the account |
401 Unauthorized (inferred) |
6053 |
|
Microsoft Fabric: the token could not be validated |
401 Unauthorized (inferred) |
6054 |
|
Microsoft Fabric: the application id is invalid |
401 Unauthorized (inferred) |
6055 |
|
Microsoft Fabric: the tenant id is invalid |
401 Unauthorized (inferred) |
6056 |
|
Microsoft Fabric: the artifact id is invalid |
401 Unauthorized (inferred) |
13008 |
|
Generated by the thin client proxy |
403 Forbidden |
3 |
|
A write was sent to a region that no longer accepts writes during a manual failover |
403 Forbidden |
1005 |
|
The provisioning limit is reached |
403 Forbidden |
1008 |
|
The database account is not found |
403 Forbidden |
1009 |
|
The container definition in the request is the same as the existing one |
403 Forbidden |
1010 |
|
The quota of containers in a shared throughput database is exceeded |
403 Forbidden |
1011 |
|
The shared throughput offer does not need to grow |
403 Forbidden |
1012 |
|
The database definition in the request is the same as the existing one |
403 Forbidden |
1014 |
|
The logical partition reached its maximum size |
403 Forbidden |
1015 |
|
Replacing the throughput of an autoscale offer is disabled |
403 Forbidden |
1019 |
|
The number of containers in a shared throughput database is exceeded |
403 Forbidden |
1020 |
|
The number of shared throughput databases is exceeded |
403 Forbidden |
1021 |
|
An internal compute error occurred |
403 Forbidden |
1026 |
|
The client id does not match |
403 Forbidden |
1027 |
|
A unique index re-indexing is in progress |
403 Forbidden |
1028 |
|
The account throughput cap is exceeded |
403 Forbidden |
1029 |
|
The throughput cap value is invalid |
403 Forbidden |
1031 |
|
A system partition key is not allowed |
403 Forbidden |
1032 |
|
The limit of delete-by-partition-key requests is exceeded |
403 Forbidden |
1033 |
|
The partition is leaked |
403 Forbidden |
1034 |
|
The resource is soft-deleted |
403 Forbidden |
1110 |
|
The condition of a conditional patch is not met |
403 Forbidden |
4000 |
|
Customer-managed keys: Azure Cosmos DB cannot get the Microsoft Entra ID access token for the Key Vault |
403 Forbidden |
4001 |
|
Customer-managed keys: the Microsoft Entra ID service is unavailable |
403 Forbidden |
4002 |
|
Customer-managed keys: the Key Vault does not grant Azure Cosmos DB access, or the key is disabled |
403 Forbidden |
4003 |
|
Customer-managed keys: the key is not found in the Key Vault |
403 Forbidden |
4004 |
|
Customer-managed keys: the Key Vault service is unavailable |
403 Forbidden |
4005 |
|
Customer-managed keys: the Key Vault cannot wrap or unwrap the key |
403 Forbidden |
4006 |
|
Customer-managed keys: the Key Vault key URL is invalid, for example it includes the key version |
403 Forbidden |
4007 |
|
Customer-managed keys: internal server error, the input bytes are not in the base64 format |
403 Forbidden |
4008 |
|
Customer-managed keys: the Key Vault returned an internal service error |
403 Forbidden |
4009 |
|
Customer-managed keys: the Key Vault DNS name cannot be resolved |
403 Forbidden (inferred) |
4010 |
|
Customer-managed keys: the Key Vault certificate URL is invalid |
403 Forbidden (inferred) |
4011 |
|
Customer-managed keys: the Key Vault key and certificate URLs are invalid |
403 Forbidden (inferred) |
4012 |
|
Customer-managed keys: the customer key was rotated |
403 Forbidden (inferred) |
4013 |
|
Customer-managed keys: a request parameter is missing |
403 Forbidden (inferred) |
4014 |
|
Customer-managed keys: the Key Vault secret URL is invalid |
403 Forbidden (inferred) |
4015 |
|
Customer-managed keys: the account has no default identity |
403 Forbidden (inferred) |
4016 |
|
Customer-managed keys: a network security perimeter denies outbound access to the Key Vault |
403 Forbidden (inferred) |
4017 |
|
Customer-managed keys: the Key Vault is not found |
403 Forbidden (inferred) |
4018 |
|
Customer-managed keys: the key is disabled or expired |
403 Forbidden (inferred) |
4019 |
|
Customer-managed keys: the master service is unavailable |
403 Forbidden |
5300 |
|
The request cannot be authorized by a Microsoft Entra ID token in the data plane |
403 Forbidden (inferred) |
5301 |
|
Role-based access control does not authorize the metadata request |
403 Forbidden (inferred) |
5302 |
|
Role-based access control does not authorize the name-based data request |
403 Forbidden (inferred) |
5303 |
|
Role-based access control does not authorize the resource-id-based data request |
403 Forbidden (inferred) |
5304 |
|
Role-based access control cannot resolve the resource id |
403 Forbidden (inferred) |
5305 |
|
Role-based access control has no user id for the request |
403 Forbidden (inferred) |
5306 |
|
Role-based access control has no action for the request |
403 Forbidden (inferred) |
5307 |
|
A network security perimeter denies the inbound request |
403 Forbidden (inferred) |
5400 |
|
Role-based access control did not authorize the request |
403 Forbidden (inferred) |
6050 |
|
Microsoft Fabric: the permissions are insufficient |
403 Forbidden (inferred) |
6051 |
|
Microsoft Fabric: authorization failed |
403 Forbidden (inferred) |
6052 |
|
Microsoft Fabric: the operation is not supported |
403 Forbidden (inferred) |
13001 |
|
The public endpoint of the thin client proxy is disabled |
404 Not Found |
1002 |
|
The read session is not available for the session token |
404 Not Found |
1003 |
|
The owner resource, a database or container, does not exist |
404 Not Found |
1013 |
|
The container create operation is still in progress; retry the read until it succeeds |
404 Not Found |
1023 |
|
The store is not ready |
404 Not Found |
1030 |
|
The authorization token is not found in the cache |
404 Not Found |
1031 |
|
The container of a migrating partition was deleted |
404 Not Found |
1034 |
|
The source partition of a partition migration was deleted in the master partition |
404 Not Found |
1035 |
|
The partition of a shared throughput database is not found during a partition migration |
404 Not Found |
1036 |
|
The partition resource is not found during a partition migration |
404 Not Found |
1037 |
|
A partition migration failed to update DNS |
408 Request Timeout |
1900 |
|
The request was preempted |
408 Request Timeout (inferred) |
13009 |
|
Generated by the thin client proxy |
409 Conflict |
1006 |
|
The operation conflicts with a control plane operation |
409 Conflict |
3050 |
|
The document counts of the source and target partitions of a partition migration do not match |
409 Conflict |
3051 |
|
The document counts of the target partition replicas of a partition migration do not match |
409 Conflict |
3206 |
|
A database with the name already exists |
409 Conflict |
3207 |
|
A configuration with the name already exists |
409 Conflict |
3301 |
|
The item violates a unique key constraint |
409 Conflict |
3302 |
|
The partition key hash collides for the id |
409 Conflict |
3303 |
|
Incremental backup to the Azure Backup vault is paused |
409 Conflict |
3304 |
|
Restore from an incremental Azure Backup vault backup is disabled |
409 Conflict (inferred) |
5401 |
|
The initial request of a retriable write has already completed |
409 Conflict (inferred) |
5402 |
|
The retriable write request is a duplicate |
409 Conflict (inferred) |
5403 |
|
The operation conflicts with another operation in the user transaction |
409 Conflict (inferred) |
6300 |
|
Truncating a container is not allowed during a merge |
410 Gone |
1000 |
|
The client's name cache is stale |
410 Gone |
1002 |
|
The partition key range is gone, for example after a split |
410 Gone |
1007 |
|
A partition split is completing |
410 Gone |
1008 |
|
A partition migration is completing |
410 Gone |
1022 |
|
The lease is not found |
410 Gone |
1024 |
|
The archival partition is not present |
412 Precondition Failed |
2001 |
|
Splitting is disabled |
412 Precondition Failed |
2002 |
|
The containers in the partition were updated |
412 Precondition Failed |
2003 |
|
The partition key ranges lock cannot be acquired |
412 Precondition Failed |
2004 |
|
The resource is not found |
412 Precondition Failed |
2005 |
|
The offer owner lock cannot be acquired |
412 Precondition Failed |
2007 |
|
The partition key range lock cannot be acquired |
412 Precondition Failed |
2008 |
|
The partition lock cannot be acquired |
412 Precondition Failed |
2011 |
|
A storage split conflicts with an n-way throughput split |
412 Precondition Failed |
2012 |
|
Merging is disabled |
412 Precondition Failed |
2015 |
|
The tombstone records are not found |
412 Precondition Failed |
2016 |
|
The account status is invalid |
412 Precondition Failed |
2017 |
|
The throughput offer validation failed |
412 Precondition Failed |
2018 |
|
The master partition access lock cannot be acquired |
412 Precondition Failed |
2019 |
|
The in-account restore lock cannot be acquired |
412 Precondition Failed |
2020 |
|
The container state changed |
412 Precondition Failed |
2021 |
|
The throughput offer was scaled up by the user |
412 Precondition Failed |
2101 |
|
The log store load balance lock cannot be acquired |
412 Precondition Failed |
5325 |
|
The container resource ids do not match on a migrate partition request during a migration |
412 Precondition Failed |
5326 |
|
The partition is not in the migrating status for a migrate partition request |
412 Precondition Failed |
5327 |
|
The partition resource is missing when completing a migration |
412 Precondition Failed |
5328 |
|
The partition resource is missing when aborting a migration |
413 Request Entity Too Large |
3401 |
|
The transaction limit is exceeded |
413 Request Entity Too Large |
3402 |
|
The batch response size is exceeded |
429 Too Many Requests |
3073 |
|
Throttled by the Bw-tree I/O rate limiter |
429 Too Many Requests |
3074 |
|
The staleness exceeded its bound |
429 Too Many Requests |
3075 |
|
The replication queue is full |
429 Too Many Requests |
3076 |
|
Throttled by back pressure from a full Bw-tree log |
429 Too Many Requests |
3077 |
|
Throttled by the connection rate limiter |
429 Too Many Requests |
3078 |
|
Throttled by the composite replicator |
429 Too Many Requests |
3079 |
|
Throttled for an unexpected reason |
429 Too Many Requests |
3080 |
|
Throttled by an asynchronous reader-writer lock |
429 Too Many Requests |
3081 |
|
Throttled by a service module |
429 Too Many Requests |
3082 |
|
A value does not match its expected bound |
429 Too Many Requests |
3083 |
|
A sink partition value does not match its expected bound |
429 Too Many Requests |
3084 |
|
Too many concurrent stored procedure executions |
429 Too Many Requests |
3085 |
|
Throttled by the RNTBD client channel |
429 Too Many Requests |
3086 |
|
Throttled by back pressure from the log flush queue depth |
429 Too Many Requests |
3087 |
|
Throttled by back pressure from the checkpoint queue depth |
429 Too Many Requests |
3088 |
|
Throttled because of a partition split |
429 Too Many Requests |
3089 |
|
The AE queue is full |
429 Too Many Requests |
3090 |
|
A quota is exceeded |
429 Too Many Requests |
3091 |
|
The container quota is exceeded |
429 Too Many Requests |
3092 |
|
A system resource is unavailable |
429 Too Many Requests |
3093 |
|
The partitioned resource quota is exceeded |
429 Too Many Requests |
3094 |
|
Throttled because of resource exhaustion |
429 Too Many Requests |
3095 |
|
Throttled because the staging index queue is full |
429 Too Many Requests |
3096 |
|
Throttled by replication back pressure |
429 Too Many Requests |
3097 |
|
The container quota of an autoscale (autopilot) container is exceeded |
429 Too Many Requests |
3098 |
|
The log store has no free segments |
429 Too Many Requests |
3099 |
|
Throttled by a blob read |
429 Too Many Requests |
3100 |
|
The operation log is too big |
429 Too Many Requests |
3101 |
|
The archival partition has not caught up yet |
429 Too Many Requests |
3102 |
|
Throttled by traffic regulation |
429 Too Many Requests |
3103 |
|
Throttled because of transport buffer usage |
429 Too Many Requests |
3200 |
|
The request units per second budget is exceeded |
429 Too Many Requests |
3201 |
|
The gateway throttled the request |
429 Too Many Requests |
3202 |
|
The request units per minute limit of the partition is exceeded |
429 Too Many Requests |
3203 |
|
The shared request units per minute budget is exceeded |
429 Too Many Requests |
3204 |
|
Throttled because the throughput offer is scaling down |
429 Too Many Requests |
3207 |
|
The prepare time limit is exceeded |
429 Too Many Requests |
3208 |
|
The client TCP channel is full |
429 Too Many Requests |
3209 |
|
The Bw-tree term count limit is exceeded |
429 Too Many Requests |
3210 |
|
The request units per second budget of the master partition is exceeded |
429 Too Many Requests |
3211 |
|
Throttled because the log of a revoked encrypted store is not empty |
429 Too Many Requests |
3212 |
|
The throughput bucket exceeded its configured maximum throughput |
429 Too Many Requests |
3213 |
|
The throughput bucket configuration was changed more than once in 10 minutes |
429 Too Many Requests |
3214 |
|
A hot partition key is throttled |
429 Too Many Requests |
3300 |
|
The Microsoft Fabric capacity unit budget is exceeded |
429 Too Many Requests (inferred) |
13010 |
|
The thin client proxy throttled the request |
449 Retry With |
5350 |
|
The Microsoft Entra ID group of role-based access control is unavailable |
449 Retry With |
5351 |
|
The Azure role-based access control access decision is unavailable |
449 Retry With |
5352 |
|
A distributed transaction coordinator race conflict occurred |
449 Retry With (inferred) |
5404 |
|
The response of a retriable write request expired in the primary cache |
500 Internal Server Error |
3001 |
|
The configuration name is not empty |
500 Internal Server Error |
3002 |
|
The configuration operation was cancelled |
500 Internal Server Error |
3003 |
|
The account configuration is invalid |
500 Internal Server Error |
3004 |
|
The federation does not exist or is locked |
500 Internal Server Error |
3010 |
|
A partition failover failed |
500 Internal Server Error |
3021 |
|
The operation manager dequeue pump stopped |
500 Internal Server Error |
3042 |
|
The operation was cancelled without a rollback |
500 Internal Server Error |
3043 |
|
A partition split timed out |
500 Internal Server Error |
5360 |
|
Role-based access control is disabled because of the Azure Resource Manager path |
500 Internal Server Error |
5411 |
|
The distributed transaction coordinator ledger failed |
500 Internal Server Error |
5412 |
|
The distributed transaction coordinator account configuration failed |
500 Internal Server Error |
5413 |
|
The distributed transaction coordinator dispatch failed |
500 Internal Server Error |
5415 |
|
The distributed transaction coordinator rolled the operation back |
500 Internal Server Error (inferred) |
13011 |
|
Generated by the thin client proxy |
503 Service Unavailable |
1007 |
|
There are not enough bindable partitions |
503 Service Unavailable |
1012 |
|
The compute federation is not found |
503 Service Unavailable |
1337 |
|
A gone exception was not resolved by retries |
503 Service Unavailable |
1338 |
|
The quorum is not met |
503 Service Unavailable |
1339 |
|
There are too many tentative writes to a satellite region |
503 Service Unavailable |
6001 |
|
The aggregated health state is an error |
503 Service Unavailable (inferred) |
6002 |
|
The application health state is an error |
503 Service Unavailable (inferred) |
6003 |
|
The health state is an error |
503 Service Unavailable (inferred) |
6004 |
|
An unhealthy event was found |
503 Service Unavailable (inferred) |
6005 |
|
The cluster health is empty |
503 Service Unavailable (inferred) |
6006 |
|
An allocation failed |
503 Service Unavailable (inferred) |
6007 |
|
The operation result is null |
503 Service Unavailable (inferred) |
6008 |
|
The operation result is unexpected |
503 Service Unavailable (inferred) |
6009 |
|
The health of the fabric nodes is an error |
503 Service Unavailable |
9001 |
|
The operation is paused |
503 Service Unavailable |
9002 |
|
The service is offline |
503 Service Unavailable |
9003 |
|
The capacity is insufficient |
503 Service Unavailable (inferred) |
13012 |
|
Generated by the thin client proxy |
503 Service Unavailable |
20001 |
|
The client failed to connect and all retries failed |
503 Service Unavailable |
20002 |
|
The client timed out and all retries failed |
503 Service Unavailable |
20003 |
|
An operating system I/O error occurred on the client |
503 Service Unavailable |
20004 |
|
The client machine's CPU is overloaded |
503 Service Unavailable |
20005 |
|
The client machine's thread pool is starved |
503 Service Unavailable |
20006 |
|
The connection was interrupted or terminated unexpectedly |
503 Service Unavailable (inferred) |
20913 |
|
Generated by the .NET SDK: the write region barrier changed in the middle of the operation |
503 Service Unavailable |
21001 and greater |
|
This and every greater sub-status is a transient service condition |
503 Service Unavailable |
21001 |
|
The name cache stayed stale after the SDK retry limit |
503 Service Unavailable |
21002 |
|
The partition key range stayed gone after the SDK retry limit |
503 Service Unavailable |
21003 |
|
A partition split was still completing after the SDK retry limit |
503 Service Unavailable |
21004 |
|
A partition migration was still completing after the SDK retry limit |
503 Service Unavailable |
21005 |
|
A 410 Gone from the service that SDK retries did not resolve |
503 Service Unavailable |
21006 |
|
The global strong write barrier is not met |
503 Service Unavailable |
21007 |
|
The read quorum is not met |
503 Service Unavailable |
21008 |
|
A 503 Service Unavailable from the service |
503 Service Unavailable |
21009 |
|
No valid store response was received |
503 Service Unavailable |
21011 |
|
The barrier request was throttled |
503 Service Unavailable |
21012 |
|
The n-region commit write barrier is not met |
503 Service Unavailable |
21013 |
|
The write barrier request was throttled |
503 Service Unavailable |
21015 |
|
The routing map snapshot is inconsistent |
404 / 400 |
10004 |
|
Generated by the client SDK, not the service, when the container has no throughput offer: the Python SDK pairs it with 404, the Java SDK with 400 |
The service can return sub-status codes that are not in this list, so always keep a fallback case.
The emulators do not reproduce every sub-status of the service. For example, a point read with a prefix of a
hierarchical partition key is rejected with 400 Bad Request and sub-status 1001 (PartitionKeyMismatch) by the
Windows emulator, but with sub-status 0 by the Linux vNext emulator. Code that has to behave the same against
both should not depend on a sub-status where the status code alone is enough, and tests that assert on a
sub-status should run against the backend they are meant to cover.