@Transactional
  public synchronized void removeUser(User user) throws AmbariException {
    UserEntity userEntity = userDAO.findByPK(user.getUserId());
    if (userEntity != null) {
      removeUser(userEntity);
    } else {
      throw new AmbariException("User " + user + " doesn't exist");
    }
  }
Removes a user from the Ambari database.
<p>
It is expected that the associated user authentication records are removed by this operation
as well.

@param user the user to remove
@throws AmbariException
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java