就我的情况而言,Hadoop 会给我带来更多好处吗?
我使用 Clojure 每小时提取 10 个 XML 文件,每个文件大约 10 MB。该脚本正在服务器计算机上运行。
XML 文件现在被解析并存储到 RDBMS 中(所有操作都是使用本机 Clojure 代码完成的)。
考虑到我的情况,如果我使用 Hadoop Map/Reduce 来解析 XML 文件,我是否会获得更多好处?或者它会矫枉过正?
I'm using Clojure to pull ten XML files hourly, each file is about 10 MB. This script is running on a server machine.
XML files are parsed and stored into RDBMS right now (all is done using native Clojure code).
Considering my case, Am I going to gain more benefits if I used Hadoop Map/Reduce to parse the XML files? or it will be overkill?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
![扫码二维码加入Web技术交流群](/public/img/jiaqun_03.jpg)
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在这种情况下,使用 Hadoop 肯定是大材小用。如果你要使用 Hadoop 并行解析 10 个文件,
如果您的文件每个最大为10 Mb,那么我看不到太多优势,事实上您会看到JVM 启动和过多 IO 会产生大量开销。
我想说,一旦每个文件超过 100 - 150 Mb,您就应该考虑 Hadoop
Using Hadoop would definitely be an overkill in this case. If you were to use Hadoop to parse 10 files, parallely,
If your files are each a max of 10 Mb, then I dont see much advantage and you will infact incur significant overhead from the JVM starts and excessive IO.
Id say you should consider Hadoop once you cross 100 - 150 Mb per file
我有两个 clojure 示例可供您进行比较:
当然,这取决于服务器的处理能力,但一切都是在 Clojure 中完成的,没有任何瓶颈的迹象。
I have two clojure examples that you could use for comparison:
Of course, this depends on the server processing power, but everything is done in clojure, without any hint of a bottleneck.