views:

70

answers:

2

Hi All, I have a design scenario that is giving me a few headaches and I'm wondering what solution is the best solution.

I have a dashboard-like application that polls information from a service that requires a java RMI connection to gather real time data. I'd like to implement that dashboard component in silverlight and provide the data using WCF.

I've designed a solution for this in the past with .net remoting and Windows forms. My previous design was a windows service, but I'm wondering if there is a way for me to host this service like application in IIS.

The service needs to: ->Open RMI connection (this i've done with ikvm) ->pull data at regular intervals ->Update clients new data has arrived (observer pattern)

Could I implement a singleton instance of my data collection class and register observers? Should i just host WCF in a windows service? Any other ideas?

+1  A: 

Web architecture essentially is only about responding to requests. You can simulate PUSH with repeated polling from the client, but if the client isn't actively seeking information, you can't push it on them.

Depending on what your client needs, it sounds like a webservice with a background cache and poll system to keep it updated would be best, as your client would always get the most up to date information straight away. The cache and update could be maintained by a number of different solutions, but your client would only see the standard webservice.

You could enhance it further by having a smaller interface as part of the webservice to allow the client to check if there is an update before downloading it is the size of the download offsets the roundtrip to check for the update.

ck
A: 

IIS is designed to handle HTTP connections and these are normally short lived. In order to do this kind of thing you have to make the client poll the server on a regular basis.

Martin Brown