WSTrace

You define the WSTrace attribute for debugging purposes.

Syntax

WSTrace

Usage

You use this attribute to specify the action of the HTTP TRACE verb for debugging purposes. You set the WSTrace attribute in the ATTRIBUTES() clause of the function.

Example using WSTrace

PUBLIC FUNCTION TraceServer()
   ATTRIBUTE(WSTrace, 
             WSPath = '/*')
   RETURNS(STRING ATTRIBUTE(WSHeader, 
                            WSName = "Debug"))
   DEFINE echoTrace STRING

   #... function code ...

   RETURN echoTrace
 END FUNCTION 

In this example the REST function returns a trace. This can help identify bugs in your code.