Python 中的 Azure 事件中心与 Apache Spark 的集成

Azure Event Hubs integration with Apache Spark in Python

我想知道python里面有没有这个like?

如果是这样,您能否提供任何带有示例的网站?

额外:

如果你想运行它像一个普通的python程序一样,它会给你一个错误:

运行 它使用:

spark-submit --packages com.microsoft.azure:azure-eventhubs-spark_2.11:2.3.9 nameoffile.py

https://docs.databricks.com/_static/notebooks/structured-streaming-python.html

https://github.com/Azure/azure-event-hubs-spark/blob/master/docs/PySpark/structured-streaming-pyspark.md

# Source with default settings
connectionString = "YOUR.CONNECTION.STRING"
ehConf = {
  'eventhubs.connectionString' : connectionString
}

df = spark \
  .readStream \
  .format("eventhubs") \
  .options(**ehConf) \
  .load()