title: Android Push Notifications Without using Firebase Cloud Messaging or any other similar service
body: <p>I am developing an android chat application for learning purposes that uses a server- client architecture. I wrote the server side myself in Java (because I am trying to learn) and the client side is an android app. I am using TCP sockets for communication. </p>
  
  <p>Everything works great when the two clients have their apps open and are connected, but I would like client A to still be able to send a message to client B <strong>when client B does not have the app open.</strong> </p>
  
  <p>After doing some research I realized that I need to use <strong>the android push up notifications</strong> that will allow my server to communicate with the client (the android app) even when the app is not opened or running <strong>by triggering an intent on the client side</strong>. I did some more research and every tutorial that I found is using a third party service as a middle man to achieve this , such as Firebase Cloud Messaging, which defeats my purpose of trying to learn by doing things myself. </p>
  
  <p>Because I am doing this for learning purposes <strong>I do not want to use any of these services such as Firebase Cloud Messaging</strong>, I would like to trigger the intent myself from the server that I wrote in java without using the middle-man.</p>
  
  <p>The main goal here is to send messages from my server to the android app when the app is closed, without using any third party software such as Firebase Cloud Messaging. </p>
  
  <p>I am unsure of how to achieve this and I would appreciate it if anyone could point me at the right direction. 
  Thanks!</p>