I have a Spring Boot application which sends some message to Kafka. We use Apicurio registry provided by our customer to manage AVRO schema for message serialization. The application uses Apicurio registry client, namely the Maven artifact io.apicurio:apicurio-registry-utils-converter:1.3.2.Final
and its dependency apicurio-registry-utils-serde
. The client communicates with registry using REST API.
Recently the Apicurio was migrated to higher version and there are some issues with REST communication. (They are beyond scope of this question - in a nutshell, we play with changing global id strategy to avoid some unwanted REST calls, more info in comment under this question.)
The Apicurio migration seems somewhat turbulent and I observe now that any REST call can fail with various reason (missing configuration, missing artifacts, availability...). Actually the only thing in log is javax.ws.rs.WebApplicationException
without further cause description. To understand what's happening there, I need to enable logging of all REST API calls from Apicurio client.
The Apicurio client internally uses OkHttpClient
. I am aware the OkHttpClient
is configured using builder pattern and the standard way is to add HttpLoggingInterceptor. However, the process of creation of OkHttpClient
seems to be too strictly closed in internals of Apicurio client (private static OkHttpClient createHttpClientWithConfig
in RegistryRestClientImpl
). Hence the Apicurio client itself does not let user to set up custom configuration of underlying OkHttpClient
.
Is there some way to do it in a simple way or am I missing something?
(Note some of these application.properties
settings which were recommended to us are helpful too but they does not relate to core topic of question:
logging.level.okhttp3=TRACE
logging.level.org.apache.http=TRACE
logging.level.io.apicurio=TRACE
logging.level.org.springframework.kafka=TRACE
logging.level.org.apache.kafka=TRACE
)