Using singleton scope for stateful beans. Frame the concept in practical terms so you can explain it during interview discussion.
A common mistake in Spring is using the singleton scope for stateful beans, which can lead to data inconsistency and concurrency issues, as all requests share the same bean instance. Stateful beans, such as those managing user sessions, should use the appropriate scope, like prototype or session, to ensure isolated state for each user request.
Additional Notes
How would you explain a common mistake with bean scopes in Spring in an interview?