Apache Hadoop is an open source software utility that allows users to manage big datasets (from gigabytes to petabytes) by enabling a network of computers(or “nodes”) to solve vast and intricate data problems. This is highly stable, cost effective, and stores and processes structured, semi-structured and unstructured data (e.g., Internet clickstream records, web server logs, IoT sensor data, etc.).
Advantages- data protection in the event of hardware failure, vast scalability (thousands of machines), real time analytics are offered
Apache Spark is also an open source, data processing engine for big datasets. It splits large tasks across many nodes like Hadoop, but it uses RAM to cache and process data instead of a file system/hard disk, which increases speed and enables Spark to handle use cases that Hadoop cannot.
Advantages- can be 100x faster than Hadoop for smaller workloads, has APIs designed for ease of use while using semi-structured data and transforming data
Spark runs faster than Hadoop at a lower batch size, but since it uses RAM rather than hard disk memory, it incurs a higher cost. Hadoop is better suited for large batch size data analyses(i.e. Extreme scaling up, say 10,000x) and linear data processing(i.e. Not scaling up at all from one node), and Spark is better suited for real time data analytics of live unstructured data streams.(i.e. Scaling up to a small extent only, say 100x)
Spark also has access to tools for ML (MLlib), which perform ML computations in memory.
(These are just my notes. This could be wrong info. Don’t take it as law.)