-
Notifications
You must be signed in to change notification settings - Fork 355
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for windows raw notifications (in json form) #238
Conversation
Oh man travis, haha. |
Yeah, there's something weird going on with Travis wrt to Ruby 2.3.0. Rebuilding it fixes it. |
Windows raw notification support finished. No more commits coming. |
Great, thanks! I sadly cannot judge if this works since I've no way to test this myself, but it looks good, judging from the documentation. Do you think you could squash your commits a bit? |
It seems a payload cannot exceed 5KB, could you add a validation and specs for this? I think the other specs have it somewhere. See https://msdn.microsoft.com/en-us/library/windows/apps/hh761463.aspx#recommendations |
Added the validation and squashed the commit to a single commit. |
module Wns | ||
class RawNotification < Rpush::Client::ActiveRecord::Notification | ||
validates_with Rpush::Client::ActiveModel::PayloadDataSizeValidator, | ||
limit: 5000 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think they mean 5KB with base 10 (5 * 10^3 = 5000) and not 5KiB as in 5 * 2^10 = 5120 byte?
- The raw notification supports only json data, since the data model enforces hash. - Improved readme for Windows setup.
The payload limit is 2 based not 10, makes sense. Thanks for catching it. |
Add support for windows raw notifications (in json form)
Add support for windows raw notifications (in json form)
Added some helpful information to get going with the Windows notifications.