@Override
  public boolean equals(Object obj) {
    if (!(obj instanceof MpackRequest)) {
      return false;
    }
    if (this == obj) {
      return true;
    }
    MpackRequest mpackRequest = (MpackRequest) obj;

    if (id == null) {
      if (mpackRequest.id != null) {
        return false;
      }
    } else if (!id.equals(mpackRequest.id)) {
      return false;
    }

    if (mpackName == null) {
      if (mpackRequest.mpackName != null) {
        return false;
      }
    } else if (!mpackName.equals(mpackRequest.mpackName)) {
      return false;
    }

    if (mpackUri == null) {
      if (mpackRequest.mpackUri != null) {
        return false;
      }
    } else if (!mpackUri.equals(mpackRequest.mpackUri)) {
      return false;
    }

    if (registryId == null) {
      if (mpackRequest.registryId != null) {
        return false;
      }
    } else if (!registryId.equals(mpackRequest.registryId)) {
      return false;
    }

    if (mpackVersion == null) {
      if (mpackRequest.mpackVersion != null) {
        return false;
      }
    } else if (!mpackVersion.equals(mpackRequest.mpackVersion)) {
      return false;
    }

    return true;
  }
The {@link MpackRequest} encapsulates the data necessary to make a
backend request for {@link MpackEntity}.
ambari-server/src/main/java/org/apache/ambari/server/controller/MpackRequest.java