0

我正在尝试从文件系统读取 cfg 文件,但找不到任何示例。是否可以创建这样的路由:Reading the config file from application.properties(这是一个弹簧启动应用程序)

from("quickfix:{{XX.config.file}}").routeId("XXFixRoute")

应用程序属性:

XX.config.file=/home/user/fixApp/XXconfig.cfg

提前致谢。

4

1 回答 1

0

不,它只能从类路径加载。加载配置文件的代码在这里:https://github.com/apache/camel/blob/master/components/camel-quickfix/src/main/java/org/apache/camel/component/quickfixj/QuickfixjEngine。爪哇#L253

但它可能是一个很好的增强,允许从文件或类路径加载资源,就像其他一些 Camel 组件可以做的那样。欢迎您在 Apache Camel 问题跟踪器上记录 JIRA 票证:http: //camel.apache.org/support.html

于 2016-05-17T17:05:18.427 回答