有人能帮我一个视频教程或简单的步骤,如何上传ElasticSearchxml文件?提前谢谢!
o2rvlv0m1#
您需要从logstash示例读取xml文件,以使用以下logstash配置将其存储到elasticsearch示例。
input { file { path => "/path/to/your/xml/*.xml" start_position => beginning sincedb_path => "/dev/null" } } filter { xml { source => "message" target => "doc" store_xml => false xpath => [ "/msg/@time", "time", "/msg/@time_norm", "time_norm" ] } } output { elasticsearch { hosts => ["localhost:9200"] } stdout { codec => rubydebug } }
14ifxucb2#
fscrawler还支持读取xml文件。看到了吗https://fscrawler.readthedocs.io/en/latest/admin/fs/local-fs.html#indexing-xml文档免责声明:我是fscrawler的作者
2条答案
按热度按时间o2rvlv0m1#
您需要从logstash示例读取xml文件,以使用以下logstash配置将其存储到elasticsearch示例。
14ifxucb2#
fscrawler还支持读取xml文件。看到了吗https://fscrawler.readthedocs.io/en/latest/admin/fs/local-fs.html#indexing-xml文档
免责声明:我是fscrawler的作者