Closed karunreddy30 closed 6 years ago
Actually, I figured out the role of apns_codec after looking at https://github.com/processone/xmpp. I think including gcm into the same module would be trivial after that.
Hi @karunreddy30,
Glad the issue resolved.
As of your second question, you might want to have a separate record, not apns_users or gcm_users. You're absolutely correct about having an additional entry to indicate where user came from. Keep in mind that a single user might use both services (not likely, but possible).
Appreciate your inputs. I'll send a PR once I make the changes and test them. (Am not sure how to change this to a feature request and not an issue?)
It would be great if you updated mod_gcm to the latest ejabberd API, but I don't think I can accept a PR that makes a single module out of gcm and apns ones.
Best regards, John.
Firstly, thank you so much for the mod. I had a few questions about adapting this mod to include gcm endpoint as well and wanted to get your thoughts on how to go about it. I know there is a separate mod_gcm written by you, but I would like to have one mod take care of both end points. I'm not well versed with erlang, so please bear my ignorance.
My questions are as below:
What is the role of mod_apns_codec in this? If it is used just in parsing the register calls from clients. how do I go about changing it to decoding a register stanza from them, if it also has an extra tag (in addition to the device token) indicating if it is an android or iOS client? Also it seems to be auto generated?
I would like to change the record in the database to have additional entry for this client info indicating android/iOS. I was thinking to do this change in record(apns_users) section and go from there. Any inputs on the possible changes here?
Appreciate your inputs. I'll send a PR once I make the changes and test them. (Am not sure how to change this to a feature request and not an issue?)