Questions tagged [microprofile]

The Eclipse MicroProfile project defines a programming model for developing microservice applications in an Enterprise Java environment.

The Eclipse MicroProfile project is a CDI-first approach to building microservice applications and supported by both community and Java application server vendors. There are a number of active projects within MicroProfile, which can be viewed at the official website.

296 questions
11
votes
1 answer

Generate OpenAPI descriptions from JavaDoc

I have an application which provides an API with JAX-RS (Java API for RESTful Web Services / JSR-311). For documentation purposes I provide an URL according to the OpenAPI-Specification, which is generated by Eclipse MicroProfile OpenAPI. Everything…
Tobias Liefke
  • 8,637
  • 2
  • 41
  • 58
10
votes
3 answers

Prometheus-Grafana : How to use wildcard in query

I have below labels in prometheus, how to create wildcard query while templating something like “query”: “label_values(application_*Count_Total,xyx)” . These values are generated from a Eclipse Microprofile…
funtoos
  • 295
  • 1
  • 4
  • 17
9
votes
1 answer

OpenAPI and @Schema annotation on Java Enum

I’m generating OpenAPI 3.0 documentation from annotated java code. But the issue is that when I add @Schema annotation to enum all the values disappear. I'm using Thorntail 2.3.0.Final with microprofile-openapi fraction. I know I can just change the…
Kiki
  • 2,243
  • 5
  • 30
  • 43
8
votes
2 answers

How to have dynamic base URL with Quarkus MicroProfile Rest Client?

Quarkus using Rest Client, explains how to use the MicroProfile REST Client. For Base URL application.properties can be used. org.acme.restclient.CountriesService/mp-rest/url=https://restcountries.eu/rest # With above approach, cant have dynamic…
Tushar
  • 263
  • 3
  • 11
7
votes
2 answers

Quarkus ExceptionMapper does not handle WebApplicationException

I'm trying to understand if this is a feature or a bug... :-) For the below controller and exception mapper, for a rest client that will fail with a 401 response, I would expect the exception handler to be invoked for both cases. However it's not…
bmooney
  • 391
  • 6
  • 15
6
votes
2 answers

Quarkus & Microprofile : Is there a better way to use a property from application.properties into @ClientHeaderParam?

I'm trying to build a simple app that calls an API with quarkus-rest-client. I have to inject an API Key as a header which is the same for all resources of the API. So I would like to put the value of this API Key (that depends on the environment…
Tatute
  • 61
  • 1
  • 6
5
votes
2 answers

How to convert camel case to lower case with underscores in a REST API?

I am using Quarkus and Microprofile OpenAPI to map entities in REST APIs. I can convert my camel case named properties to lower case with underscores in the following way: @Schema(name = "first_name") private String firstName; However it is…
Sasha Shpota
  • 9,436
  • 14
  • 75
  • 148
5
votes
1 answer

How to set the OpenAPI type/schema for a property in a Kotlin data class

In a Microprofile / Quarkus project using Kotlin have a data class with a variable of type Instant. @Schema(name = "Vehicle", description = "POJO that represents a vehicle at a specific time.") data class VehicleDTO( var time: Instant =…
Flickster
  • 120
  • 2
  • 9
5
votes
3 answers

Can you configure the port on wildfly for microprofile-health endpoint?

The standard behaviour for wildfly-17 (and 18) with microprofile-health-smallrye is, that the /health endpoints are published under the management port. Is there a way to configure it to use a different port? That behaviour is difficult in some…
5
votes
2 answers

How to copy external dependency to Open Liberty during maven build

UPDATE - July 2021: While the accepted answer using the dependency plugin was the best solution at the time, the answer from @ltlBeBoy leverages the 'copyDependencies' support since added to liberty-maven-plugin. Using 'copyDependencies' is usually…
Anton Balaniuc
  • 10,889
  • 1
  • 35
  • 53
5
votes
1 answer

How do I debug a Quarkus/SmallRye client request

I have a request that looks like this: @Path("/v1") @RegisterRestClient @Produces("application/json") public interface VaultClient { @POST @Path("/auth/jwt/login") @Consumes("application/json") String getVaultToken(LoginPayload…
Jim Wharton
  • 1,375
  • 3
  • 18
  • 41
5
votes
1 answer

How to replace jackson for moxy on payara 5

I read a lot about how to replace jackson for moxy on payara 5 but never achieve a good solution, so I create a small project and hope that someone can help me. pom.xml javax
tiagomistral
  • 143
  • 8
4
votes
3 answers

Quarkus Microprofile Rest Client ResponseExceptionMapper doesn't catch errors

I have a Rest Client in a Quarkus (1.8.1) service defined like this: @RegisterRestClient @Path("/") @Produces("application/json") @Consumes("application/json") public interface MyClient { @POST @Path("/{entity}") Response…
Sean
  • 1,416
  • 19
  • 51
4
votes
0 answers

How to make a long polling with Quarkus

I want to implement an API rest endpoint with the long polling pattern. The problem with a while loop is, It block the thread so each Http connection take one thread. For exemple if I have 40 threads available I can only make 40 concurrent Http…
Dorian Maliszewski
  • 821
  • 1
  • 10
  • 14
4
votes
1 answer

How to configure ObjectMapper for Quarkus REST Client

I know that you can implement ObjectMapperCustomizer to configure the mapper for your Quarkus REST service. However, it's not clear in the documentation for Quarkus REST Client, whether it will use that same (global?) mapper or not. And how do you…
1
2 3
19 20