简体   繁体   English

我可以将 Mule Cloudhub 中的文件连接器用于 FTPS

[英]Can I use the File connector in Mule Cloudhub for FTPS

Is there a way to configure a File connector for use in cloudhub, specifically related to reading in a file over FTPS and putting it into a file before beginning the actual processing of the contents?有没有办法配置文件连接器以在 cloudhub 中使用,特别是与通过 FTPS 读入文件并将其放入文件之前开始实际处理内容有关?

Clarification : I'm in cloudhub, which does not provide a filesystem in the same sense that a local/on-prem Mule setup has.澄清:我在 cloudhub,它不提供与本地/本地 Mule 设置具有相同意义的文件系统。 One standard practice when dealing with streams (FTPS or similar) in order to avoid processing over the open stream is to take the incoming stream and use the File connector (outbound in this case) to put the inbound stream into a file, and then use that file for your flow process.处理流(FTPS 或类似)以避免处理打开的流时的一种标准做法是获取传入流并使用文件连接器(在本例中为出站)将入站流放入文件中,然后使用该文件用于您的流程。 How is this managed in CloudHub?这是如何在 CloudHub 中管理的?

File Connector is to read files from paths specified on the server.文件连接器是从服务器上指定的路径读取文件。 They cannot be used to read from remote servers.它们不能用于从远程服务器读取。

I case you want to have a File to start your flow with try the following.如果您想要一个文件来开始您的流程,请尝试以下操作。

<flow name="ftp_reader_flow">
    <ftp: inbound>   Read from the remote directory
    ...
    <file:outbound>  to a local directory
</flow>

<flow name="actual_processing_flow">
    <file:inbound>  read from the local directory.
    ... Continue with the processing
    .....
</flow>

Hope this helps.希望这可以帮助。

You can use the connector for temporary data with the tmp directory.您可以将连接器用于 tmp 目录的临时数据。

From the MuleSoft Documentation :来自MuleSoft 文档

Disk Persistence磁盘持久性

CloudHub does not guarantee that writing to disk survives hardware failures. CloudHub 不保证写入磁盘不会发生硬件故障。 Instead, you must use an external storage mechanism to store information.相反,您必须使用外部存储机制来存储信息。 For small amounts of data, you can use the Object Store.对于少量数据,您可以使用对象存储。 For applications that have large data storage requirements, we recommend use of a cloud service such as Amazon S3.对于具有大数据存储要求的应用程序,我们建议使用 Amazon S3 等云服务。 For temporary storage, the File connector is still available and can be used with the /tmp directory.对于临时存储,文件连接器仍然可用并且可以与 /tmp 目录一起使用。

您也可以在 CloudHub 中使用文件连接器,但请确保您仅从类路径-src/main/resource或项目类路径中的任何文件夹读取或写入文件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM