Changeset 5388 for CMDIValidator


Ignore:
Timestamp:
06/26/14 09:18:54 (10 years ago)
Author:
Oliver Schonefeld
Message:
  • handle unexpected exceptions more gracefully
Location:
CMDIValidator/trunk/cmdi-validator-core/src/main/java/eu/clarin/cmdi/validator
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • CMDIValidator/trunk/cmdi-validator-core/src/main/java/eu/clarin/cmdi/validator/CMDIValidator.java

    r5384 r5388  
    264264
    265265            return done;
    266         } catch (CMDIValidatorException e) {
     266        } catch (Throwable e) {
    267267            synchronized (this) {
    268268                state = State.DONE;
     
    271271                }
    272272            } // synchronized (this)
    273             throw e;
     273            if (e instanceof CMDIValidatorException) {
     274                throw (CMDIValidatorException) e;
     275            } else {
     276                throw new CMDIValidatorException(
     277                        "an unexpected error occured", e);
     278            }
    274279        } finally {
    275280            if (threadsProcessing.decrementAndGet() <= 0) {
  • CMDIValidator/trunk/cmdi-validator-core/src/main/java/eu/clarin/cmdi/validator/ThreadedCMDIValidatorProcessor.java

    r5384 r5388  
    163163                /* IGNORE */
    164164            } catch (Throwable e) {
    165                 logger.error("unexpected error in worker thread: {}",
    166                         e.getMessage(), e);
     165                logger.error("unexpected exception in worker thread", e);
    167166            }
    168167        }
Note: See TracChangeset for help on using the changeset viewer.