protected void onUnhandledException ( WebURL webUrl , Throwable e ) { if ( myController . getConfig ( ) . isHaltOnError ( ) && ! ( e instanceof IOException ) ) { throw new RuntimeException ( "unhandled exception" , e ) ; } else { String urlStr = ( webUrl == null ? "NULL" : webUrl . getURL ( ) ) ; logger . warn ( "Unhandled exception while fetching {}: {}" , urlStr , e . getMessage ( ) ) ; logger . info ( "Stacktrace: " , e ) ; // Do nothing by default (except basic logging) // Sub-classed can override this to add their custom functionality } }
This function is called when a unhandled exception was encountered during fetching