Lazy loading not working in JPA with hibernate
I am using JPA with hibernate in my spring boot application. Whenever I try to fetch the enities using jpa methods, its returning the entity plus all the association present inside it. I wanted to fetch the associated entities on demand(lazy loading), so I have provided fetch=FetchType.LAZY in my domain class. But still its returning all the entries. Below is the code: Case.java @Entity @Table(name="smss_case") public class Case implements Serializable { /** * */ private static final long serialVersionUID = -2608745044895898119L; @Id @Column(name = "case_id", nullable = false) @GeneratedValue