How to save spark scala dataframe to elastic search


(sheryl) #1

i am using this df to save into elasticsearch but it showing error
--- ERROR NetworkClient: Node [192.168.0.1:9200] failed (Connection timed out: connect); no other nodes left - aborting... --

df.write.format("org.elasticsearch.spark.sql").option("es.nodes.wan.only","true")
.option("es.port","9200")
.option("es.net.ssl","true")
.option("es.nodes","192.168.0.1")
.mode("append")
.option("es.nodes.client.only", "false")
.save("C:\elasticsearch-6.3.1")

i m running this on windows but not working .


(James Baiera) #2

Please avoid double posting on here as it creates clutter and makes it harder for people to respond or find answers. I will respond on your other topic.


(James Baiera) #3