Urgent.News

What's breaking now, across thousands of outlets.

Tech

Why are you still debugging Spark on your host machine?

Last October, a "minor" dependency bump in a PySpark job cost us four hours of downtime and roughly $12,000 in cloud compute credits. A developer had tested a new UDF locally using an older version of delta-spark than what we ran on our EMR cluster. Locally, the serialization worked fine. In production, the different Scala/Java versions in the underlying runtime caused a…

Spark debugging has become a headache for a team after a minor dependency update caused four hours of downtime and $12,000 in cloud costs. Developers were able to test new UDFs locally, but the different Scala/Java versions in production led to java.io.NotSerializableExceptions. The developer realized that having a local environment not matching the cluster caused issues and decided to either stay in a problematic situation or containerize their local development.

The two options are installing Java, Python, Spark, and Delta Spark on your machine or creating a Docker container that mirrors the production environment. The second option, although requiring initial effort, provides a consistent environment, easier debugging, and faster local development. The author recommends the containerized approach, especially for those working on critical data, as it ensures the code runs consistently across different environments, saving time and money.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

Grid workspace for the COSMIC compositor

How I patched the COSMIC compositor: a 5×5 workspace grid for Pop!_OS Context My workspaces are a map, not a scroll. One 4-finger swipe moves me north, south, east, or west across a 5×5 grid that…

Simulating 30 Million microbes in Browser

Simulating 30 Million Microbes in the Browser WebGPU gives the browser direct access to modern GPU capabilities — not just for rendering, but also for general-purpose computation through compute…

More from Monday 14 September →