Question: what is the difference between save and saveandflush?
Answer: Difference between Save and SaveAndFlush in Spring Java. ... They both are both belong to the Spring data library. save may or may not write your changes to the DB straight away. When we call saveAndFlush system are enforcing the synchronization of your model state with the DB.