add JPA database, upgrade Memory-base to write and load file