Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
7 Views

multi-thread enabled product

We have created some classes for upload and download which inherits from backgroundworker class. There are a list of files which are to be uploaded and downloaded and pass the same to our respective classes.

Since the classes inherit from background worker class, both the instances(for Upload and Download) run on a seperate thread.

While scheduling the upload / download jobs a Schedular is used for this task.

Schedular is a different project (Window Service) and is also executed on different thread. Schedular class checkes for the list of schedules needed to be run and create a file list accordingly for each schedule.

Each schedule runs on a different thread as we execute an exe with the help of ProcessStartInfo class

Would this tool qualify as a Multi-threaded product ?

0 Kudos
3 Replies
Highlighted
Employee
7 Views

I'm not sureof the definition of amulti-threaded application, but I am sure of the definition of a succesfully multi-threaded application. An application is successfully multi-threaded if it shows speedup when run on a multi-core processor compared to a single-core processor. I like this definition because it is based on observable behavior, not internal structure of the program. There are of course programs that have multiple threads internally, but exhibit slowdown on multi-core processors. I'd call that failed multi-threading. (I've done my share of that too.)

0 Kudos
Highlighted
Black Belt
7 Views

I'll go out on a limb and say that I do know how to define a multithreaded application. For me, this is an application that spawns one or more additional threads within the process. These threads share the resources of the process without any special API needed.

You can fork off processes from with a process. This is what I call a multi-process application. Things can be shared between processes, but that would take special set up and/or API calls. Running multiple copies of the same application, with different input data sets, would also be considered a multi-process execution. While both may appear the same to the user, the programming of each model is different.

It is possible to achieve speedup with multiple processes. For example, if it takes 4 minutes to run an application, running two of these apps, one after the other on a serial processor, would take 8 minutes. If I run the two copies of the app on a dual core laptop and both finish in 6 minutes, I have achieved a 1.5X speedup. (Unless there was some contention for resources other than the CPU, I would hope to get an execution time closer to 4 minutes.)

--clay

0 Kudos
Highlighted
Valued Contributor II
7 Views

Actually, 8/6 = 1.3333x speedup, not 1.5

--Robert

0 Kudos