使用 AtlasMap 将 xml 转换为 json

2022-01-19 00:00:00 xml json java apache-camel atlasmap

在探索 xml 到 json 的高效转换工具时,我发现了 AtlasMap!(https://atlasmap.io) 非常有用.AtlasMap 独立应用程序有助于制定源到目标的映射文件.它支持在 XML、JSON 和 Java 对象之间转换数据.最重要的是,我的项目严重依赖 Apache camel,它也支持骆驼组件.

While exploring the efficient conversion tool for xml to json, I find AtlasMap! (https://atlasmap.io) is a very useful. AtlasMap standalone application helps to formulate source to target mapping file. It supports transforming data to and from XML, JSON and Java objects. Most important thing, my project is heavily Apache camel depended and it supports camel component too.

虽然它对于小型有效负载工作正常,但对于大型有效负载,用于 xml 到 json 转换的性能非常差.我相信它正在使用 DOM 解析器进行 xml 处理,如果是这样,我该如何配置 STAX 或 Woodstox 解析器?或者,如果我想使用 AtlasMap,大型 xml 到 json 转换该怎么办?谢谢

Though it is working fine for small payload, it is giving very bad performance for large payload for xml to json conversion. I believe it is using DOM parser for xml processing, if so how can I configure STAX or Woodstox parser? Or what to do for large xml to json conversion if I want to use AtlasMap? Thanks

推荐答案

感谢您对 AtlasMap 的关注.不幸的是,我们还没有支持 XML/JSON 的流处理,但它肯定在桌面上.如果您可以在我们的 GitHub 存储库上提出问题并吸引其他人的投票,那么优先考虑它会有所帮助.

Thank you for your interest in AtlasMap. Unfortunately we haven't supported stream processing for XML/JSON yet, but it's definitely on the table. If you could file an issue on our GitHub repo and attracts other people's vote, it helps to be prioritized.

https://github.com/atlasmap/atlasmap

参见.https://github.com/atlasmap/atlasmap/issues/45

相关文章