Hi, is there a way to add additional behaviour to ...
# http4k
l
Hi, is there a way to add additional behaviour to
server.start()
? so that a connection to a message broker can be established on start, other than implementing the
Http4kServer
interface myself
It’s not that the connection to the message broker depends on the server but it’d be good to synchronise the start of the 2. Now thinking about it, maybe I can have another abstraction on top of the 2 that calls start on the server and on the broker connection
s
That’s similar to the approach we have taken on projects: we have a “server” abstraction where one (or more) service(s) (http or otherwise) can be setup and started/stopped in a consistent way
l
Thanks for the prompt reply! Sometimes you need to talk about things to realise what the solution is 😁
s
You’re welcome! simple smile
l
Thanks @dave I’ll keep this option in mind