SlideShare uma empresa Scribd logo
1 de 21
Xamarin
   Seminar
      9th August 2012
    Copyright 2012 © Xamarin Inc. All rights reserved
Agenda
Push Notifications - Introduction to Push Sharp

                                  Jonathan Dick
                                  DBA, Mobile App Developer
                                  jondick@gmail.com
                                  Twitter: @redth
                                  Blog: http://redth.info
                                                   Professional Android
                                                   Programming with Mono for
                                                   Android and .NET/C# (Co-Author)
                                                   http://amzn.to/MyKMZy



                                                                            Xamarin
               Copyright 2012 © Xamarin Inc. All rights reserved
Push Notifications

            What are they?
    Why Should I use them?
      How do they work?
        Platform Specifics
        PushSharp Library
           Pitfalls to avoid
 Alternative Ways to Send them


                                                          Xamarin
      Copyright 2012 © Xamarin Inc. All rights reserved
What are Push
              Notifications?

• Think Growl but for Mobile
• Small bits of information only
• Pushed instead of Pulling
• Platforms have specific API’s



                                                                       Xamarin
                   Copyright 2012 © Xamarin Inc. All rights reserved
Why use Push
              Notifications?

•More realtime than Polling
•Scalability - many apps, one connection
•Lower resource consumption
•Easier than ‘rolling your own’



                                                                      Xamarin
                  Copyright 2012 © Xamarin Inc. All rights reserved
How do Push Notifications
                 Work?




Registering for Push Notifications
 1. App requests Push Notification Registration
 2. Unique Registration ID generated by provider
 3. ID sent to your Cloud Service

Sending a Push Notification
 1. Your cloud service builds notification with Unique Registration ID of device
 2. Notification is sent to Provider Push Notification Gateway
 3. Provider’s Push Notification Gateway delivers the notification to the device

                                                                                  Xamarin
                              Copyright 2012 © Xamarin Inc. All rights reserved
Platform Specific Implementations

•Each platform has its own Implementation
 • Apple Push Notification Service (APNS)
 • Google Cloud Messaging (GCM)
 • Windows Phone Notification Service

•Apple is most difficult to work with
•Many 3rd party libraries exist
 • APNS-Sharp, C2DM-Sharp, EasyAPNS, etc.




                                                                        Xamarin
                    Copyright 2012 © Xamarin Inc. All rights reserved
Platform Specific Implementations

•Each platform has its own Implementation
 • Apple Push Notification Service (APNS)
 • Google Cloud Messaging (GCM)
 • Windows Phone Notification Service

•Apple is most difficult to work with
•Many 3rd party libraries exist
 • APNS-Sharp, C2DM-Sharp, EasyAPNS, etc.

     If only there was a better way...

                                                                        Xamarin
                    Copyright 2012 © Xamarin Inc. All rights reserved
PushSharp to the Rescue!
• Open Source - Apache 2.0 License

• Abstraction of APNS, GCM, Windows Phone

• Fluentish API for building notifications

• Sample code: MonoTouch & Mono for Android

• Managed Code: MS.NET CLR, Mono, Azure

• GitHub - Fork & Contribute

• BuddyTV App currently sending 100,000+ / day


                                                                                    Xamarin
                                Copyright 2012 © Xamarin Inc. All rights reserved
Sample Time !!1!




                                                       Xamarin
   Copyright 2012 © Xamarin Inc. All rights reserved
Apple Sample




                                                     Xamarin
 Copyright 2012 © Xamarin Inc. All rights reserved
Apple Sample




                                                     Xamarin
 Copyright 2012 © Xamarin Inc. All rights reserved
Google Sample




                                                      Xamarin
  Copyright 2012 © Xamarin Inc. All rights reserved
Google Sample




                                                      Xamarin
  Copyright 2012 © Xamarin Inc. All rights reserved
Windows Phone 7 Sample




                                                           Xamarin
       Copyright 2012 © Xamarin Inc. All rights reserved
Windows Phone 7 Sample




                                                           Xamarin
       Copyright 2012 © Xamarin Inc. All rights reserved
Alternatives to PushSharp
•3rd party Push Notification Services
 • Provide some abstraction
 • Easier to handle device registrations

•Urban Airship - most popular
•Parse.com - ‘Channels’ concept
•Drawbacks of 3rd Party Services
 • Do not support all platforms
 • Another API to code against
 • Still need your own Cloud Service to generate notifications


                                                                          Xamarin
                      Copyright 2012 © Xamarin Inc. All rights reserved
Pitfalls to Avoid
• Read the PushSharp GitHub wiki
• Read documentation for each platform
• Apple will make your cry
 • Development Provisioning Profile must use Sandbox Server
 • AdHoc & AppStore Provisioning Profiles must use Production Server
 • Make sure you export your Push SSL Certificate WITH Private Key
• Push Notifications not guaranteed to be delivered
• Google C2DM is deprecated - use GCM now


                                                                                Xamarin
                            Copyright 2012 © Xamarin Inc. All rights reserved
Questions?


                                                      Xamarin
  Copyright 2012 © Xamarin Inc. All rights reserved
References
PushSharp Project Site:
https://github.com/redth/PushSharp

Follow me on Twitter: @redth

My Blog: http://redth.info


Urban Airship - http://urbanairship.com

Parse.com - http://parse.com
                                                                      Xamarin
                  Copyright 2012 © Xamarin Inc. All rights reserved
Xamarin
    Seminar
   Please give us your feedback
  http://bit.ly/xamfeedback


      Follow us on Twitter
        @XamarinHQ

          9th August 2012
        Copyright 2012 © Xamarin Inc. All rights reserved

Mais conteúdo relacionado

Destaque

How Industries Push Mobile Engagement & Next-Level Opportunities
How Industries Push Mobile Engagement & Next-Level OpportunitiesHow Industries Push Mobile Engagement & Next-Level Opportunities
How Industries Push Mobile Engagement & Next-Level OpportunitiesMobile Marketing Association
 
Beacon Presentation Retail BLE 4.0
Beacon Presentation Retail BLE 4.0Beacon Presentation Retail BLE 4.0
Beacon Presentation Retail BLE 4.0Andrew Spaulding
 
Presentation On Airship
Presentation On AirshipPresentation On Airship
Presentation On AirshipHarshit0107
 
Practical Push Notifications Seminar
Practical Push Notifications SeminarPractical Push Notifications Seminar
Practical Push Notifications SeminarXamarin
 
The Customer Engagement Balancing Act
The Customer Engagement Balancing ActThe Customer Engagement Balancing Act
The Customer Engagement Balancing Act Urban Airship
 
Google cloud messaging
Google cloud messagingGoogle cloud messaging
Google cloud messagingAmardeep Vijay
 
Microservice vs. Monolithic Architecture
Microservice vs. Monolithic ArchitectureMicroservice vs. Monolithic Architecture
Microservice vs. Monolithic ArchitecturePaul Mooney
 
Mobile Push Notifications
Mobile Push NotificationsMobile Push Notifications
Mobile Push NotificationsMike Willbanks
 

Destaque (10)

How Industries Push Mobile Engagement & Next-Level Opportunities
How Industries Push Mobile Engagement & Next-Level OpportunitiesHow Industries Push Mobile Engagement & Next-Level Opportunities
How Industries Push Mobile Engagement & Next-Level Opportunities
 
Portland ad fed
Portland ad fedPortland ad fed
Portland ad fed
 
Beacon Presentation Retail BLE 4.0
Beacon Presentation Retail BLE 4.0Beacon Presentation Retail BLE 4.0
Beacon Presentation Retail BLE 4.0
 
Presentation On Airship
Presentation On AirshipPresentation On Airship
Presentation On Airship
 
Practical Push Notifications Seminar
Practical Push Notifications SeminarPractical Push Notifications Seminar
Practical Push Notifications Seminar
 
The Customer Engagement Balancing Act
The Customer Engagement Balancing ActThe Customer Engagement Balancing Act
The Customer Engagement Balancing Act
 
Google cloud messaging
Google cloud messagingGoogle cloud messaging
Google cloud messaging
 
Push Notification
Push NotificationPush Notification
Push Notification
 
Microservice vs. Monolithic Architecture
Microservice vs. Monolithic ArchitectureMicroservice vs. Monolithic Architecture
Microservice vs. Monolithic Architecture
 
Mobile Push Notifications
Mobile Push NotificationsMobile Push Notifications
Mobile Push Notifications
 

Mais de Xamarin

Xamarin University Presents: Building Your First Intelligent App with Xamarin...
Xamarin University Presents: Building Your First Intelligent App with Xamarin...Xamarin University Presents: Building Your First Intelligent App with Xamarin...
Xamarin University Presents: Building Your First Intelligent App with Xamarin...Xamarin
 
Xamarin University Presents: Ship Better Apps with Visual Studio App Center
Xamarin University Presents: Ship Better Apps with Visual Studio App CenterXamarin University Presents: Ship Better Apps with Visual Studio App Center
Xamarin University Presents: Ship Better Apps with Visual Studio App CenterXamarin
 
Get the Most Out of iOS 11 with Visual Studio Tools for Xamarin
Get the Most Out of iOS 11 with Visual Studio Tools for XamarinGet the Most Out of iOS 11 with Visual Studio Tools for Xamarin
Get the Most Out of iOS 11 with Visual Studio Tools for XamarinXamarin
 
Get the Most out of Android 8 Oreo with Visual Studio Tools for Xamarin
Get the Most out of Android 8 Oreo with Visual Studio Tools for XamarinGet the Most out of Android 8 Oreo with Visual Studio Tools for Xamarin
Get the Most out of Android 8 Oreo with Visual Studio Tools for XamarinXamarin
 
Creative Hacking: Delivering React Native App A/B Testing Using CodePush
Creative Hacking: Delivering React Native App A/B Testing Using CodePushCreative Hacking: Delivering React Native App A/B Testing Using CodePush
Creative Hacking: Delivering React Native App A/B Testing Using CodePushXamarin
 
Build Better Games with Unity and Microsoft Azure
Build Better Games with Unity and Microsoft AzureBuild Better Games with Unity and Microsoft Azure
Build Better Games with Unity and Microsoft AzureXamarin
 
Exploring UrhoSharp 3D with Xamarin Workbooks
Exploring UrhoSharp 3D with Xamarin WorkbooksExploring UrhoSharp 3D with Xamarin Workbooks
Exploring UrhoSharp 3D with Xamarin WorkbooksXamarin
 
Desktop Developer’s Guide to Mobile with Visual Studio Tools for Xamarin
Desktop Developer’s Guide to Mobile with Visual Studio Tools for XamarinDesktop Developer’s Guide to Mobile with Visual Studio Tools for Xamarin
Desktop Developer’s Guide to Mobile with Visual Studio Tools for XamarinXamarin
 
Developer’s Intro to Azure Machine Learning
Developer’s Intro to Azure Machine LearningDeveloper’s Intro to Azure Machine Learning
Developer’s Intro to Azure Machine LearningXamarin
 
Customizing Xamarin.Forms UI
Customizing Xamarin.Forms UICustomizing Xamarin.Forms UI
Customizing Xamarin.Forms UIXamarin
 
Session 4 - Xamarin Partner Program, Events and Resources
Session 4 - Xamarin Partner Program, Events and ResourcesSession 4 - Xamarin Partner Program, Events and Resources
Session 4 - Xamarin Partner Program, Events and ResourcesXamarin
 
Session 3 - Driving Mobile Growth and Profitability
Session 3 - Driving Mobile Growth and ProfitabilitySession 3 - Driving Mobile Growth and Profitability
Session 3 - Driving Mobile Growth and ProfitabilityXamarin
 
Session 2 - Emerging Technologies in your Mobile Practice
Session 2 - Emerging Technologies in your Mobile PracticeSession 2 - Emerging Technologies in your Mobile Practice
Session 2 - Emerging Technologies in your Mobile PracticeXamarin
 
Session 1 - Transformative Opportunities in Mobile and Cloud
Session 1 - Transformative Opportunities in Mobile and Cloud Session 1 - Transformative Opportunities in Mobile and Cloud
Session 1 - Transformative Opportunities in Mobile and Cloud Xamarin
 
SkiaSharp Graphics for Xamarin.Forms
SkiaSharp Graphics for Xamarin.FormsSkiaSharp Graphics for Xamarin.Forms
SkiaSharp Graphics for Xamarin.FormsXamarin
 
Building Games for iOS, macOS, and tvOS with Visual Studio and Azure
Building Games for iOS, macOS, and tvOS with Visual Studio and AzureBuilding Games for iOS, macOS, and tvOS with Visual Studio and Azure
Building Games for iOS, macOS, and tvOS with Visual Studio and AzureXamarin
 
Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017Xamarin
 
Connected Mobile Apps with Microsoft Azure
Connected Mobile Apps with Microsoft AzureConnected Mobile Apps with Microsoft Azure
Connected Mobile Apps with Microsoft AzureXamarin
 
Introduction to Xamarin for Visual Studio 2017
Introduction to Xamarin for Visual Studio 2017Introduction to Xamarin for Visual Studio 2017
Introduction to Xamarin for Visual Studio 2017Xamarin
 
Building Your First iOS App with Xamarin for Visual Studio
Building Your First iOS App with Xamarin for Visual StudioBuilding Your First iOS App with Xamarin for Visual Studio
Building Your First iOS App with Xamarin for Visual StudioXamarin
 

Mais de Xamarin (20)

Xamarin University Presents: Building Your First Intelligent App with Xamarin...
Xamarin University Presents: Building Your First Intelligent App with Xamarin...Xamarin University Presents: Building Your First Intelligent App with Xamarin...
Xamarin University Presents: Building Your First Intelligent App with Xamarin...
 
Xamarin University Presents: Ship Better Apps with Visual Studio App Center
Xamarin University Presents: Ship Better Apps with Visual Studio App CenterXamarin University Presents: Ship Better Apps with Visual Studio App Center
Xamarin University Presents: Ship Better Apps with Visual Studio App Center
 
Get the Most Out of iOS 11 with Visual Studio Tools for Xamarin
Get the Most Out of iOS 11 with Visual Studio Tools for XamarinGet the Most Out of iOS 11 with Visual Studio Tools for Xamarin
Get the Most Out of iOS 11 with Visual Studio Tools for Xamarin
 
Get the Most out of Android 8 Oreo with Visual Studio Tools for Xamarin
Get the Most out of Android 8 Oreo with Visual Studio Tools for XamarinGet the Most out of Android 8 Oreo with Visual Studio Tools for Xamarin
Get the Most out of Android 8 Oreo with Visual Studio Tools for Xamarin
 
Creative Hacking: Delivering React Native App A/B Testing Using CodePush
Creative Hacking: Delivering React Native App A/B Testing Using CodePushCreative Hacking: Delivering React Native App A/B Testing Using CodePush
Creative Hacking: Delivering React Native App A/B Testing Using CodePush
 
Build Better Games with Unity and Microsoft Azure
Build Better Games with Unity and Microsoft AzureBuild Better Games with Unity and Microsoft Azure
Build Better Games with Unity and Microsoft Azure
 
Exploring UrhoSharp 3D with Xamarin Workbooks
Exploring UrhoSharp 3D with Xamarin WorkbooksExploring UrhoSharp 3D with Xamarin Workbooks
Exploring UrhoSharp 3D with Xamarin Workbooks
 
Desktop Developer’s Guide to Mobile with Visual Studio Tools for Xamarin
Desktop Developer’s Guide to Mobile with Visual Studio Tools for XamarinDesktop Developer’s Guide to Mobile with Visual Studio Tools for Xamarin
Desktop Developer’s Guide to Mobile with Visual Studio Tools for Xamarin
 
Developer’s Intro to Azure Machine Learning
Developer’s Intro to Azure Machine LearningDeveloper’s Intro to Azure Machine Learning
Developer’s Intro to Azure Machine Learning
 
Customizing Xamarin.Forms UI
Customizing Xamarin.Forms UICustomizing Xamarin.Forms UI
Customizing Xamarin.Forms UI
 
Session 4 - Xamarin Partner Program, Events and Resources
Session 4 - Xamarin Partner Program, Events and ResourcesSession 4 - Xamarin Partner Program, Events and Resources
Session 4 - Xamarin Partner Program, Events and Resources
 
Session 3 - Driving Mobile Growth and Profitability
Session 3 - Driving Mobile Growth and ProfitabilitySession 3 - Driving Mobile Growth and Profitability
Session 3 - Driving Mobile Growth and Profitability
 
Session 2 - Emerging Technologies in your Mobile Practice
Session 2 - Emerging Technologies in your Mobile PracticeSession 2 - Emerging Technologies in your Mobile Practice
Session 2 - Emerging Technologies in your Mobile Practice
 
Session 1 - Transformative Opportunities in Mobile and Cloud
Session 1 - Transformative Opportunities in Mobile and Cloud Session 1 - Transformative Opportunities in Mobile and Cloud
Session 1 - Transformative Opportunities in Mobile and Cloud
 
SkiaSharp Graphics for Xamarin.Forms
SkiaSharp Graphics for Xamarin.FormsSkiaSharp Graphics for Xamarin.Forms
SkiaSharp Graphics for Xamarin.Forms
 
Building Games for iOS, macOS, and tvOS with Visual Studio and Azure
Building Games for iOS, macOS, and tvOS with Visual Studio and AzureBuilding Games for iOS, macOS, and tvOS with Visual Studio and Azure
Building Games for iOS, macOS, and tvOS with Visual Studio and Azure
 
Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017
 
Connected Mobile Apps with Microsoft Azure
Connected Mobile Apps with Microsoft AzureConnected Mobile Apps with Microsoft Azure
Connected Mobile Apps with Microsoft Azure
 
Introduction to Xamarin for Visual Studio 2017
Introduction to Xamarin for Visual Studio 2017Introduction to Xamarin for Visual Studio 2017
Introduction to Xamarin for Visual Studio 2017
 
Building Your First iOS App with Xamarin for Visual Studio
Building Your First iOS App with Xamarin for Visual StudioBuilding Your First iOS App with Xamarin for Visual Studio
Building Your First iOS App with Xamarin for Visual Studio
 

Último

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024SynarionITSolutions
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 

Último (20)

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 

Push Notifications - Introduction to PushSharp Seminar

  • 1. Xamarin Seminar 9th August 2012 Copyright 2012 © Xamarin Inc. All rights reserved
  • 2. Agenda Push Notifications - Introduction to Push Sharp Jonathan Dick DBA, Mobile App Developer jondick@gmail.com Twitter: @redth Blog: http://redth.info Professional Android Programming with Mono for Android and .NET/C# (Co-Author) http://amzn.to/MyKMZy Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 3. Push Notifications What are they? Why Should I use them? How do they work? Platform Specifics PushSharp Library Pitfalls to avoid Alternative Ways to Send them Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 4. What are Push Notifications? • Think Growl but for Mobile • Small bits of information only • Pushed instead of Pulling • Platforms have specific API’s Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 5. Why use Push Notifications? •More realtime than Polling •Scalability - many apps, one connection •Lower resource consumption •Easier than ‘rolling your own’ Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 6. How do Push Notifications Work? Registering for Push Notifications 1. App requests Push Notification Registration 2. Unique Registration ID generated by provider 3. ID sent to your Cloud Service Sending a Push Notification 1. Your cloud service builds notification with Unique Registration ID of device 2. Notification is sent to Provider Push Notification Gateway 3. Provider’s Push Notification Gateway delivers the notification to the device Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 7. Platform Specific Implementations •Each platform has its own Implementation • Apple Push Notification Service (APNS) • Google Cloud Messaging (GCM) • Windows Phone Notification Service •Apple is most difficult to work with •Many 3rd party libraries exist • APNS-Sharp, C2DM-Sharp, EasyAPNS, etc. Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 8. Platform Specific Implementations •Each platform has its own Implementation • Apple Push Notification Service (APNS) • Google Cloud Messaging (GCM) • Windows Phone Notification Service •Apple is most difficult to work with •Many 3rd party libraries exist • APNS-Sharp, C2DM-Sharp, EasyAPNS, etc. If only there was a better way... Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 9. PushSharp to the Rescue! • Open Source - Apache 2.0 License • Abstraction of APNS, GCM, Windows Phone • Fluentish API for building notifications • Sample code: MonoTouch & Mono for Android • Managed Code: MS.NET CLR, Mono, Azure • GitHub - Fork & Contribute • BuddyTV App currently sending 100,000+ / day Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 10. Sample Time !!1! Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 11. Apple Sample Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 12. Apple Sample Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 13. Google Sample Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 14. Google Sample Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 15. Windows Phone 7 Sample Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 16. Windows Phone 7 Sample Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 17. Alternatives to PushSharp •3rd party Push Notification Services • Provide some abstraction • Easier to handle device registrations •Urban Airship - most popular •Parse.com - ‘Channels’ concept •Drawbacks of 3rd Party Services • Do not support all platforms • Another API to code against • Still need your own Cloud Service to generate notifications Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 18. Pitfalls to Avoid • Read the PushSharp GitHub wiki • Read documentation for each platform • Apple will make your cry • Development Provisioning Profile must use Sandbox Server • AdHoc & AppStore Provisioning Profiles must use Production Server • Make sure you export your Push SSL Certificate WITH Private Key • Push Notifications not guaranteed to be delivered • Google C2DM is deprecated - use GCM now Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 19. Questions? Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 20. References PushSharp Project Site: https://github.com/redth/PushSharp Follow me on Twitter: @redth My Blog: http://redth.info Urban Airship - http://urbanairship.com Parse.com - http://parse.com Xamarin Copyright 2012 © Xamarin Inc. All rights reserved
  • 21. Xamarin Seminar Please give us your feedback http://bit.ly/xamfeedback Follow us on Twitter @XamarinHQ 9th August 2012 Copyright 2012 © Xamarin Inc. All rights reserved

Notas do Editor

  1. \n
  2. Book promo code\n
  3. \n
  4. \n
  5. \n
  6. \n
  7. If only there was a better way... Extra Advance\n
  8. \n
  9. \n
  10. Extra Advance\n
  11. Extra Advance\n
  12. Extra Advance\n
  13. \n
  14. \n
  15. \n
  16. Book promo code\n
  17. Book promo code\n