我想要实现的是通过java应用程序从队列中读取csv文件。 我想知道队列中的数据是存储为字节还是csv文件直接上传。
What I am trying to achieve is to read a csv file from the queue through a java application. I would like to know if the data in queue is stored as a byte or the csv file is uploded directly.
最满意答案
MQ不关心你在邮件正文中放置了什么。 它可以是简单的文本,字节流,一些结构化数据等。所以这完全取决于应用程序如何处理消息体。 消息体将是字节流,但MQ可以将字节转换为文本格式。
它自己的MQ不发送/接收文件。 您的应用程序必须将文件中的数据读入缓冲区,将缓冲区设置为消息正文并发送消息。 在接收方,您的应用程序必须接收消息,检索消息正文并将其写入文件。
您还可以查看MQ Managed File Transfer产品。
MQ does not care what you put in the message body. It can be simple text, stream of bytes, some structured data etc. So it's all up to the application how it wants handle the message body. The message body will be stream of bytes but MQ can convert the bytes to text format.
MQ on it's own does not send/receive files. Your application has to read data from the file into a buffer, set the buffer as message body and send the message. On the receiver side, your application has to receive message, retrieve the message body and write it to a file.
You can also look at MQ Managed File Transfer product.
更多推荐
发布评论