Problem solve Get help with specific problems with your technologies, process and projects.

How to approach mobile optimization with less risk

Microservices and containers can help boost mobile optimization, but it's not automatic. Development teams must think carefully about tooling choices, API creation and more.

Mobile optimization is the process of making applications compatible with mobile devices and app platforms used...

by most workers today. It's a kind of application modernization process, and like other modernization processes, enhancements should avoid the creation of excessive risk or disruption.

Browser-based access to applications usually follows what is referred to as the storefront design pattern, which creates a landing page where routine business tasks can reside. Using this pattern, the graphical user interface (GUI) is organized in a way that cuts the need for a worker to remember URLs for several different applications. In mobile optimization, the storefront functionality is partially ceded to the app, but the so-called storefront and the processes behind it are typically used for browser access, which will aid mobile users who prefer to use browser access rather than an app.

Since the user's perception of the application is really determined by the specific app on the device itself, make sure to explicitly synchronize the mobile app with the underlying major application. This synchronization occurs in two dimensions.

First, it occurs at runtime when the transaction state is maintained and connection issues are settled. It also occurs when you make changes to either the application or mobile app version. With mobile apps, the app is separate and often distributed in an app store. This means that updates may not always be synchronized with the rest of the application.

Microservices, containers and mobile apps

Both microservices and containers are essential for efficient mobile optimization. Low overhead and high application density per server are natural features of containers, which makes them effective hosting platforms for any componentized app, including microservices. Microservices used in mobile optimization should focus on business logic and perform exactly what a mobile user would see as a specific business function, such as an order placement or a stock status check. But don't break down microservices beyond that level for mobile user access, because too many APIs make it difficult to create reliable app-to-app linkages.

The API gateway is the most common strategy used to support the container approach. API gateways tend to divide things into classes, depending on whether the plan is to use containers to build your own applications or to use the public cloud and cloud provider web services to facilitate scalable and agile mobile front-end design. You may need a second class of tools if you use multiple public clouds for mobile front-end tasks.

The right mobile optimization tools

Major public cloud providers offer tools to build both browser and mobile front ends for traditional applications. These provider-supplied tools work best if you can completely separate the GUI from transaction processing. By keeping them separate, the browser or app can establish the UI and connect transactions to business processes via a message queue.

In a mobile front end, apps may communicate in different ways, which often requires specific accommodations for the type of mobile device or mobile OS used. Try to harmonize the functional dialog between the apps and the cloud front end. Also, use mobile backend as a service (MBaaS) tools to accommodate differences in how the apps run.

Even if you don't use the public cloud, it's still worthwhile to select a good MBaaS tool that can be deployed either in the cloud or in a data center. MBaaS tools bring harmony to BYOD development tasks. They can also help developers create an intermediary data model that serves as a link between the deployed microservices and mobile users. This model not only makes front-end and app development easier, but it also helps maintain transaction state even if a mobile connection is a bit unreliable.

Remember that the release cycle for store-distributed apps is much longer than that of webpages. To combat this, try to create stable APIs upfront, because mobile apps must tightly attach to microservices APIs. And to avoid synchronization problems, build an intermediate data model, and pass data payloads to and from the mobile app using XML or JSON with all the possible fields represented. This enables you to adapt the mobile interface without rereleasing the app.

Opt for functional microservices

Containers are an ideal way to host any kind of microservices, but so-called functional microservices are particularly created for mobile operations. When you use containers to host microservices, the way in which you deploy containers as a kind of virtual application can appear arbitrary; some users put one microservice in each deployment, while some put them all in a single container. However, functional microservices create a natural aggregation strategy of sorts. If you deploy functional microservices by an orchestrator, like Kubernetes, then you can also deploy more compositional microservices and reduce the intercomponent traffic and delay.

Consider an API broker replacement

By using containers, it's possible to create a sort of microservices hub and replace the storefront used for browser access. This strategy can help prevent mobile apps and microservices from coupling too tightly to one another and can even eliminate the need for an API broker. The elimination of an API broker can improve performance depending on the complexity of the API broker implementation and the degree to which a delay is introduced.

Finally, it's important to review application dialogs to find elements that may confuse mobile users. Acquiring user feedback on elements as simple as confirmation questions and interface buttons can help you decide if there is need for a rollback in the mobile back-end process. Stay aware of the things that distinguish mobile users from other users -- as well as the limitations that they face -- to solve mobile optimization problems.

This was last published in October 2018

Dig Deeper on Development implications of microservices architecture

Join the conversation

1 comment

Send me notifications when other members comment.

Please create a username to comment.

How do microservices and containers help solve your mobile optimization challenges?
Cancel

-ADS BY GOOGLE

SearchSoftwareQuality

SearchCloudApplications

SearchAWS

TheServerSide.com

SearchWinDevelopment

DevOpsAgenda

Close