fbpx

Satellite Data Types in Bubble

Follow me:

In our last Bubble.io article, we looked at how we can use the Data Weight analogy to visualize how the structure of our Data Types can affect performance. But what do we do with the information?

What is a Satellite Data Type?

Satellite Data Types is another term we introduced in our book The Ultimate Guide to Bubble Performance. In short, they are extra Data Types that you set up to serve a specific purpose, usually unbeknownst to your Users. A typical use case is when you work with a Data Type that has a high Data Weight (containing lots of unstructured data and fields), and your Users also need to frequently and quickly search for that Type.

Returning to our example from earlier, we’re setting up an online magazine with thousands of articles. The articles can be any length from a 5-minute read to 45 minutes, thus containing potentially large volumes of unstructured data. Our magazine also has an advanced search feature, where Users can quickly search for articles that may interest them. In that case, we have what we call a Requirement Conflict. Our Data Type needs to:

  • store a lot of unstructured data
  • be lightweight enough for quick searching and displaying

As we set up the requirements for this Data Concept, we can easily identify the conflict here: a high data weight slows down searches. In some cases this can be an acceptable compromise – other times you need to rethink your database structure to prepare the Data Concept to fulfill both requirements.

This is where Satellite Data Types come in.

Satellite Data Type for searching and storing

The solution to the predicament above is to separate the two requirements (storing lots of data and searching quickly) into two different Data Types. This is where we’ll return to the Data Concept model – we’re going to set up two separate Data Types, but to our Users, there’s still only one Data Concept: the Article. To keep the two Data Types separated, we’ll divide them into two categories:

Illustration of the heavy Container Data Type and the lighter Satellite Data Type called Search Data Type
Our Container Type is a bit heavy, so we introduce a new Search Type that allows for faster searches with less data to download.

The Data Container

The Data Container is the Data Type that contains all the heavy data we need to store, such as the Article HTML/BBCode content. We don’t mind that this one can end up heavier, as we’ll only ever load one at a time.

The Search Data Type

The Search Data Type (the Satellite) contains a more lightweight version of the same Article record. There are two things you’ll need to consider when setting the Type up:

  • What fields do you need to search for this type?
    For an Article, typical fields would be the header, the author and perhaps some sort of tags and/or categories
  • What fields do you need to display the search results for this type?
    You may need to include fields not needed for searching, such as a thumbnail photo, word count or whatever info you want to show in your results.

Whenever a User searches for Articles, Bubble will be looking for the Search Data Type, and whenever a result is clicked to view or edit the full Article, Bubble switches to the Data Container. As illustrated below, we don’t need to load the Type with the high Data Weight until the last step.

satellite data types user journey
This is what the User journey might look like when browsing Articles. Your app silently switches between the two Data Types, but the User is never aware.

To keep the two Data Types in check, we can set up workflows to update fields on the Search Data Type whenever the Data Container is changer, or better yet – use Back-end Triggers to keep them always up to date.

There are several scenarios where this can be useful – let’s have a look at some of them.

Other scenarios for using Satellite Data Types in Bubble

The important thing about Satellite Data Types it to not think of them as search types or data containers. These are simply two common use cases, but the important lesson is that your Data Concepts don’t need to match your Data Types – you’re free to set up your database in the way that serves your app best, not in the way that your Users imagine it to be.

Site-wide search is another scenario where Satellite Data Types come in handy. In the book, we use TripAdvisor as an example; from the same search bar you can search for countries, cities, attractions, hotels and restaurants. In Bubble, this would mean performing five searches simultaneously – hardly efficient. But you can use a Satellite Search Data Type to combine multiple Data Types into one searchable Data Type, allowing for site-wide search for as many different kinds of records you want.

Satellite Link Data Type is a similar way to combine several data types in cases where you need to link different data types to each other. Let’s say you’re using one of the Rich Text Editor plugins that support tags for example, and you want to be able to tag multiple data types, you can set up a Satellite Link type that “represents” multiple Data Types in a search.

For more scenarios and the full process for structuring your database, you can check out the full chapter in The Ultimate Guide to Bubble Performance.

Support the site and keep it free ❤️

I love tech startups and the Bubble community, and have made it my mission to try and create content that’s valuable, easy to follow and entertaining.

Creating content next to full-time consulting work is time-consuming; if you’d like to support it and keep the site free for everyone, please consider buying me a coffee or becoming a supporting member.

Buy Me A Coffee

Follow me:
Bubble.io books

Learn Bubble the right way

Our professional Bubble books teach you how to plan, structure and build your applications right from the start.

5-star review stars

More Posts

2 Comments


Fabrice Jeullain
November 21, 2022 at 22:50
Reply

Hello,
The images are not displayed in the article. Thanks for the great work!


    Petter Amlie
    December 7, 2022 at 11:55
    Reply

    Hi Fabrice,

    Thanks for letting me know The images should now be displaying correctly!

Leave A Reply

Your email address will not be published. Required fields are marked *

*

Email icon

Useful articles and tips

Join the mailing list to get guides, opinions and articles on Bubble, no-code, automation and the tech industry.

We don't share your email address with anyone, and you can unsubscribe at any time.

You have successfully subscribed