@Override
  @SuppressWarnings("unchecked")
  public byte[] serializeResource(R resource) {
    checkNotNull(resource);
    return kryoSerialize.serializeResource(resource);
  }
JavaSerializer Use KryoSerialize to serialize/deserialize java objects

@param <R>
amoro-common/src/main/java/org/apache/amoro/serialization/JavaSerializer.java