igor.wojda
01/07/2021, 12:47 PMdevelopment = true
in the application.conf
file and I can see stack-traces in the console. Now I wonder is there any way to print into console all requests and responses (including returned data like JSON and http codes) ?Dragos Rachieru
01/07/2021, 1:07 PMigor.wojda
01/07/2021, 1:59 PMCallLogging
…
install(CallLogging) {
format { call -> call }
}
…
but getting the desired output is not straight forward:
1. I need a way to have query parameters nicely formatted - call.request.queryParameters
(ApplicationCall
class) displays params as io.ktor.server.netty.NettyApplicationRequest$queryParameters$1@143dccc7
string while within the routing { get {
DSL printing parameters call.parameters
(ApplicationCallPipeline
class) would produce nicely formatted string Parameters [phoneNumber=[123]]
2. I don’t see a way to retrieve values of POST parameters at all
3. I am not sure how to retrieve request and response body
I would appreciate some help on thisRequest
- path
- parameters
- body
Response
- body