three-tier exception handling