            (catch Throwable e
              (timbre/fatal e))))))
 
-(defn established? [channel]
+(defn established? [^Channel channel]
   (and channel (.isActive channel)))
 
 (defn create-client [client-group host port]


(defn add-failed-check 
  "Check if the message failed to send"
  [f connection buf]
  (.addListener f (reify GenericFutureListener
                    (operationComplete [_ _]
                      (when-not (.isSuccess f)

  [^ChannelGroup channel-group handler]
  (proxy [ChannelInboundHandlerAdapter] []
    (channelActive [ctx]
      (.add channel-group (.channel ^ChannelHandlerContext ctx)))
    (channelRead [^ChannelHandlerContext ctx ^Object message]
      (try
        (handler ctx message)
