Question

I have created a .Net app which allows to query IIS logs of some web servers. The app calls WCF service to get data. WCF service location has the IIS logs in place. The WCF service internally calls Logparser on the IIS log files and returns the result. There are multiple IIS log files. If I run logparser on all of them in one go, it takes a lot of time to return as there are about 30 huge IIS log files which are queried. I want to run logparser on each of these IIS logs one by one and return result one by one.

I am looking for a framework which works over WCF and allows piece by piece data retrieval from the WCF service. So I want to get result of IISlogfile1, then of IISlogfile2, and so on. Otherwise the UI will have to wait for a very long time to get full result in one go.

Do you know of any existing framework which allows part by part retrieval of data from WCF service?

PS: The workaround I have is to call the service multiple times, once for each IIS log file, till it responses that all data is sent. But I am looking for a cleaner solution.

Was it helpful?

Solution

This question seems very related to your scenario, see if the answer from Steven Cheng helps you. The gist of his answer is you can try Duplex services where the server can call the client when it completes processing each log file.

Edit:

Also take a look at SignalR framework to establish a persistent connection between server and client, so you can send notifications (in your case log file) from server as it finishes processing one. An example here.

OTHER TIPS

Well Souvik basu,

I am not sure if this helps or not but you can do this way.

First call a WCF service to get the count of files you have.

Then inside loop you call WCF service with file name and bind them with gridview+jqgrid or some asynchornously calling magic.

This way you can progress and show data on asynchornously and your latency will be less. Your WCF service will also be less loaded.

Hope i make my point clear.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top