Calling LoadGen from BizUnit

Sep 10, 2008 at 10:34 PM
I'm trying to create load tests for a BizTalk environment and I'm running in to some issues getting LoadGen to run properly from BizUnit.  I've tried running the tests using both NUnit and Visual Studio 2008 Team Test and I'm getting the same event log errors from both.  The error I'm getting is:

Event Type:    Error
Event Source:    LoadGen::NormalSectionThread
Event Category:    None
Event ID:    0
Date:        9/10/2008
Time:        2:08:31 PM
User:        N/A
Computer:    CMCCAIN
Description:
Start() Section [FileSection] encountered the following exception!System.NullReferenceException: Object reference not set to an instance of an object.
   at LoadGen.NormalSectionThread.Start()

along with:

Event Type:    Error
Event Source:    LoadGen:GenericSectionThread
Event Category:    None
Event ID:    0
Date:        9/10/2008
Time:        3:23:33 PM
User:        N/A
Computer:    CMCCAIN
Description:
Cannot Load Transport DLL C:\Program Files\NUnit 2.4.7\bin\FileTransport.dll for Section FileSection
Could not load file or assembly 'file:///C:\Program Files\NUnit 2.4.7\bin\FileTransport.dll' or one of its dependencies. The system cannot find the file specified.


All I'm trying to do is call a basic file creation LoadGen script from BizUnit.  Here is the BizUnit test case to call loadgen I am using:

        <TestStep assemblyPath="" typeName="BizUnit.LoadGenSteps.LoadGenExecuteStep, BizUnit.LoadGenSteps, Version=3.0.0.0, Culture=neutral, PublicKeyToken=7eb7d82981ae5162">
            <LoadGenTestConfig>C:\Amphire\Exchange\Test\LoadGen\PO\CustomMC.xml</LoadGenTestConfig>
        </TestStep>

The console output is showing the LoadGen is getting called and starting to run properly, but files are not being dropped and the event log error is showing up in the Errors and Failures section.

Step: BizUnit.LoadGenSteps.LoadGenExecuteStep, BizUnit.LoadGenSteps, Version=3.0.0.0, Culture=neutral, PublicKeyToken=7eb7d82981ae5162 started @ 15:30:12.740 10/09/2008, failOnError = True
Info: About to execute LoadGen script: C:\Amphire\Exchange\Test\LoadGen\PO\CustomMC.xml

LoadGen Started at 9/10/2008 3:30:12 PM
FileSection has Started
CONTROLLER STARTED

FileSection : Section being Stopped
FileSection : Signalled Threads to Stop
FileSection : Cleanup Completed
CONTROLLER STOPPED

Info: FilesSent: 0
Info: StartTime: 9/10/2008 3:30:12 PM
Info: StopTime:  9/10/2008 3:30:13 PM
Info: DeltaTime: 1.0156445Secs.
Info: Rate:      0
Step: BizUnit.LoadGenSteps.LoadGenExecuteStep, BizUnit.LoadGenSteps, Version=3.0.0.0, Culture=neutral, PublicKeyToken=7eb7d82981ae5162 ended @ 15:30:19.787 10/09/2008

I've looked at the MSDN documentation on how to supposedly get this working, but this is what I get when I followed it.

Can someone point out if I'm doing something wrong, or if there is something in particular I need to add to my .cs for this to function properly?

Thanks,

Conlyn
Sep 22, 2008 at 5:37 PM
After fighting with this for a couple of weeks, I think I've figured this issue out.

First off, you must use LoadGen 2004 instead of the newest one, 2007.  The reason for that is you must add the LoadGen.dll to the GAC, and the 2007 version isn't "strong named" so it won't add.  I believe that the LoadGen.dll is the only one that needs to be added as it is the actual one that is called from BizUnit (but I could be mistaken).

Second is you must put the full path the assemblies that are being used in the LoadGen scripts.  So the File Transport section should look something like this:
<Section Name="FileSection">
    <Transport Name="FILE">
      <Assembly>C:\Program Files\LoadGen\Bins\FileTransport.dll/FileTransport.FileTransport</Assembly>
    </Transport>

That is what was causing the even log errors I was getting above.

Now that the basics of LoadGen work from BizUnit, I'd like to find a way to get the WCF generators that LoadGen 2007 has working.  Anyone have any ideas on that front?

-Conlyn