Перейти к содержимому

Building a Distributed ETL Pipeline with MongoDB and Bacalhau

Expanso

0:00 / 0:00

Building a Distributed ETL Pipeline with MongoDB and Bacalhau

314 просмотров · 2 года назад
Expanso
146 подписчиков
314 просмотров · 2 года назад
In this tutorial, we show you how to spin up a Bacalhau Private Network to extract, transform, and load records from a local MongoDB database into a MongoDB Atlas instance. Why are we doing this? Well, modern infrastructure generates a lot of data in many different places. Keeping tabs on that data and accessing it when you want to gain some insight can be both logistically complex and expensive. Typically, there are two approaches: 1. You can aggregate data from all of your data sources in a centralised location and perform queries on that new, larger datastore. 2. You can process your data close to, or at the source of its generation, and then aggregate the results somewhere else for further analysis. Both approaches present challenges that aren't easy to overcome. When aggregating all your data, there are multiple factors in play that can make the approach even more challenging: Cost of bandwidth, cost of centralised storage, time to execute queries and more. Processing data on the edge can tackle some of those issues, but it comes with its own challenges. Namely: Tracking your infrastructure, communicating, and executing remotely on those data sources, and having a consistent, repeatable way to manage each individual data source. With Bacalhau, we can create a common interface for querying and filtering data at each source point and then aggregate a reduced set of key data points for further analysis at a central location. This process tackles the problems presented by both typical approaches. Instead of incurring fees and long wait times to transfer all your data from different sources, we extract only the data that we consider to be useful for any given application. Compared with the first approach, this means less bandwidth and storage utilisation, and a smaller centralised data source from which we can derive greater insight into our data, faster. For the second approach, we have a secure, consistent interface with which to execute processing on our data across the totality of our infrastructure, without having to consider the overhead of multi-regional, multi-cloud deployments.