Looking for the right solution to asynchronous content back to asp.net page. Chunked? SignalR? Streaming? Not even sure what I’m looking for.

I’ve got a webapp that when the user clicks submit on a page, we call system.management.automation.powershell in the background. PS has callback functions for the various output streams (errors, warnings, host, etc) that right now queue in memory and the output is then generated at the end.

I want the callback functions from the various streams to be fed back to the user on the page in real-time. I tried UpdatePanel but as near as I can tell, that only supports one update per page call (if there’s an example showing otherwise, that would be great).

I researched SignalR, but it seems like that is for syncing multiple users to the same content. That doesn’t apply, we’re not sharing data between users.

Right now, everything happens on the same page. Is calling a separate page with chunking enabled and using ajax on the front end the “correct” way to do it?

Any recommendations? I’m not even sure what the correct terminology really is for what I’m trying to do.

TIA for any suggestions, examples, any tips you can provide.

submitted by /u/mdomansky
[link] [comments]

Leave a Reply