pedestal

jdkealy 2020-06-03T03:05:07.173800Z

I find that when I am attempting to reload a handler with pedestal I also need to re-evaluate the service that calls the handler for the changes to take effect. Are there any tips to bypass having to reload the service that calls the handler ?

isak 2020-06-03T03:11:05.175100Z

@jdkealy for development mode, change your routes to (fn [] (expand-routes (deref #'my-routes)) in the service-map (instead of the default, something like: (expand-routes my-routes) )

2
hindol 2020-06-03T05:11:36.175400Z

What configuration did you try?

lxsameer 2020-06-03T10:25:53.175800Z

hey folks: here is my routes and the logs http://paste.debian.net/1149907/

lxsameer 2020-06-03T10:26:12.176300Z

any post request to /q returns 404

lxsameer 2020-06-03T10:26:29.176600Z

am I doing it wrong ?

husayn 2020-06-03T23:10:17.180300Z

hello. I am using pedestal and seeing some weird behaviour, when I catch an exception the interceptor chain restarts instead of returning my response

(catch java.util.concurrent.ExecutionException e
                    (log/info :msg "return error")
                    (assoc context :response
                           {:status 408
                            :body {:status "error"
                                   :message (format "Operation Timed out %d seconds" wait-time)}}))
and the logs look like
00:58:50.511 [qtp463993419-109] INFO  payment-gateway.routes.collection - {:msg "valid public key ?", :line 20}
00:58:50.525 [qtp463993419-109] INFO  payment-gateway.routes.collection - {:msg "valid referency id ?", :line 40}
00:58:50.621 [qtp463993419-109] INFO  payment-gateway.routes.collection - {:msg "create payment", :line 119}
00:58:52.667 [qtp463993419-109] INFO  payment-gateway.routes.collection - {:status :accepted, :line 122}
00:58:52.667 [qtp463993419-109] INFO  payment-gateway.routes.collection - {:msg "process request", :line 125}
00:59:30.555 [qtp463993419-109] INFO  payment-gateway.routes.collection - {:msg "return error", :line 136}
00:59:30.565 [qtp463993419-110] INFO  payment-gateway.routes.collection - {:msg "valid public key ?", :line 20}
00:59:30.566 [qtp463993419-110] INFO  payment-gateway.routes.collection - {:msg "valid referency id ?", :line 40}
As you can see the request starts on thread qtp463993419-109 but when I return, it. instead restarts on a new thread qtp463993419-110 Has anyone experienced this before or what could be going on ?

2020-06-03T23:12:21.180400Z

Is this code in a public repo somewhere? I'd like to repro.