How to generate trace output for the Commerce Server Adapters
Tracing for the Commerce Server Adapters are a little different than the rest of the Commerce Server systems. With the adapters, you will trace on a per endpoint basis, where endpoint is either a Send or Receive Port.
Here are the steps:
- First, open the Registry and go to the Registry Subkey that you configured for the endpoint. This can be found in: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Commerce Server 2007 BizTalk Adapters\<Adapter type>\<RegistrySubkey>\ or HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Commerce Server 2007 BizTalk Adapters\<Adapter type>\<RegistrySubkey>\ if running on a 64 bit machine (as a 32 bit process).
- Copy the Trace Guid value, you will us this in the trace command.
- Open a command prompt and go to the <Commerce Server Root Directory>\Support directory.
- Enter: tracelog -start AdapterTrace -f AdapterTrace.log -guid #<Trace GUID HERE> -flags 0x7f
- Enable the endpoint (or submit a message) to generate trace data.
- When you are ready to stop the trace, execute: tracelog -stop AdapterTrace
- Then Format: tracefmt AdapterTrace.log -tmf TraceFormat\CSTraceEvents.tmf
That's it, it's as simple as that! I hope this helps with Adapter debugging!
-Alan