Updated code to send periodically send file contents to MQ.