ObjectMapperFactory.java
|
@ApplicationScoped
|
@Produces // -> must be javax.enterprise.inject.Produces NOT javax.ws.rs.Produces
|
public ObjectMapper getObjectMapper() {
|
return mapper;
|
}
|
The same applies to name.abhijitsarkar.javaee.microservices.client.ResteasyClientFactory.newClient(). Moreover, ObjectMapper is not proxyable because it contains final methods - so you can't use a normal scope for the producer method.
|