On IoT, edge computing and Couchbase Mobile. Q&A with Priya Rajagopal
Q1. What are the main challenges that enterprises face when implementing their mobile, IoT and edge strategy?
With the proliferation of edge and distributed computing and the demand to bring compute and storage closer to the source of data, companies face the following challenges
- From a functional perspective:
- Latency is a key consideration. Whether it is driving the end user experience on a mobile app or a mission critical app such as an autonomous vehicle or a robot hand, guaranteed latency. In the former case, you could lose a customer. In the latter case, it would be the question between life and health where sub-msec latencies are critical.
- Bandwidth is another criteria. This is a premium resource. Typically the edge is far flung – consider disaster recovery zones or a cruise ship. It would be cost prohibitive to send volumes of data from IoT and mobile endpoints to the cloud for analysis. So the edge needs to be capable of working as an autonomous unit, but we need a way to keep the edge data store in sync with the cloud in an efficient way. Having a sync technology that is smart about what data gets synchronized with the cloud and when is key.
- Data Privacy. Cannot overstate the importance of this criteria. Any app that collects context information to make personalized recommendations needs to be cautious about not sending this up back to the cloud. This is especially true for healthcare apps that collects personal data about diet, workout routines, etc.
- From an operational perspective:
- A way to efficiently deploy, monitor and manage your edge clusters is important. How do you do efficiently do software and hardware upgrades? How do you replace broken hardware? These are important challenges unique to edge computing that a centralized cloud-based deployment doesn’t offer.
- Cost is an important consideration. Especially as the number of edges grow. The solution needs to scale from a cost standpoint as well.
- This is a big challenge when it comes to edge computing. In a centralized environment, it would be possible to physically lock down a data center. The same isn’t necessarily true for the edge, which is a lot more “open” and consequently at risk.
Q2. What role does a foundational technology like a database play in an enterprise’s mobile, IoT and edge application strategy?
Bringing data storage close to the source of data is the cornerstone of edge computing, so the database plays an integral role. Here are some key capabilities that database solution should offer:
- The storage technology needs to be efficient so it can be deployed on relatively resource-constrained embedded devices.
- Going hand-in-hand with storage is the ability to efficiently query the data. A flexible database query API that is performant and flexible is critical to building complex workflows within edge apps.
- The ability to share the data on an edge device with the cloud or with other devices in the edge data center is important. The storage solution needs to have built-in sync capabilities to enable offline-first apps.
- Support for the heterogeneity of platforms and programming languages. It could be a mobile platform such as iOS, Android, or Windows, or it could be a non-mobile embedded device running embedded Linux or Windows IoT for instance.
- Last but not the least, security with enterprise-grade built-in encryption is essential for protecting data while at the edge.
Q3. What are some trends you’re seeing in the market that would indicate that it’s time to consider an edge strategy?
Industrial IoT (IIoT) and mobile are the key drivers here. Interestingly, these are the same trends that drove the cloud computing paradigm for reasons that included scale, cost, and manageability. Except that now, latency and bandwidth are the primary motivators for driving the computing to the edge. In addition to mobile and IoT applications, the ability for businesses to be able to deliver services and operate uninterrupted even in the face of poor or no network connectivity is growing in relevance. Customers are expecting services to be “always available.” A restaurant or a retail store cannot afford to shut its doors or turn away patrons if it loses internet connectivity. Businesses expect to continue to service its customers even when disconnected from the Internet. Once network connectivity is restored, sales and purchase orders can be synced up.
Q4. What is Couchbase Mobile?
Couchbase Mobile extends the power of Couchbase NoSQL data platform to the edge. It is comprised of three components:
- Couchbase Lite is an embedded, NoSQL JSON Document Style database for your mobile and embedded platforms. It is supported on iOS, Android and .NET platforms that includes UWP apps for any Windows platform. We recently published C API support as a community project making it well-suited for non-mobile embedded platforms.
- Sync Gateway, a stateless, synchronization endpoint that securely syncs data across Couchbase Lite clients and between Couchbase Lite clients and Couchbase server. It is responsible for access control. It is stateless and is backed by Couchbase Server.
- Couchbase Server, highly scalable, available, distributed NoSQL database platform that acts as the persistent data layer.
Couchbase Mobile offers a great deal of flexibility when it comes to deployment options. This is critical when it comes to edge computing. You can deploy Couchbase Mobile on-premises or in the cloud (any cloud) or in a hybrid cloud environment. You can containerize the platform making it easy to deploy on any hardware. Using a suitable container orchestration technique such as Kubernetes simplifies deployment. Finally, you can directly sync between Couchbase Lite clients which works well for several edge field applications
Q5. What are the new functionality Couchbase has built into the latest version of your mobile solution?
We recently announced Couchbase Mobile 2.5. This release builds on the strong architectural foundation that was laid out with the release of Couchbase Mobile 2.0 last year. It includes some features that are particularly relevant for edge deployments, including:
Delta Sync. For deployments where network bandwidth is constrained, the delta sync feature enhances the sync protocol by syncing only parts of the document that have changed, resulting in significant savings in bandwidth consumption. Depending on the size of the document and change, we have observedup to 90% savings in bandwidth with delta sync. The system automatically detects what has changed and sends only that change over. The change is then patched on the receiving end.
Predictive Query API.Couchbase Lite’s new Predictive Query API, available in Developer Preview, allows mobile applications to leverage mobile-optimized, pre-trained, machine learning models to run predictive queries against data in your database in a convenient, fast, and always available way. You can use the API to correlate real time predictions with predictions made on application data stored in the database.
We have also introduced a number of features that improve platform supportability, which is important for edge deployments. These include enhanced logging on Couchbase Lite and significantly enhanced the stats reporting on Sync Gateway. This is important to get important insights into the health of your Couchbase Mobile deployment.
Q6. Why is a database a good fit for correlating ML predictions with application data?
Machine learning (ML) on the edge offers several benefits, including fast real-time predictions, adherence to data privacy restrictions and always-available, offline support. The ecosystem is rife for Machine Learning on the edge-with machine learning models optimized for mobile, enhancements in the silicon layer for running these models and the “democratization of ML,” which has made it easier than ever to train such models. So it is logical for edge applications to leverage these platform and ecosystem advancements to run real-time predictions on the database directly.
Building this support into the database means you can now create a Predictive index on the data. This is essentially a cache of the output of running the ML predictions against the database.
This yields significant performance benefits at the time of query.
This is better illustrated with an example. Consider the case of a user who walks into a big-box retail store holding an item or an image of an item of interest. The user approaches the sales associate and enquires about availability of the item, say in a different size or color. The sales associate captures the image of the item using her store app. The image that is captured is real-time data and is run through a ML classifier that identifies the object and thein-store catalog database on the sales associate’s app is queried for matches. The employee can then direct the user to the appropriate aisle in the store where the item is available. This vastly improves the overall shopping experience. The prediction and database look-up is done locally on the phone which means it is fast and always available, even if the store loses connection to the Internet.
For privacy reasons, the user may not want the item whose image was captured to hit the cloud. In this example, the captured image never leaves the employee phone and is never stored anywhere, even on the employee’s device.
Qx. Anything else you wish to add?
While edge computing is growing in relevance, it complements cloud computing and does not replace it. Cloud computing will continue to offer benefits with economies of scale, cost and manageability. But with all the benefits that edge computing brings, a hybrid cloud strategy should be an important consideration for any business or mission-critical application.
—————————–
Priya Rajagopal is a Principal Product Manager for Couchbase focusing on the Couchbase Mobile and IoT platform. She has been professionally developing software for 20 years in several technical leadership positions, with the last 8 years focused on mobile technologies. She is a co-inventor on 22 patents spanning areas of networking and platform security.
Sponsored by Couchbase.