I have the following classes:
public class Document {
public String id;
public String date;
public Map<String, Keyword> keywords = new HashMap<>();
}
public class Keyword {
public String word;
public Map<String, Document> docs = new HashMap<>();
}
I want to serialize the keywords
HashMap in order to save it in Redis.
I tried this but it throws an error:
java.io.NotSerializableException:keyword