Throw exception on invalid configuration