Tidied up exception listener, exception wrapper implemented, added constraint violation exception.