You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In HibernateClinic (org.springframework.samples.petclinic.hibernate) we're using @Autowired field injection right now. This should be changed to use constructor injection. We promote the use of constructor injection all over the place and also not doing field injection in your business logic and this is precisely what we're doing here...
Attaching a patch. Not tested (can't get the workspace up and running right now, so please test before committing).
Alef Arendsen opened SPR-5326 and commented
In HibernateClinic (org.springframework.samples.petclinic.hibernate) we're using
@Autowired
field injection right now. This should be changed to use constructor injection. We promote the use of constructor injection all over the place and also not doing field injection in your business logic and this is precisely what we're doing here...Attaching a patch. Not tested (can't get the workspace up and running right now, so please test before committing).
Affects: 2.5.6
Attachments:
Referenced from: commits fe31de5
The text was updated successfully, but these errors were encountered: