Github user selvaganesang commented on a diff in the pull request:
https://github.com/apache/incubator-trafodion/pull/885#discussion_r93672871
--- Diff: core/sqf/src/seatrans/tm/hbasetmlib2/javaobjectinterfacetm.cpp ---
@@ -478,3 +514,23 @@ void
JavaObjectInterfaceTM::appendExceptionMessages(JNIEnv *jenv, jthrowable a_e
jenv->DeleteLocalRef(a_exception);
}
+short JavaObjectInterfaceTM::getExceptionErrorCode(JNIEnv *jenv,
jthrowable a_exception)
+{
+ jshort errCode = JOI_OK;
+ if(a_exception != NULL)
+ {
+ //Check to see if this exception has getErrorCode method.
+ //Only custom subclasses have errorcode defined.
--- End diff --
Consider caching the methodId or it is an expensive way to get the error
code. Is this method called only when error is present
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---