README.md in lead_zeppelin-0.1.1 vs README.md in lead_zeppelin-0.1.2
- old
+ new
@@ -32,18 +32,24 @@
# You can provide .p12 files too! p12: File.read('./yourapp.p12')
c.add_application :your_app_identifier, pem: File.read('./yourapp.pem')
end
-# Add a poller to read messages via a method of your choosing:
+## Polling
+Add a poller to read messages via a method of your choosing:
+
# Poll every second, join parent (main) thread so it doesn't close
client.poll(1, join_parent_thread: true) do |c|
- c.message :demoapp, 'f80d44bc73b4a856d9bcd63c2285e5190f8a7dcd8af34cfdf1f4a23cfd66423d', "testing!"
+ c.message :demoapp, 'YOUR_DEVICE_TOKEN_GOES_HERE', "testing!"
end
+If you already have the generated JSON payload, you can inform the message sender to not encode to JSON:
+
+ c.message :demoapp, 'YOUR_DEVICE_TOKEN_GOES_HERE', '{"aps":{"alert":"Now Playing: Dazed and Confused"}}', raw: true
+
# Logging
LeadZeppelin#logger takes a Logger class:
require 'logger'
@@ -66,6 +72,7 @@
* *TESTING*
* Way to handle errors asynchronously using a pool
* Performance and concurrency speedups
* Edge cases
* Documentation (code level and regular)
-* Length checking for payload, possibly an auto truncating feature
+* Length checking for payload, possibly an auto truncating feature
+* Research Celluloid and Celluloid::IO integration (waiting on [this ticket](https://github.com/celluloid/celluloid-io/pull/11))
\ No newline at end of file