explaingit

zomato/pulse-droid

Analysis updated 2026-05-18

26KotlinAudience · developerComplexity · 3/5Setup · moderate

TLDR

An Android library that wraps MQTT messaging (real-time updates, notifications) behind a simple command-based API with retries and auto-reconnect.

Mindmap

mindmap
  root((pulse-droid))
    What it does
      Wraps Paho MQTT client
      Simplifies Android integration
    Tech stack
      Kotlin
      Coroutines
      Gson
    Use cases
      Push notifications
      Real-time order updates
      Device signalling
    Audience
      Android developers

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Add real-time push notifications to an Android app.

USE CASE 2

Stream live order or status updates from a backend to a mobile app.

USE CASE 3

Build reliable device-to-server signalling with automatic retries.

What is it built with?

KotlinMQTTCoroutinesGsonAlarmManagerWorkManager

How does it compare?

zomato/pulse-droidwifi-x-smasher/nuvio-windows-unofficialhuiyeji-7/pei-pei-shua
Stars262524
LanguageKotlinKotlinKotlin
Setup difficultymoderateeasyeasy
Complexity3/52/52/5
Audiencedevelopergeneralgeneral

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires implementing a bridge object to supply logging, JSON, and coroutine scope.

No license information is shown in the available documentation.

In plain English

pulse-droid is a Kotlin library from Zomato that wraps the Eclipse Paho MQTT client to make it easier to use inside Android apps. MQTT is a lightweight messaging protocol commonly used for things like push notifications, real-time order updates, or device-to-server signalling, where small messages move between an app and a broker over a long-lived connection. The library is published as a kit called PulseMqttKit and the README is mostly an integration guide for Android developers. You start by creating an instance of PulseMqttKit inside your Application class and calling initialize, passing in a context and a bridge object that you implement. The bridge lets the library reach back into your app for things like the logger you want to use, a Gson instance for JSON, a coroutine scope, a health monitoring config, and a network monitoring config. This means the library does not force a particular logging or serialization choice on the host app. All MQTT actions go through a command submission model rather than direct method calls. There are ConnectCommand, PublishCommand, SubscribeCommand, UnsubscribeCommand, and DisconnectCommand types, each submitted with pulseMqttKit.submitCommand. Commands can declare dependencies on other commands, so for example you can attach a ConnectCommand as a dependency of a SubscribeCommand and the subscribe will only run if the connect succeeds first. Each command also takes a retry policy: Sequential for fixed intervals, Exponential for back-off, Jitter for adding randomness so many clients do not retry at the exact same moment, or None to disable retries. You can exclude specific MQTT exception codes, like NOT_AUTHORIZED, from retry attempts. The connection options can include an AutoSubscriptionConfig with a map of topics and the message types and quality of service levels you expect on each. When this is enabled, the library re-subscribes to those topics on its own after a reconnect, so you do not have to resend SubscribeCommands yourself. You can also register listeners that receive results for each command, including how many retry attempts were used and the total execution time, and unregister them when done. For staying connected over time, the library has a health monitoring system that can run periodic checks through either Android's AlarmManager or Jetpack WorkManager and reconnect automatically if the link drops. A shutDown call disconnects and clears all listeners. The README is published as plain documentation with example code, no license is shown in the clipped portion.

Copy-paste prompts

Prompt 1
Show me how to initialize PulseMqttKit inside my Android Application class.
Prompt 2
Write a SubscribeCommand that depends on a ConnectCommand and uses exponential retry.
Prompt 3
Set up an AutoSubscriptionConfig so my app resubscribes to topics after reconnect.
Prompt 4
Explain how pulse-droid's health monitoring keeps an MQTT connection alive using WorkManager.

Frequently asked questions

What is pulse-droid?

An Android library that wraps MQTT messaging (real-time updates, notifications) behind a simple command-based API with retries and auto-reconnect.

What language is pulse-droid written in?

Mainly Kotlin. The stack also includes Kotlin, MQTT, Coroutines.

What license does pulse-droid use?

No license information is shown in the available documentation.

How hard is pulse-droid to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is pulse-droid for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.