tags:

views:

169

answers:

2

We need is to push sports data to a number of different client types such as ajax/javascript, flash, .NET and Mac/iPhone. Data updates need to only be near-real time with delays of several seconds being acceptable.

How to best accomplish this?

A: 

I would go with XML. XML is widely supported on all platforms and has lots of libraries and tools available for it. And since it's text, there are no issues when you pass it between platforms.

I know JSON is another alternative, but I'm not familiar enough with it to know whether or not to recommend it in this case.

17 of 26
JSON is becoming much more widely supported than XML in a lot of cases. Naturally it works perfectly with a web client (JavaScript) but with RESTful communications I see JSON being used for serialization which is directly supported in both .NET and the iPhone developer toolkits. I assume JSON is well supported in other platforms.
Brennan
+1  A: 

The best solution (if we're talking .NET) seem to be to use WCF and streaming http. The client makes the first http connection to the server at port 80, the connection is then kept open with a streaming response that never ends. (And if it does it reconnects).

Here's a sample that demonstrates this: Streaming XML.

The solution to pushing through firewalls: Keeping connections open in IIS

Sire