editor's choice app store

As an SDK developer, it’s important to fear about way more than simply transport new options. You may have to have the ability to ship these options with the least quantity of assets attainable. Your SDK is simply part of your consumer’s app, and it has to play together with many different SDKs which can be additionally built-in into the app. In case your SDK begins to have an effect on the app negatively or devour a disproportionate quantity of assets, your customers will look to interchange it with any of the opposite comparable components obtainable to them. On this put up, we’ll check out what that you must do to ensure your SDK doesn’t have an effect on your host app.

 

Table of Contents:

Measurement

The dimensions of an app is usually inversely proportional to app downloads. The larger the dimensions of an app, the much less possible customers are going to obtain it, particularly if the app is anticipated to deal with non-demanding duties. This makes the dimensions of your SDK an enormous deciding issue for builders when they’re selecting the SDKs they are going to be utilizing of their app.

It’s important to be extremely aware of the dimensions of your SDK. Use the minimal variety of dependencies attainable and at all times select compressed or optimized codecs to attenuate the dimensions of your SDK.

Launch time

App launch time is likely one of the most vital metrics tracked by cellular app builders to measure their app efficiency. Apps that take too lengthy to launch are irritating for customers and threat being uninstalled and this isn’t a threat most cellular builders are able to take.

Any SDK that noticeably will increase launch time dangers being changed by a extra performance-conscious competitor. Be sure to don’t have any long-running operations in the principle thread to initialize your SDK to keep away from considerably bumping up launch time.

Threading

A quick launch is ineffective if all different app actions are sluggish. As a lot as cellular builders care about their app launch time, additionally they need to be sure that their app supplies a seamless expertise.

In case your SDK has a substantial impact on the efficiency of the app’s most important actions, it can swiftly be reduce out of your consumer’s stack. Be sure to at all times run your operations within the background except it’s a UI exercise.

Battery drain

Whether or not you might be carrying them out within the background or the UI, operations use processor energy and drain the battery. Whereas it may appear to you that you’re not going overboard, think about that the typical Android app makes use of 18 SDKs.

With all these SDKs operating their operations in tandem with the app’s most important operations, it provides up rapidly and interprets to sizeable useful resource consumption. And now, it’s simpler than ever for builders to seek out out precisely what makes their app power-hungry.

It’s important to be aware of your useful resource consumption and maintain it to a minimal. Community calls, as an illustration, could cause a big drain to the battery if not correctly managed and stored to a minimal. Additionally, instruments like encryption are nice however it’s important to select your encryption technique correctly and make sure to use it solely when it’s really wanted.

Run-time reminiscence

At all times needless to say your SDK is secondary to the app that’s utilizing it. In case your SDK holds up a variety of reminiscence, it could critically have an effect on the efficiency of your consumer’s app.

This goes past avoiding reminiscence leaks —that are a deadly sin for cellular SDKs— and needs to be about being as environment friendly as attainable together with your reminiscence utilization. It’s best to at all times maintain as little reminiscence as attainable for as little time as you want.

Don’t intervene together with your consumer’s app

This sounds apparent, however it may be straightforward to by accident change the app’s conduct for those who don’t put that into cautious consideration in your SDK design. In case your SDK has any UI parts, you have to ensure that their placement and design don’t intervene with the consumer expertise.

UI apart, you have to even be aware of issues just like the again stack and the way your SDK’s actions ought to behave in it. You also needs to ensure that all of your assets have a prefix of their names to keep away from conflicting with the app and make them simpler to establish in your customers.

Don’t crash your consumer’s app

Whereas technically this belongs to the earlier level, crashing your consumer’s app is the deadliest of sins for an SDK and deserves it’s personal level. Crashes are extraordinarily disruptive to the consumer expertise and your customers are spending an excessive amount of effort to handle their very own code’s high quality to fret about yours.

Your error-handling sport have to be on level and your SDK have to be able to deal with any error irrespective of how surprising. But it surely doesn’t cease with error-handling and you must observe different defensive programming strategies like enter validation.