Changes from preetigupta152/johm -
Added catch block that returns broken resource in case of Exception.
Fixed exception handling.