I have got two java objects with byte[]
field of the size of the order of millions. What is the fastest and efficient way to check Deep Equal for these java objects?
Sample Entity:
@Entity
public class NormalBook
{
@Id
private String bookId;
@Column
private String title;
@Column
private byte[] pdfFile;
//setters and getters
}
Note: I am doing it for an ORM tool basically I am checking an object (which is in managed state) with an object present in Persistence Context.