Setting Up the Push Notification Sample Application
The Push Notification Sample Application source code is installed by default with the Microsoft Exchange Server 2010 Web Services Software Development Kit (SDK) in the directory in which the Exchange 2010 Web Services SDK is installed, in the \Samples\PushNotification\ folder. This sample includes two applications. The first application is a client Web service that accepts notifications from the computer on which the Client Access server role is installed. This must be set up first. The second application creates the subscription. The second application uses the URL to the client Web service to define where the notification messages should be sent.
Note
This sample application is intended for instructional purposes only and is not meant to be installed in a production environment.
Prerequisites
The following prerequisites are needed to build and use the Push Notification Sample Application:
Microsoft.NET Framework
MicrosoftVisual Studio .NET
MicrosoftInternet Information Services (IIS)
Exchange 2010
The types.xsd and messages.xsd schema files that are found in the EWS virtual directory of the computer that is running Exchange 2010
Building the Push Notification Client Web Service Application
To build the push notification client Web services application
Open the client Web services project.
Navigate to the directory in which the Exchange 2010 Web Services SDK is installed, open the Samples\PushNotification\PushNotificationClient\ folder, and double-click the PushNotificationClient.sln file.
From the Build menu, select Build Web Site.
Publish the Web site to an IIS virtual directory.
Note
When the client Web service is published to IIS, make sure that the virtual directory uses ASP.NET 2.0 for the client application.
Setting Up and Building the Push Notification Client Subscriber Application
To set up and build the subscriber application
Navigate to the directory in which the Exchange 2010 Web Services SDK is installed, open the Samples\PushNotification\PushNotificationSubscriber\ folder, and double-click the PushNotificationSubscriber.csproj file.
Update the ExchangeServiceBindingUrl property to identify the location of the Exchange Web service.
Update the ExchangeServiceBindingCredentials property to identify the name, password, and domain of the user whose mailbox will be monitored for events.
Update the PushSubscriptionRequestTypeURL property to identify the location of the client Web service that will receive the event notifications. This URL is defined by the location of the client Web service.
From the Build menu, select Build Solution.