This is a sample Android project to showcase the Firebase Cloud Messaging (FCM) to manage upstream and downstream messages. To be precise, it is the client project for my XMPP Connection Server for FCM. The objective is to have an end-to-end testing:
- Upstream message: Android - FCM CCS - XMPP Client Server.
- Downstream message: XMPP Client Server - FCM CCS - Android.
Android
- Send upstream messages to the XMPP Client Server.
- Handle push notifications.
PHP
- Register tokens from devices into the database.
- Get the list of tokens from the database.
- Send push notifications to registered devices.
Firebase
- Send push notifications through the Firebase console.
XMPP Client Server
- Send downstream messages to a device. Java implementation.
For more information must read the following documentation:
- Create new project in Firebase
- Add Firebase to the Android project
- Set the FCM client app in Android
- Send upstream messages
- Receive downstream messages
- Volley library for Android
- Android
- Java
- Firebase Cloud Messaging
- PHP
- MySQL
- Apache Server
- Localhost for android emulator: 10.0.2.2
- IDE: Android Studio
- You can find the PHP and MySQL scripts in the application root folder.
- Implementation of an XMPP Connection Server for FCM
- XMPP Connection Server for FCM using the latest version of the Smack library (4.3.4)
- Implementation of a base exponential back-off strategy class
I am Carlos Becerra - MSc. Softwware & Systems. You can contact me via:
Any improvement or comment about the project is always welcome! As well as others shared their code publicly I want to share mine! Thanks!
Copyright 2020 Carlos Becerra
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.