- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
โ08-11-2024 08:20 PM
I am currently managing nearly 300 tables from a production database and considering moving the entire ETL process away from Azure Data Factory to Databricks.
This process, which involves extraction, transformation, testing, and loading, is executed daily.
Given this context, I am unsure whether it's more efficient to:
- Create 300 individual notebooks or Python scriptsโone for each tableโproviding great isolation and easier debugging if something breaks.
- Implement a single script with a loop that processes all tables, potentially simplifying management but increasing complexity in debugging.
My questions are:
- Which approach would you recommend in this situation?
- Are there any better alternatives that I might be overlooking?
- Is there a real benefit over .py scripts vs notebooks? I'm considering sticking to notebooks as I find it easier to debug (can run things cell by cell) for any newbies we might be onboarding in the future.
- Is it optimal to create very long loops in Spark/Databricks?
Additional context:
- Data is around 50GB.
- We're using a Standard spark instance on Azure.
- We're writing onto ADLS Gen2
Thank you for your insights!
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
โ08-11-2024 09:38 PM
Hi,
Instead of 300 individual files or one massive script, try grouping similar tables together. For example, you could have 10 scripts, each handling 30 tables. This way, you get the best of both approchesโThis way you will have a freedom of easy debugging without having too many files to manage.
Start with Notebooks and once everythingโs running smoothly, consider converting your notebooks into .py scripts.
One more tip - look into using Delta Lake in Databricks. It makes managing your data easier and more reliable.
Give a try.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
โ08-11-2024 09:38 PM
Hi,
Instead of 300 individual files or one massive script, try grouping similar tables together. For example, you could have 10 scripts, each handling 30 tables. This way, you get the best of both approchesโThis way you will have a freedom of easy debugging without having too many files to manage.
Start with Notebooks and once everythingโs running smoothly, consider converting your notebooks into .py scripts.
One more tip - look into using Delta Lake in Databricks. It makes managing your data easier and more reliable.
Give a try.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
โ08-13-2024 04:26 PM
Thank you Brahmareddy!
Not too sure why I never thought of that ๐!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
โ08-13-2024 05:15 PM
You are welcome, Joeyong!. Good day.

