How eclipse-paho/paho.mqtt.android works
Project Type & Overview
• This is an Android service library for MQTT. Its purpose is to enable Android applications to communicate over MQTT (supporting MQTT 3.1 and 3.1.1, SSL/TLS, WebSocket, etc.).
• Besides the core service, the project offers sample applications (in directories like org.eclipse.paho.android.sample and paho.mqtt.android.example) which demonstrate how to use the service.
And Isolate the Main Components
• MQTT Android Service Library:
• Core internal components (e.g., MqttAndroidClient, MqttService, MqttConnection, MqttDeliveryTokenAndroid).
• Components handling persistence (Persistence, DatabaseMessageStore) and connectivity (AlarmPingSender, MqttTraceHandler).
• Internal package components that manage connections and message storage.
• Android Sample Applications:
• UI layers and activity components (e.g., MainActivity, various Fragments in the sample app).
• Adapters, view components, and layouts that interact with the service.
• Build and Configuration Tools:
• Gradle and Maven configuration files, wrappers and CI configurations (e.g., .travis.yml, build.gradle, settings.gradle).
• Testing Layers:
• Android tests included under src/androidTest and unit tests under src/test.
• External Services:
• The actual MQTT brokers that the service will connect to, using protocols like SSL/TLS and WebSocket.