One Library, Double Power: Integrate Huawei and Google Services with CMS

Feyza Ürkut
Huawei Developers
Published in
4 min readAug 6, 2024
Photo by Sylvia Yang on Unsplash

Introduction

Hello everyone! 😊 As Huawei developers, we created an open-source project to enable mobile application developers to integrate both Huawei Mobile Services (HMS) and Google Mobile Services (GMS) using a single library.

❤️ Let’s explore this library and our other projects together!

My Neighbor Totoro

Common Mobile Services (CMS)

This library provides a unified interface for mobile services for Android developers. Its purpose is to eliminate specific mobile service dependencies in your application code, offering the following benefits:

💫 Separation of Concerns

  • By removing creation and lifecycle control code from your application code, it ensures that your classes are free from unnecessary responsibilities. This results in cleaner, more maintainable, and sustainable code.

💫 Flexibility and Compatibility

  • Allows the use of different mobile services. For instance, not all Android devices have Google Mobile Services (GMS). This library ensures compatibility regardless of which mobile service the device supports, allowing you to use different services without changing your application code.

💫 Easy Integration

  • With a single library, you can easily integrate both HMS and GMS services simultaneously, simplifying mobile application development.

💫 Wide Device Support

  • Ensures that your applications are compatible with a broader range of devices, increasing your user base.

💫 Reduced Development Time

  • Speeds up the development process with a more modular and flexible codebase.

💫 Improved User Experience

  • Enhances the user experience by enabling seamless transitions between different services.

💫 Ease of Maintenance

  • Makes code maintenance and updates easier due to its modular structure.

This library offers developers a more flexible and sustainable solution, enhancing both the compatibility and user experience of their applications.

Photo by Marvin Meyer on Unsplash

What Are We Currently Working On in the Project?

💥 New Kit Integrations

  • We are working on integrating various new kits into the project.
  • By utilizing each kit’s APIs and features, we are making the project more functional.
  • We conduct tests after integration to ensure that the kits work correctly.

💥 Version Updates

  • We are updating the versions of existing kits to the latest versions.
  • We integrate the changes and innovations brought by the new versions into the project.
  • Security patches and performance improvements from version updates are included in the project.

💥 Updating the README File

  • We add all the changes and innovations made in the project to the README file.
  • We provide information about newly added kits, version updates, and integration processes.
  • We carefully organize the README file so that users can easily access the most up-to-date information about the project.

💥 Documentation

  • We write explanations with Kdoc documents that describe the functionality of each method, class, and package.
  • These documents help developers better understand the code and maintain the project more easily.
  • We create materials, like this article, about the implementations, changes, and innovations made in the project.
  • We hope that this preparation will be helpful for users and developers to be aware of new features and kits.

Through all these efforts, we aim to make the project more comprehensive and user-friendly.

Spirited Away

CMS DEMO: Using Kits with the CMS Library

With the CMS DEMO project, we aim to make the use of this library more understandable and accessible.

In this project, we provide practical examples using the most common and fundamental features of the kits. For instance, we perform simple ad integrations with the Ads Kit, display maps with the Map Kit, and use location data for location detection and navigation with the Location Kit. This helps developers learn how to use the basic functions of the kits.

Our goal is to facilitate the integration of the CMS library for those who want to use it and provide ready-made solutions they can use in their projects. With CMS DEMO, developers will be able to quickly and effectively implement features that add value to their projects while discovering the potential of the kits.

🎯 You can access the GitHub repositories of our projects from the references section.

Benefits of the Demo Project

💙 Real-World Testing: It allows us to test the CMS library in real-world scenarios and validate its functionality.

💙 Improvement and Refactoring: The demo project helps us identify shortcomings and areas for improvement in the CMS library, allowing us to make necessary adjustments.

💙 Bug Detection and Resolution: We can quickly identify and fix bugs that arise during the project.

💙 Documentation Development: By anticipating issues users may encounter, we can create more comprehensive and explanatory documentation.

💙 Testing New Features: We can test the integration and impact of newly added features, increasing stability.

💙 Ensuring Project Compatibility: By checking compatibility with different devices and services, we can ensure the CMS library works seamlessly across a wide range of environments.

The Wind Rises

Result

The CMS library simplifies the development process by allowing developers to use various services through a single library. This open-source library aims to provide diversity and flexibility in mobile applications.

CMS DEMO helps developers easily use and integrate the CMS library into their projects. We hope this article assists you in making your projects more user-friendly and comprehensive 😊

References

--

--