Create push notification server for android without using GCM

How can we create a push notification service without using GCM to send messages to one android device. I don't need to use GCM because it is very slow and beta.

Can anyone help me with this.

Thanks in advance.

Sathish

+3


source to share


2 answers


Google Cloud Messaging is not included in the beta at all. :)

If you want to avoid using Google's service, it's best not to repeat it. Try using other frameworks like Amazon SNS:

http://aws.amazon.com/sdkforandroid/



or

http://code.google.com/p/openmobster/wiki/PushFramework

Or something else.

+3


source


You can install PSB ( http://pservicebus.codeplex.com/ ) and use the Java API ( https://github.com/rpgmaker/PServiceBus-Java-Client ) to communicate between your Android devices.

When building an application using the Java client API. You can create a post for example.

public class Notification {
   public int Id;
   public String Message;
}

      

And when you subscribe to a post in the android app, you just apply the filter when you subscribe.



ex

PSBClient.Subscribe(Notification.class, new Action<Notification>() {
   public void execute(Notification msg){
      //Do something with message
   }
}, "Id = UniqueAndroidID");

      

When publishing a message to a specific device, you simply do the following:

Notification message = new Notification();
message.Id = 10003432;//Unique Android ID
message.Message = "Hello Android Device";
PSBClient.publish(message);

      

0


source







All Articles