Handling exceptions in Oracle DB stored Java classes -
when stored java class hits , unhandled exception, what best way total stack trace pl/sql proper logging?
during preliminary tests of class, nail nullpointer, oracle displayed unhandled java exception. info had was nullpointer - no hint in code.
obviously should able avoid exceptions rigorous validation of client-provided info , unit tests, in event happens?
i thinking of catching exceptions, storing stacktrace in array , returning array plsql... i'd rather avoid need manage these additional homecoming values.
there on that, unfortunately google-fu has failed me...
you can finish stacktrace , convert them string , pass pl/sql logging. got simple solution converting stacktrace string question here
stringwriter sw = new stringwriter(); printwriter pw = new printwriter(sw); t.printstacktrace(pw); string stacktrace = sw.tostring(); // send pl/sql java exception-handling oracle11g java-stored-procedures
No comments:
Post a Comment