if (!hazard && heuristicResources.size() == totalResourceCount)
throw new BitronixHeuristicRollbackException(message + ":" +
" all resource(s) " + Decoder.collectResourcesNames(heuristicResources) +
" improperly unilaterally rolled back", phaseException);
else
throw new BitronixHeuristicMixedException(message + ":" +
(errorResources.size() > 0 ? " resource(s) " + Decoder.collectResourcesNames(errorResources) + " threw unexpected exception" : "") +
(errorResources.size() > 0 && heuristicResources.size() > 0 ? " and" : "") +
(heuristicResources.size() > 0 ? " resource(s) " + Decoder.collectResourcesNames(heuristicResources) + " improperly unilaterally rolled back" + (hazard ? " (or hazard happened)" : "") : ""), phaseException);
}