[英]Spring Integration File Polling complex structure - subdirectories
I am currently using this project as an attempt to listen and poll files from a FS structure, start Spring Batch jobs from them and write'em back to a different folder. 我目前正在使用这个项目作为尝试来监听和轮询FS结构中的文件,从中启动Spring Batch作业并将它们写回到另一个文件夹。
Unfortunately, as I can guess, it can only define one single folder for each type of channel (read, out, fail and processed). 不幸的是,据我所知,它只能为每种类型的通道(读,出,失败和处理)定义一个文件夹。 I would like to define a parent folder for each channel and a few children folders to be automatically created and have a scanner on.
我想为每个通道定义一个父文件夹,并为几个要自动创建并打开扫描仪的子文件夹。
Eg: 例如:
entrada:
path: /opt/app/inbound/
informantes:
- Bradesco
- Itau
- Caixa
- Banco do Brasil
- Santander
Do you guys have any hint on if and how can this be achieved? 你们对是否以及如何实现有任何暗示吗?
I've seen this link here , but I couldn't figure it out how to adapt it to this solution. 我在这里看到了此链接,但是我无法弄清楚如何使它适应该解决方案。
Any help is highly appreciated! 任何帮助深表感谢!
Best regards, Enrico 最好的问候,恩里科
Did you see a RecursiveDirectoryScanner
there in Spring Integration? 您是否在Spring Integration中看到
RecursiveDirectoryScanner
?
* The {@link DefaultDirectoryScanner} extension which walks through the directory tree
* using {@link Files#walk(Path, int, FileVisitOption...)}.
* <p>
* By default this class visits all levels of the file tree without any {@link FileVisitOption}s.
What files to accept or not you can determine by particular filter
, eg RegexPatternFileListFilter
. 您可以通过特定的
filter
(例如RegexPatternFileListFilter
确定要接受什么文件。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.