Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27517

VS 2012 Parallel Task Library and WCF

$
0
0
Hi,

I'm currently planning a new project which requires the development of a Windows Service that will run as the Application Server. Since I've never developped a Windows Service, I want to make sure I'm selecting the correct tools to do the job. If I'm talking nonsense here, the egg is firmly in my face :)

The Service will have the following functionality:

  • periodically perform tasks like checking for new files on an ftp server, database updates and maintenance

  • on-demand tasks like generating pdf-files, sending emails etc.


As this is a whole new project, I'm not bound to any architectural restrictions or platform (other than it being VB.NET).

For the first function, I was looking into .NET 4.5 Parallel Tasks Library and use that in combination with the
System.Timers.Timer class.

Consider this real-world example: The service checks every minute if new files are present on an ftp server.
Typically, this is would be done by System.Timers.Timer. However, I would like to have the processing of those files
done by Parallel Tasks (Basically, generate a task for each file present).

Would this be a correct approach? That way, the total processing time would (almost) never exceed the interval time
and this would make better use of the multi-core CPU on the server.


For the 2nd function, I was looking at WCF. As I am a complete WCF-newbie, I would appreciate some guidance
into how to implement a WCF-based service (possibly combined with the Parallel Library).
For example, is each request sent to a WCF-service run in a separate thread? How do I make a request from a client?

Any links to some VB-based tutorials on either subject are also very much appreciated.

Viewing all articles
Browse latest Browse all 27517

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>