Azure Cosmos DB
An Azure NoSQL database service for app development.
980 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Getting the below error
Microsoft.Azure.Cosmos.CosmosException: 'Response status code does not indicate success: NotFound (404); Substatus: 0; ActivityId: 9cb22e39-4d37-472e-b650-6033281e5585; Reason: (Response status code does not indicate success: NotFound (404); Substatus: 0; ActivityId: 9cb22e39-4d37-472e-b650-6033281e5585; Reason: (Response status code does not indicate success: NotFound (404); Substatus: 0; ActivityId: 9cb22e39-4d37-472e-b650-6033281e5585; Reason: (
Errors : [
"Resource Not Found. Learn more: https://aka.ms/cosmosdb-tsg-not-found"
]
);););'
On execution of the below code (at Line number 7)
public List<int> Run([ActivityTrigger] IDurableActivityContext inputs, ILogger log)
{
try
{
container = _repository.GetContainer();
var stores = container .Where(d =>
d.CreatedDate >= _yesterday.Date && d.CreatedDate < _today.Date
).ToList().DistinctBy(x => x.storeId).Select(s => s.storeId).ToList();
return stores;
}
catch (Exception ex)
{
log.LogError(ex, $"Error processing function.");
throw;
}
}
Hi @Shreekumar Suggamad Please provide the answer to the above questions so we can better assist.
Regards,
Oury
Hi @Shreekumar Suggamad
From the code, it's hard to know exactly where the error comes from, but the 404 is a known error code: https://learn.microsoft.com/en-us/azure/cosmos-db/sql/troubleshoot-not-found
It means either the Database, or the Container, or the Item (depending on the operation) doesn't exist.
Regards,
Oury
Hi @Shreekumar Suggamad
Could you please confirm the above so we can better assist here.
Regards,
Oury
Sign in to comment