on 10-02-2009 3:49 PM
Hi I would like to know how to use logging within a java mapping.
I know i have to use theese classes : Location, Category, ConsoleLog but i dont know how.
1) How to load the P1, P2, P3 and P4 tags in the Error tag of the SOAP header watched in SXMB_MONI
- <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
<SAP:Category>Application</SAP:Category>
<SAP:Code area="MAPPING">STREAM_TRANSFORMATION_EX</SAP:Code>
<SAP:P1>SwissMedical/Interfaces/IFI002/LiquidacionMapping~</SAP:P1>
<SAP:P2 />
<SAP:P3 />
<SAP:P4 />
<SAP:AdditionalText />
<SAP:ApplicationFaultMessage namespace="" />
<SAP:Stack>Java mapping of application triggered an exception</SAP:Stack>
<SAP:Retry>M</SAP:Retry>
</SAP:Error>
2) How to load and activate log in the DIAGNOSTIC tag of the SOAP Header.
- <SAP:Diagnostic xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
<SAP:TraceLevel>Information</SAP:TraceLevel>
<SAP:Logging>Off</SAP:Logging>
</SAP:Diagnostic>
Thanks!!
As already suggested, you can display custom messages using AbstractTrace.
trace = (AbstractTrace)param.get( StreamTransformationConstants.MAPPING_TRACE );
trace.addInfo("G1-CYCLE is missing");
For more on coding front refer:
http://help.sap.com/javadocs/NW04/current/pi/com/sap/aii/mapping/api/StreamTransformation.html
To get this trace seen in MONI, set parameter TRACE_LEVEL in SXMB_ADM to 2.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Mariano,
Please refer to OSS note # 1090753 - Creation of logs for WebChannel/E-Commerce applications
https://service.sap.com/sap/support/notes/1090753
including the attached PDF which explains logging.
Hope this answers your question.
Regards,
Rasmus
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I don't think you can use com.sap.tc.logging in Java mapping.
Use AbstractTrace instead.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.