null exception fixed
not necessary to throw an exception as container is anyhow closed. logging is enough