@Override
    public boolean equals(Object obj) {
      if (this == obj) {
        return true;
      }
      if (obj == null) {
        return false;
      }
      if (getClass() != obj.getClass()) {
        return false;
      }
      BigHolder other = (BigHolder) obj;
      if (bd == null) {
        if (other.bd != null) {
          return false;
        }
      } else if (!bd.equals(other.bd)) {
        return false;
      }
      if (bi == null) {
        return other.bi == null;
      } else
        return bi.equals(other.bi);
    }
A serializable with a writeReplace method should use standard serialization.
geode-core/src/integrationTest/java/org/apache/geode/pdx/AutoSerializableJUnitTest.java