|
|
|
|
|
Total Hits: 3 | Today: 0
|
Author: Jeffrey Richter
|
Rating:
|
|

By far, the most common use of thread synchronization is to ensure mutually exclusive access to a shared resource by multiple threads. In the Win32® API, the CRITICAL_SECTION structure and associated functions offers the fastest and most efficient way to synchronize threads for mutually exclusive access when the threads are all running in a single process. The Microsoft® .NET Framework doesn't expose a CRITICAL_SECTION structure, but it does offer a similar mechanism allowing mutually exclusive ...
|
|
|
|
Total Hits: 5 | Today: 0
|
Author: Jeffrey Richter
|
Rating:
|
|

In my last column, I showed the various thread synchronization mechanisms employed by the Microsoft® .NET Framework (see Concurrent Affairs: Performance-Conscious Thread Synchronization). I then examined the performance characteristics of all these mechanisms and determined that the Interlocked methods performed the best because the calling thread never has to transition to kernel mode. I then looked at how to build some simple locks using the Interlocked methods....
|
|
|
|
Total Hits: 4 | Today: 0
|
Author: James McCaffrey
|
Rating:
|
|

Stress testing is a fundamental quality assurance activity that should be part of every significant software testing effort. The key idea behind stress testing is simple: instead of running manual or automated tests under normal conditions, you run your tests under conditions of reduced machine or system resources. The resources to be stressed generally include internal memory, CPU availability, disk space, and network bandwith. To reduce these resources for testing you can run a tool called a s...
|
|
|
|
Total Hits: 4 | Today: 0
|
Author: Dr. James McCaffrey
|
Rating:
|
|

Creating and using random test case data is an essential software testing skill. Although most test case data consists of specific inputs to the system under test and specific expected values/states, you will almost always want to subject your system to random test case inputs, too. Typically you do this to see if you can cause a crash or evoke an exception by throwing a large variety of inputs at the application. In this month's column, I'll explain four common tasks when dealing with random te...
|
|
|
|
Total Hits: 4 | Today: 0
|
Author: Dr. James McCaffrey
|
Rating:
|
|

One of the first things that developers new to the Microsoft .NET Framework learn is how to read from and write to text files using methods from the FileStream class of the System.IO namespace. However, the .NET I/O stream model also provides developers with a powerful way to create custom stream classes. In this month's column, I'll explain key techniques you can use to test such custom stream classes-and specifically those that deal with transforming data read from or written to another stream...
|
|
|
|
Total Hits: 4 | Today: 0
|
Author: James Avery
|
Rating:
|
|

Unit testing has gradually moved from a fringe technology to standard practice on many Microsoft® .NET Framework projects. Many .NET developers have at least some experience working with nUnit, the predominant unit-testing framework for .NET. While nUnit covers most required scenarios for unit testing .NET applications, you can take unit testing to the next level with MbUnit 2.4. MbUnit is an open-source unit-testing framework started by Jonathan "Peli" de Halleux (who has since gone on to work ...
|
|
|
|
Total Hits: 4 | Today: 0
|
Author: Stephen Toub
|
Rating:
|
|

In my application, I'm encrypting and compressing quite a bit of data. As these are computationally intensive operations, I was expecting to see 100 percent CPU utilization in Task Manager, but I noticed that on my dual-core machine, it's topping out at around 50 percent. I'm assuming this is because only one core is being used, which is a shame given that the process takes a non-trivial amount of time to run. Is there any way I can get this encryption and compression process to use both process...
|
|
|
|
Total Hits: 12 | Today: 0
|
Author: Malli_S
|
Rating:
|
|

A few months ago, one of my colleagues was using a tool that was managing multiple desktops. I was wondering how the tool could manage multiple desktops. I thought it would be just hiding-and-displaying the application windows for different desktops when a user switches between them. As a matter of curiosity, I started studying multiple desktops and ended up with this article....
|
|
|
|
Total Hits: 10 | Today: 0
|
Author: Microsoft Corporation
|
Rating:
|
|

When you edit markup in Source view of the Visual Studio Web designer, the editor continually checks that the markup you are creating is valid. Markup validation works like the spelling checker in a word processing program. The editor examines the markup and adds wavy red lines under the elements or attributes that are not valid....
|
|
|
|
Total Hits: 19 | Today: 0
|
Author: JasonShort
|
Rating:
|
|

Everyone knows that any app driven by data is much more than just the app. In most cases the app without a database doesn’t even function, or fails to function properly. If a database is an integral part of your application, then shouldn’t you be doing all you can to ensure it stays healthy and prepare for the worst case events of corruption or dead drives?
This week we have been contacted by 5 long time users who suddenly lost or corrupted their data. Two of these were end user data t...
|
|
|
|
Total Hits: 21 | Today: 0
|
Author: slelong
|
Rating:
|
|

This article is about a USB library which enables you to manage Attach and Detach events of USB devices and detect your own device. I was not able to find a working code written in C# and which runs under both Windows XP and Windows 7 x64. I therefore decided to write my own code. I read various articles about USB Attach and Detach detection, and got some help from both the Microsoft website and the PINVOKE.NET website (http://www.pinvoke.net)....
|
|
|
|
Total Hits: 14 | Today: 0
|
Author: noorani_786
|
Rating:
|
|

Imagine the following (which you’ve very likely run into in the past):
You join a new company and inherit a humongous existing code base. You are told to add some new functionalities without of course breaking existing functionality. “No problem”, you say! “I’ve done this before.”...
|
|
|
|
|
|