我有 3 条骆驼路线解析 3 个不同的 ~ 分隔文件。我正在使用 Camel bindy 将文件解析为 Java 对象。我有类似下面的东西
<route>
<from uri ="endpoint1" />
<unmarshal>
<bindy type="Csv" classType="package1.File1Data" />
</unmarshal>
<to uri="bean:process?method=processFile1Data" />
</route>
<route>
<from uri ="endpoint2" />
<unmarshal>
<bindy type="Csv" classType="package2.File2Data" />
</unmarshal>
<to uri="bean:process?method=processFile2Data" />
</route>
<route>
<from uri ="endpoint3" />
<unmarshal>
<bindy type="Csv" classType="package3.File3Data" />
</unmarshal>
<to uri="bean:process?method=processFile3Data" />
</route>
如果我打开了所有 3 条路由,我会收到解析错误,但是如果我在任何给定时间保留一条路由(一个绑定),它工作正常。
我在某处读到了骆驼绑定不支持的地方,还有其他人遇到过与绑定相同的问题吗?
这是我的依赖:
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-bindy-starter</artifactId>
<version>2.18.0</version>
</dependency>