pedestal

yiorgos 2020-03-25T12:37:51.002400Z

@ddeaguiar that worked great, just for the reference just in case someone else faces the same problem. here are the changes

(def logger
  (interceptor/on-request
   ::log-request
   (fn [request]
     (log/info :msg request)
     request)))

(def service-map
  {::http/type :jetty
   ::http/resource-path "/public"
   ::http/port 3001
   ::http/routes r/routes
   ::http/request-logger logger}) ;; <----- update the default logger with a custom one

2020-03-25T12:38:58.003400Z

Great! At some point I’ll update the Default Interceptors docs to make overriding clearer

👍 2
yiorgos 2020-03-25T12:43:31.004900Z

I have a plain html form and I am rendering it with Semler the body of the request looks like this :body #object[org.eclipse.jetty.server.HttpInputOverHTTP 0x3747fe8b "HttpInputOverHTTP@3747fe8b[c=0,q=0,[0]=null,s=STREAM]"] how can I parse that? the content type is “application/x-www-form-urlencoded

2020-03-25T12:53:41.005Z

@g3o take a look at the body params interceptor

👍 1