We're using com.microsoft.azure:azure-cosmosdb-spring-boot-starter:2.3.3, and when running a query that uses aggregations such as this one:
SELECT c.Type, COUNT(c) as num_losses
FROM c
GROUP BY c.Type
we get an exception that the client does not support this:
com.azure.data.cosmos.CosmosClientException: Gateway Failed to Retrieve Query Plan: Query contains 1 or more unsupported features. Upgrade your SDK to a version that does support the requested features:
Query contained NonValueAggregate, which the calling client does not support.
Query contained GroupBy, which the calling client does not support.
There does not seem to be a newer version released, and I don't see an obvious workaround. I don't understand why the client needs to support anything, as it is mainly acting as a json marshaller.
Can you please give an ETA as to when such a basic feature as aggregations will be supported, or suggest a workaround?
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @kushagraThapar, @anfeldma-ms
@saragluna @chenrujun - please point the latest spring boot cosmos db starter, as this issue is already fixed in latest version of v4 Java SDK.
Thanks for getting back at me. It doesn't seem to be released? Latest version I see on Maven Central is 2.3.5 https://search.maven.org/artifact/com.microsoft.azure/azure-cosmosdb-spring-boot-starter
@MrBuddyCasino - I think they might have a beta version out for you to try out. They will provide the details shortly!
Thanks, testing it now.
Are you starting to release new versions to repo.maven.apache.org first instead of Maven Central, starting with v3? Because only the 3.0.0-beta.1 release seems to reside there, none of the 2.x releases.
none of the 2.x releases.
We changed the artifact name. In version 2.x, it's name is azure-cosmosdb-spring-boot-starter.
https://repo.maven.apache.org/maven2/com/microsoft/azure/azure-cosmosdb-spring-boot-starter/
azure-cosmosdb-spring-boot-starter:2.3.5azure-spring-boot-starter-cosmos:3.0.0-beta.1@chenrujun - please close this issue if the conversation has been resolved.