error handling in server main and cbr