Applications that rely on data in cloud storage do not need to stay current every minute of the day. Think of a social media app. The is “real-time” data such as a new post or a photo upload, but most of the data such as account information, user profile, and the place you went to high school do not need to update constantly. In a gaming app, there is a massive amount of real-time data such as your current location on a map (which is ever-changing), but your credit card number will likely stay the same month and month. To constantly update all data for a mobile or web app doesn’t make sense and only consumes uses unnecessary resources.
AWS AppSync is a way to synchronize the data used in a web or mobile app, allowing developers to choose which data should be synced in real-time.
AppSync relies on a GraphQL, which was originally developed by Facebook, for the data syncing. It’s intended to help developers who might need to pull data from different sources in the cloud, then perform functions within the app quickly and efficiently. It’s also highly secure so even though an app is syncing from multiple data sources, and developers are choosing which portions of an app can use real-time data or not, the data is still protected.
As mentioned, the application development service is intended for those who need to deal with massive amounts of real-time data and have that data sync to the application. Yet they also need the ability to decide which data does not need to sync in real-time. Developers can create complex queries that use a cloud database and aggregate the data or make complex decisions to analyze, process, or manipulate it from multiple sources.
The advantage here is that you can easily scale an application and use multiple Amazon services for your application, without being restricted by your IT infrastructure or where the data resides (and if you need to process all data in real-time).
Another advantage is that this can work with data that is offline for periods of time. In a gaming app, for example, the developer can sync real-time data but also coordinate what happens when the end-user continues to use the game and rack up a high score when he or she is no longer connected to the Internet. AppSync can them sync the offline data once the user makes a connection again without having to sync the entire data set. This reduces bandwidth requirements and speeds up data syncing for the web or mobile application.
Examples of using AWS Appsync
One example of using AWS AppSync is with a Big Data project. Often, with a research project at a large university, for example, the data sources are widely distributed. For a project analyzing new road construction, there might be data available related to material research in Zurich and environmental data from a lab in Munich, but the app development team is based in Chicago.
In the past, syncing all of this data for an app, and also deciding which data is mission-critical and must be real-time in nature and which data can be stored long-term and not synced, was quite an undertaking. It often requires a combination of multiple cloud services and a way to sync all of the data sources manually. Yet, AWS AppSync provides one console so that developers can understand their API and what is happening with their data.
Sensors might be installed to detect water leaks, look for intruders, and monitor whether a window has opened suddenly in the middle of the night. The Internet of Things (or IoT) is a concept that has allowed developers to create rich applications that unify and unite these disparate sensors to present a clear picture of what is happening in the home.
As you can imagine, pulling and monitoring this sensor data is a Herculean task. There might be thousands or even millions of data requests from an app -- e.g., every time someone opens a door or when a sensor detects a moving object. In a connected home app, some of the data can be at rest and won’t need to sync. With AWS AppSync, a developer can decide how to sync that data and what happens to it in real-time within the app, not only for the dozens of sensors that might be installed in a smart home but for hundreds or thousands of customers.
In the end, it’s the flexibility this provides that is key for developers creating rich applications that use multiple data sets from wildly varying sources from all over the globe.
- Protect your business with the best cloud firewall.