Added message ID and PID to logs when sending messages