PC Review


Reply
Thread Tools Rate Thread

Delagate vs. BackGroundWorker vs. Web Service

 
 
=?Utf-8?B?ZGJhMTIz?=
Guest
Posts: n/a
 
      26th Jul 2006
Do I :

1) use a Delegate which calls my method below (the method below is using the
EnterpriseLibrary.Data namespace for 2.0)

or

2) Use some sort of implementation of BackGroundWorker
(http://www.devx.com/dotnet/Article/22358/1954?pf=true) in
System.ComponentModel to perform a call to my method asynchronously?

3) Create a web service then execute the method using the web service and a
delagate

Also, how can I check if it is running asynchronously after I implement
either 1 or 2; what methods can I use to test after I figure this out?

This is for a public website, about 1.5 million users hit it per day, and
we'll be doing a ton of inserts per minute or even second for a specific
process which this method will help in.

Currently this method takes an incoming Search String, calls my stored proc,
and inserts stuff into my table via the defined parameters. I'm using
methods from Enterprise Library 2.0 to perform the insert and we want to keep
it that way. I just need to know how to call this asynchronously. I am a
beginner in this so be easy on me and explain. Thanks for any help!!!!

public static void InsertSearchTerm(string SearchTerm)
{
DateTime CreateDate = DateTime.Now;
Int32 ResultCount = 1;

try
{

DatabaseFactory.CreateDatabase().ExecuteNonQuery("insert_storedproc_name",
SearchTerm, ResultCount, CreateDate);
}
catch
{
throw;
}

Or do I use a web service and things like IAsyncState
--
dba123
--
dba123
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help on delagate strange behaviour ??? =?Utf-8?B?Y2FsZGVyYXJh?= Microsoft Dot NET 8 11th Sep 2007 08:20 PM
Callbacks, delagate anilkoli@gmail.com Microsoft VB .NET 0 31st Mar 2006 08:05 AM
about delagate signature and parameters # Cyrille37 # Microsoft C# .NET 3 1st Mar 2006 10:36 AM
backgroundworker in windows service or console application =?Utf-8?B?TWljaGVsIE1lZXg=?= Microsoft Dot NET Framework 7 25th Oct 2005 03:36 PM
COM Add-in and Delagate Access To Inbox Frank Perugini Microsoft Outlook Program Addins 1 6th Feb 2004 10:32 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:14 PM.