Oracle Waveset 8.1.1 Deployment Reference

Testing Expressions

Testing expressions involves two steps:

Checking Expression Syntax with lh Command

ProcedureTo Check the Syntax of an Expression

  1. Confirm that you have %WSHOME%\bin in your PATH environment variable. (For information on changing environment variables to work with Waveset, see the section of Installation Guide that describes using command-line tools.)

    If %WSHOME%\bin is not in your path, then you must change to %WSHOME%\bin before you can run the tools.

  2. From the command line, enter lh xmlparse <xpress_file> where xpress_file represents the name of the file that contains the XML you want to test. This command parses the file for XML correctness and displays error messages in the console.


    Note –

    Consider putting %WSHOME%\bin in your PATH environment variable. This will permit you to use whichever directory you are currently in as your working directory. This will also allow you to run the Waveset lh command from any current working directory.


Tracing XPRESS Evaluation

Once you have written and successfully stored an expression in the repository, you can turn on XPRESS tracing to determine if the expression is functioning correctly. XPRESS trace messages are sent to the standard output device. Since XPRESS is typically evaluated within the application server, the trace messages are sent to the console window or log file that was active when the application server was started.

There are two forms of XPRESS tracing:

Typically, block-level tracing is preferable because it reduces the amount of trace output, which is then easier to analyze.

Enabling Tracing

To enable global trace, set a Waveset.properties file entry named xpress.trace to the value true. If you change the Waveset.properties file while the application server is running, you must either restart the application server, or go to the Debug Page and click Reload Properties.

To perform block-level trace, wrap the expressions you want to trace in a <block> expression and include the attribute trace=’true’ in the block start tag.

<block trace=’true’>
   <invoke name=’getTime’ class=’java.util.Date’/>
</block>

or

<Default>
   <block trace = ’true’>
      <ref>global.accountId</ref>
   </block>
</Default>

Invalid Examples

Do not use the <block> element in the following ways.

<block trace=’true’>
   <Field name =’field1’>
…
   </Field>
</block>

or

<Field name=’Field2’>
   <block trace=’true’>
      <Default>
         <ref>global.accounts</ref>
      </Default>
   </block>
</Field>

The trace messages include the names of the functions, the values of each argument, and the return values.

To turn tracing off for XPRESS, set the xpress.trace value to false, and reload the Waveset.properties file.