I'm still new at dev with CosmosDB, Quarkus, and Vertx and am seeking some clarification - originally I ran into errors with the Quarkus native build as specified in this GitHub issue and according to the reply, I assumed it referred to the CosmosAsyncClient that we use as the culprit of issues when trying to build the native image. Per the reply, I found this project and used mvn clean install to build locally (couldn't be found in the remote repository?) and added the following dependency for what I think is the extension that was being referred to in my project's pom:
<dependency>
<groupId>io.quarkiverse.azureservices</groupId>
<artifactId>quarkus-azure-http-client-vertx</artifactId>
<version>999-SNAPSHOT</version>
</dependency>
But I am currently unsure of how to go from here in order to use the HTTP/Web client to communicate with CosmosDB (e.g. CosmosAsyncClientBuilder uses endpoint() and key() - are there equivalents/how can I use this in the HTTPClient context?) and the specific containers I need to query.
So far I've created a Vertx from the Quar开发者_运维知识库kusVertxProvider and then a WebClient from that Vertx but I'm currently stuck with how I would go about sending queries to the database and the specific containers I want to use in CosmosDB without relying on classes from com.azure.cosmos, as later I want to be able to run the native build. Has anyone had success in using Web/HTTPClient instead of CosmosAsyncClient, or is this not possible?
If there are different suggestions for any Quarkus extensions I may have missed that is better suited for what I'm trying to do, please let me know. I have briefly worked with the reactive postgreSQL and mongoDB and the tutorials were easy to understand and showed how we could specify the database connection e.g. in our properties file, but I don't know what is the equivalent for this with Cosmos.
精彩评论