This project has moved. For the latest updates, please go here.

Does this support net.msmq?

Aug 31, 2009 at 10:44 AM

Hi,

I have a service using net.msmq and when I load the WCF trace file I get "Trace did not contain any calls to WCF".

I have followed all the steps in the Usage Notes so I am wondering if this is a fundamental problem?

I tried generating the trace from the client and the service and loading each but they gave the same error.

Below is the XML message from the Trace file.

  Thanks, Vin

 

<E2ETraceEvent xmlns="http://schemas.microsoft.com/2004/06/E2ETraceEvent">
  <System xmlns="http://schemas.microsoft.com/2004/06/windows/eventlog/system">
    <EventID>0</EventID>
    <Type>3</Type>
    <SubType Name="Information">0</SubType>
    <Level>8</Level>
    <TimeCreated SystemTime="2009-08-31T10:06:50.4514284Z" />
    <Source Name="System.ServiceModel.MessageLogging" />
    <Correlation ActivityID="{00000000-0000-0000-0000-000000000000}" />
    <Execution ProcessName="w3wp" ProcessID="1516" ThreadID="6" />
    <Channel />
    <Computer>WEEDDEV002</Computer>
  </System>
  <ApplicationData>
    <TraceData>
      <DataItem>
        <MessageLogTraceRecord Time="2009-08-31T11:06:50.4484278+01:00" Source="ServiceLevelReceiveDatagram" Type="System.ServiceModel.Channels.BufferedMessage" xmlns="http://schemas.microsoft.com/2004/06/ServiceModel/Management/MessageTrace">
          <s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://www.w3.org/2005/08/addressing">
          <s:Header>
            <a:Action s:mustUnderstand="1">http://tempuri.org/IService1/SetMessage</a:Action>
            <VsDebuggerCausalityData xmlns="http://schemas.microsoft.com/vstudio/diagnostics/servicemodelsink">uIDPowlqxk/TC51AnaQ5ezi+PJoAAAAAO4OuSDAVJUm6ofCxnhSbKpye4xbBvZpGqOpMNUwzgg8ACQAA</VsDebuggerCausalityData>
            <a:To s:mustUnderstand="1">net.msmq://localhost/private/MessagingService/Service1.svc</a:To>
          </s:Header>
          <s:Body>
            <SetMessage xmlns="http://tempuri.org/">
              <composite xmlns:b="http://schemas.datacontract.org/2004/07/MessagingService" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
                <b:Content>Test <span style="color: #ff0000; font-size: 36pt; font-weight: bold; text-decoration: underline">Me</span></b:Content>
                <b:Created>2009-08-31T11:06:47.9259234+01:00</b:Created>
                  <b:Id>128961868079249232</b:Id>
                  <b:RecipientId>999</b:RecipientId>
                  <b:SenderId>666</b:SenderId>
                  <b:Subject>Trace testnet.msmq://localhost/private/MessagingService/Service1.svc</b:Subject>
                </composite>
              </SetMessage>
            </s:Body>
          </s:Envelope>
        </MessageLogTraceRecord>
      </DataItem>
    </TraceData>
  </ApplicationData>
</E2ETraceEvent>

 

 

Coordinator
Sep 4, 2009 at 7:24 AM

Apologies for the delay in replying.

At the moment the tool does not recognise one-way contracts, but there is an easy workaround, just edit the message log file and do a global search and replace for "ServiceLevelReceiveDatagram" and replace it with "ServiceLevelReceiveRequest", treating the resulting file as a service side log file.

Regards

Rob

Sep 4, 2009 at 9:17 AM

Thanks for that, it loads the log file now and I can generate the tests but I can't run them.

 

If I try and run the WCF test (not the load test) I get the following error:

Initialization method WCFTest1.WCFTest1Tests.InitializeTest threw exception. System.InvalidOperationException:  System.InvalidOperationException: The Address property on ChannelFactory.Endpoint was null.  The ChannelFactory's Endpoint must have a valid Address specified..

I had named my endpoint so I went into the .Custom.cs file and chaneged the line

System.ServiceModel.ChannelFactory<MessagingService.IService1> service1Factory = new System.ServiceModel.ChannelFactory<MessagingService.IService1>();

to

System.ServiceModel.ChannelFactory<MessagingService.IService1> service1Factory = new System.ServiceModel.ChannelFactory<MessagingService.IService1>("msmq"); 

this just changes the error text slightly to this:

Initialization method WCFTest1.WCFTest1Tests.InitializeTest threw exception. System.InvalidOperationException:  System.InvalidOperationException: Could not find endpoint element with name 'msmq' and contract 'MessagingService.IService1' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this name could be found in the client element..

I also remvoed the name property from the config and it didn't help.

I have followed the instruction in the Usage doc that says you "Run unit tests in application domain property to true" and that is done, I also tries the other config names it mentions ( and ) and even Web.config.

Running the load test will just give me the same error multiple times.

 

Any idea what might be wrong?

Should I, maybe, post this as a new question since you have answered the one I asked in the subject?

  Thanks, Vin

 

Coordinator
Sep 4, 2009 at 10:00 AM

Have you named the config file app.config in the test project?

Regards

Rob

Sep 4, 2009 at 10:02 AM

Yep.

And it does end up in the bin\Debug folder as TestProject1.dll.config

  Vin

Coordinator
Sep 4, 2009 at 10:22 AM

In that case I am not sure what to suggest, it is not a problem specific to the tool at this point, but if you want to send me the solution I don't mind taking a quick look. To do so you need to contact me via the Contacts page.

Regards

Rob

Sep 4, 2009 at 10:47 AM

I'll remove as many dependences as I can and send it on.

  Thanks, Vin