Server Implementation for Push Notifications Sent Between Android and iPhone Devices

I would like to write an instant messaging mobile application with push notifications. One requirement is to have both an iPhone and Android version able to send push notifications between 2 devices regardless of the device type.

I am having trouble coming up with a best solution to send push notifications for the following 4 cases:

  1. Android client -> server -> Android client.
  2. Android client -> server -> iPhone client.
  3. iPhone client -> server -> iPhone client.
  4. iPhone client -> server -> Android client.

I have a few questions:

  1. Did you find pushd simple to handle your push notifications? Did you run into any unforeseen issues?
  2. What are the pros and cons between creating my own node.js server implementation and using pushd for the 4 cases above (minus learning more from doing it myself)?
  3. Would it be simpler to use a different server implementation such as python or php through Apache?
  4. Were there any resources you found to be critical to writing your own server implementation?
  5. Is there a simpler suggestion for implementing push notifications between 2 cross-platform devices?

I've come across UrbanAirship and Pushwoosh but I don't think they apply to my use cases.

I apologize if this question seems to open-ended for SO but I have been struggling with this for the past few nights and am having a hard time coming up with these answers.

Thanks and I appreciate the help!

Check out Parse.com Its amazing, and their push notification service is much simplier than creating your own.

Set up an endpoint, gated to a database for your push notifications and post to that service w henever necessary. For clientside code, see here for Android and here for iOS. If you'd like server code, leave a comment and I'll post an edit to this answer,