"If all you have is a hammer, everything looks like a nail"
- Abraham Maslow
To make it clear - I don't claim that DI is evil. I think it's really useful tool. Just a tool like a hammer. Unfortunately very often I can see DI being misused. People tend to put DI in each piece of the application what is often either an overkill or at least unnecessary complication.
One of the bad practices I've recognized is
programming in XML. That happens for example when (hierarchies of) objects (including abstract objects) are defined in Spring configuration files and then used as injected prototypes in Java code which is coupled to their properties. Simple and clear solution is to introduce factory class to create objects directly in Java code.
That's rather rare case but don't worry there are also other more spectacular like for example
Anemic Domain Model. Which is very common and appreciated by some people. It decouples basically everything including the data and the logic. In my opinion DI encourages to use this approach because it enforces to drop the encapsulation and lets to do anyone anything - you have to set the properties somehow, right?
Of course there are solutions like constructor injection and factory beans but they are used rarely.
As far as I remember Spring 1.0 has been announced as a holy grail of JEE development. People dropped EJB2 and started learning Spring. I must admit EJB2 didn't have much in common with object oriented programming as well. The goal of Spring was to simplify JEE project and it has been achieved. Unfortunately Spring has inherited EJB2 functional approach - or Spring users did that.
Did you ever seen a Java project written by someone who is dazzled by DI? It's easy to recognize such a project. If during the review you have to analyze call hierarchies defined mostly in DI configuration and distributed among several XML files - that's it.
DI is not a golden hammer of software development and we also must remember about the design patterns. The art is to join them together and find the balance to not see everything as a nail anymore.