add message.clj for converting database format -> network protocol format