|Home • Trainings • Quiz • Tips • Tutorials • Functional • Cert Q's • Interview Q's • Jobs • Testimonials • Advertise • Contact Us|
Handling and Tracing Runtime Exceptions in Java Mapping
By Prasanna Krishna Mynam, Yash Technologies
problem recently we have come across was handling runtime exceptions while
implementing java mapping program to map and validate source EDI messages to
target. Since we develop our java mapping in external IDE (like NWDS, eclipse)
and use it as mapping program, but the exceptions raised during mapping are not
caught unless we handle it explicitly also provide message trace in SXMB_MONI.
We need to
get the source EDI message, validate it and map to the target structure. While
validating the time we need to throw runtime exceptions with specific message,
provide message trace in SXMB_MONI to find where exactly the validation failed
mapping, the exceptions raised in java program are not caught and also it became
difficult to trace in SXMB_MONI for any kind of messages.
= (AbstractTrace) param.get (
Throws NullPointerException while executing in NWDS.
while mapping, the exceptions raised are of type StreamTransformationException,
in our java program we need to throw this exception explicitly using the
following statement in catch block.
order to provide message trace with any fields from our program in SXMB_MONI, we
need to use MessageTrace/AbstractTrace.
using these in NWDS causes NullPointerException as we need to call the setParameter method
explicitly.Mapping frame calls this methods implicitly, we need not to worry
about this Exception and we can use our mapping program in our mapping .
Steps while programming:
Raised While Testing Mapping
Message Trace in SXMB_MONI
Please send us your feedback/suggestions at webmaster@SAPTechnical.COM
©2006-2007 SAPTechnical.COM. All rights reserved.
product names are trademarks of their respective companies. SAPTechnical.COM
is in no way affiliated with SAP AG.
Graphic Design by Round the Bend Wizards