android-c2dm

SERVICE_NOT_AVAILABLE some devices on Android GCM

只愿长相守 提交于 2019-11-28 10:29:58
问题 I made an app using GCM for notifications. I used this tutorial and my code is pretty much identical http://developer.android.com/google/gcm/client.html I'm testing on physical devices and on some of the devices I am getting a SERVICE_NOT_AVAILABLE error when I try to register the device with GCM. I have an exponential backoff setup so it does retry over time. It works on about half of my test devices the others get a SERVICE_NOT_AVAILABLE error. Looked all over and haven't found a solution

Discovering if Android activity is running

社会主义新天地 提交于 2019-11-28 10:20:22
I'm using C2DM, my BroadcastReceivers propagate the C2DM events to a local service. the service complete the registration by sending the id to my webserver pus it's responsible for letting the device know about new messages, however if the application (one of the activities) is up we want to send an intent to that activity with the new data so it can be updated, if not than the NotificationManager is used to notify the user. The issue is, how to know the activity is running ? the Application object is not an option since the Service is part of the application it's obviously going to be present

Google Cloud messaging - Sample Server

北城以北 提交于 2019-11-28 05:07:40
I need a sample application for Google Cloud messaging. with a sample server to test my app. can any one help me on this? I need a sample server to test my code i already written the code but i dont know wheather it will work or not. i dont know server side coding so anyone could help me on this. here is my code intent service package com.example.pushnotificationsample; import android.content.Context; public class GCMIntentService extends GCMBaseIntentService { protected GCMIntentService(String senderId) { super(senderId); // TODO Auto-generated constructor stub } @Override protected void

How to collapse Android notifications?

流过昼夜 提交于 2019-11-28 02:03:07
问题 I'm sending a C2DM update to my Android app every 1/2 hour, which creates a Notification. Problem is, when I wake up in the morning I get 15 Notifications queued up in the status bar. How do I only keep the latest notification, overwriting previous ones? I tried looking at the C2DM documentation (http://code.google.com/android/c2dm/) which mentions a parameter called collapse_key, but I couldn't find an explanation for how to use it, nor am I sure the solution lies on the C2DM side. Thanks!

Is GCM service reliable for large scale push notification?

隐身守侯 提交于 2019-11-28 01:39:04
问题 I want to push notifications to around 50,000 users at a time and about 50 notifications per day, is it a good choice to use GCM in this case? If not can i know which other push services can i use , i dont mind even if its a paid service.. Thanks in advance 回答1: One notification can send only to 1000 devices (GCM limit).So you must split your array of devices. 50.000 users its ok for GCM. Our application serve 100.000 users. As case you can use airpush notification service: http://www.airpush

Unable to Deploy Android App Engine Project on Google App Engine

↘锁芯ラ 提交于 2019-11-28 00:52:28
问题 I am create one smile application in Android + Google App Engine in eclipse. i am trying to deploy that app on Google app Engine but it show the error message Log Cat : Unable to update: com.google.appengine.tools.admin.HttpIoException: Error posting to URL: https://appengine.google.com/api/appversion/getresourcelimits?app_id=AppEngineTest2&version=1& 400 Bad Request Client Error (400) The request is invalid for an unspecified reason. at com.google.appengine.tools.admin

Emulator without GPU emulation detected

戏子无情 提交于 2019-11-27 23:32:14
I am trying to execute a sample C2DM Application, but I get an "Emulator without GPU emulation detected"` message in my Logcat. In Android SDK Tools R15 you can enable GPU emulation. You need to create a new emulator virtual device and set GPU emulation to true in Hardware properties. GPU enabling is now is allowed directly through Emulator Creation option.Go to Window --> Android Virtual Device Manager --> new .Now remember to check mark "Use GPU host", then you will have pretty fast working emulator with GPU enable. Android Virtual Device Manager -> Edit AVD -> Show Advanced settings ->

C2DM: How to use C2D_MESSAGE permission?

不打扰是莪最后的温柔 提交于 2019-11-27 22:40:29
I am about to implement C2DM for my application, but I find the documentation a bit confusing regarding how to write the manifest. The manifest code example contains this: <!-- Only this application can receive the messages and registration result --> <permission android:name="com.example.myapp.permission.C2D_MESSAGE" android:protectionLevel="signature" /> <uses-permission android:name="com.example.myapp.permission.C2D_MESSAGE" /> This is explained as follows: applicationPackage + ".permission.C2D_MESSAGE prevents other applications from registering and receiving the application's messages.

Android two player game to be played in internet

房东的猫 提交于 2019-11-27 22:11:10
问题 I have developed a simple two player chess game in android to be played using Bluetooth. I want to extend it by making it possible to be played through internet. whenever a player makes a move, the move should be transferred to the other player via internet. How to make this possible? I have heard of C2DM mechanism.Does that suites the scenario i described and is it reliable? Thanks:) 回答1: Another option is to use some sort of IM as a communication medium for app. For eg. Use Asmack to

Android C2DM port number choice

一笑奈何 提交于 2019-11-27 21:43:51
问题 I noticed that the Google C2DM (push) tcp connection uses port 5228. I also know that some firewalls block ports other than 80 443 (because of htttp and https), which causes lots of users to complain that they can't use the Market app or GTalk on their phones using their company wifi for example. Now my question is: why didn't Google choose port 443 or 80 for their persistent tcp connection? 回答1: There are a few reasons I can think of that Google may have chosen to use 5228 instead of 80 or