Domanda di colloquio di Capgemini

When to use equals method? Difference between @bean and @component? How to connect db to the spring application?