我需要使用AWS访问/密钥从我的Spark应用程序(结构化流)连接到AWS Elasticsearch服务。例如,S3和Spark集成有一种在configuration https://docs.databricks.com/spark/latest/data-sources/aws/amazon-s3.html中设置访问/密钥的方法
我找不到任何与Elasticsearch相同的东西。我尝试了下面的代码,但它不起作用。
val writer = input.write
.option("es.nodes",serverUrl)
.option("es.net.https.auth.user", awsAccessKeyId)
.option("es.net.https.auth.pass", awsSecretAccessKey)
.option("es.nodes.wan.only", "true")
.format("org.elasticsearch.spark.sql")
writer.save("index/mapping")
看起来"es.net.https.auth.xxx“是用于基本身份验证的。我正在寻找AWS特定的一个。如有任何信息,欢迎光临!
https://stackoverflow.com/questions/56761624
复制相似问题