Architect a .net web application to Kick start independent process
Can somebody form an idea on how to architect a web application which will kick开发者_如何学编程 start an independent process in the server which can perform data uploading function from flat file to Oracle table. This independent process should keep running until it finishes its job regardless of the web application's sign out or timeout issues. The client is a .aspx page which uploads the data file to server and then triggers the independent process in the server. I want to implement this in ASP.NET, VB.NET, VS 2003.
What is the best way to do this?
Thank you!
Have you considered just writing a service that monitors the file drop location that your aspx uploads the file to? In your aspx you could add the logic to interrogate the file to make sure it is valid. Once the interrogation has passed you drop the file to a predetermined location.
The service, that you will have to create, just monitors the file drop location for new files and processes them as they come in. Being a service you don't have to worry about timeouts any asp.net related issues.
http://msdn.microsoft.com/es-es/library/ms227433(v=VS.80).aspx
The interface exists in .net 1.1: http://msdn.microsoft.com/en-us/library/system.web.ihttpasynchandler(v=VS.71).aspx
Cheers.
精彩评论