Can't we use getdataactiivty() of telephone manager to know current status 
of the data connectivity to fire some sort of hit to web to wake the 
network from dormant state

getDataActivity return following states has any tried this way
*DATA_ACTIVITY_NONE*<http://developer.android.com/reference/android/telephony/TelephonyManager.html#DATA_ACTIVITY_NONE>
*DATA_ACTIVITY_IN*<http://developer.android.com/reference/android/telephony/TelephonyManager.html#DATA_ACTIVITY_IN>
*DATA_ACTIVITY_OUT*<http://developer.android.com/reference/android/telephony/TelephonyManager.html#DATA_ACTIVITY_OUT>
*DATA_ACTIVITY_INOUT*<http://developer.android.com/reference/android/telephony/TelephonyManager.html#DATA_ACTIVITY_INOUT>
*DATA_ACTIVITY_DORMANT*<http://developer.android.com/reference/android/telephony/TelephonyManager.html#DATA_ACTIVITY_DORMANT>



On Tuesday, 10 December 2013 11:30:33 UTC+5:30, Mukesh Srivastav wrote:

> I had the similar situation where in the GCM was not able to receive on 2G 
> and most of the time it failed. I have drawn a work around, since my 
> application deals with the Webservices, I have created  a new webservice 
> called "Getgcmfromthedb", I am calling the same service before calling any 
> other services and updating the status back to 2 for READ and 3 for Process.
>
>
>
>
>
> On Tue, Dec 10, 2013 at 10:27 AM, ranjit R <ranji...@gmail.com<javascript:>
> > wrote:
>
>> I am using 2g network for Instant messaging .with payload less than 2kb..
>>  In 3g network success rate of receiving gcm messages is 10/10 with out 
>> queueing of messages in gcm messaged in GCM server.
>>
>> In 2G network " here Is the problem" 5/10 messages are received instantly 
>> other 5 goes in to queue I n GCM server ..
>> My question is 
>> As Google queue messages on gcm server When phone is idle. 
>> 1 is there a callback to device when gcm message is queue in server.
>>  2 is there way to optimize gcm messages on 2g network 
>> 3 when does gcm expire.
>> 4 or is there better way of handling gcm message for 2G
>>  
>> -- 
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to 
>> android-d...@googlegroups.com<javascript:>
>> To unsubscribe from this group, send email to
>> android-developers+unsubscr...@googlegroups.com <javascript:>
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "Android Developers" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to android-developers+unsubscr...@googlegroups.com <javascript:>.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>
>
> -- 
> Warm Regards,
> *Mukesh Kumar*,
> Android Consultant/Freelancer,
> India,Hyderabad.
>  

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to