wrap component initialization in exception handler.