arleyandrada / PushClient

FREE and Open Source - Titanium PushClient Module
Other
44 stars 17 forks source link

Let me ask some before I dev deep with yours #26

Closed somefakeuser closed 9 years ago

somefakeuser commented 9 years ago

Hi Arley,

I've tried out your module and was suprised at how easy it is :). I'm trying out some equivalent modues to GCM receivers for a couple of days.

Let me ask some before I dev deep with yours:

1: Is your module capable of recieving messages while the app isn't running? (I'm guessing the answer is no but let me ask just in case!)

I'm also trying out GCM.js also and it seems it's got a bit advantage to your module. http://iamyellow.net/post/40100981563/gcm-appcelerator-titanium-module ( GCM.js looks a little bit outdated though, since it's based on gcm.jar)

2: I didn't notice but the error below came up in console. any ideas?

[ERROR] GooglePlayServicesUtil: The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.

Full trace: http://pastebin.com/A94iEDGg

Thanks in advance, if you need further infos please hit me up!

Best,

arleyandrada commented 9 years ago

Hi,

With iOS you can set the "remote-notification" in UIBackgroundModes to receive notifications when the app isn't running. Read more about this feature released with iOS 7 and easily use it with my module.

With Android, when the app receive the push notification, if it isn't running, a background thread within the app is started (handled by my module to show it at notification center) but is not possible to fire a callback to the JavaScript source code; However, if the app is only waiting in background, the callback event will be fired as expected.

The problem with Google Play Services and also none of the "unable to resolve static field" are expected. Please, check some itens:

Attached Click Here is a full working example project to my PushClient module. Please check if your problems still happening with it.

Regards,

Arley

somefakeuser commented 9 years ago

Arley,

Thanks so much for rapid repsonse, apologies to not getting back to you sooner. I clearly understood how it works now thanks to your answers. Unfortunately it doesn't meet our requirement this time but will use it whenever I can, it's so easy and up-to-date :).

To answer your queries:

  • Are you using Titanium SDK 3.2.1.GA or superior? Yes I do, it's on 3.3.0GA (which is latest at the moment)
  • Within the PushClient module installed folder you can find the "google-play-services.jar" file within the "lib" subfolder? Not sure if I had one in there, I just copied and pasted folders in the zip directly both for android and iOS. (sorry, I've cleared up directories just some days ago and can't verify this.)
  • Are your app using another module with different Google Play Services? As long as I know, No. unless Titanium runs it as a default.

Regards,

arleyandrada commented 9 years ago

Hi,

Please tell me why my module does not meet your requirements and maybe I can improve it.

Did you tried to run my sample project and have checked if it works to you without to show console log errors?

Regards,

Arley

somefakeuser commented 9 years ago

Hi Arley,

The reason I've chosen gcm.js over yours this time is that we need the capability of firing various callbacks along with push-messaged JSONs, whether or not the app is not-running/active/paused. this feels not right though.. Other than that your module's obviously superior. As to your sample, I need another few days since I'm too pressed for now.

Best,

arleyandrada commented 9 years ago

Hi,

Thanks for the feedback.

I have plans to improve my module to best handle the background callback when the app is not running in next weeks.

I will follow you back when I release a new version of my module.

Regards,

Arley

somefakeuser commented 9 years ago

Hey Arley,

Quick question, is there any way to localise push messages by using "loc-key" property with your module? (Titanium 'as-is' can't handle it from what I see, and I don' want to localise the string on the server side.)

Thanks in advance!

Regards,

arleyandrada commented 9 years ago

Hi,

Unfortunately is not possible to localize messages from my module YET.

Today you need to send the device language info to your server in order to allow the sending of the localized message to each device.

Regards,

Arley

somefakeuser commented 9 years ago

Hi Arley,

Thanks for getting back quick, got your message. It's weird but localisation is working with raw Titanium now somehow... though it did not work for my first try. Anyways thanks again!

Regards,