Vinod K Singh wrote:Though I do not have any clues about Exchange web services but as AFAIK web services can't send any notifications. They are supposed to be invoked by client to get any information.
In addition to pull subscriptions (using polling, as another poster mentioned), EWS in Exchange 2007 supports push notifications; when you initially create your subscription (by invoking an EWS service, obviously) you pass it the URI of your web-service/WCF service. When changes to the folder that you subscribed to happen in Exchange Server, it (Exchange 2007) will make a call to the web-service at the URI you originally passed with information about the event.
There are some options you can specify when setting up your subscription, but by default, Exchange will try several times to invoke your web-service, at increasing intervals.
As far as writing a Java web-service to handle the Exchange notifications, you could generate the proxy classes for the types and messages Exchange sends/receives by using wsimport on the types.xsd and messages.xsd and Services.wsdl files. This will generate a set of Java classes that represent folders, contacts, emails, folder types, and so on.
Or, if you have a very limited scenario, I suppose you could hand-roll your own
soap messages using a SOAP library like KSOAP2 or something. I'm going thru some of this right now creating a lightweight library to use for pulling certain info out of Exchange 2007 from Android.