1

I would like to know if there are something like this in python?

If so, could you provided any web with examples?

EXTRA:

If you are trying to run it like a normal python program it will give you an error:

Run it using:

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

1 Answer 1

5

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()
Sign up to request clarification or add additional context in comments.

3 Comments

Believe me when I ask something I try to look for it before.The web you posted is the same I saw before and that is not what I asking/looking for. In the title of the post I talk about Integrating Apache Spark with Azure Event Hubs. I saw that with scala but not with python.So I would like to know about any python connector to work like this org.apache.spark.eventhubs
I've updated accordingly. Apologies I thought the original mentioned event hub as well.
Thanks @HaukeMallow

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.