Psychology researchers discuss their findings in a New York Times op-ed piece.
The take-home advice:
Positive thinking fools our minds into perceiving that we’ve already attained our goal, slackening our readiness to pursue it.
...
What does work better is a hybrid approach that combines positive thinking with “realism.” Here’s how it works. Think of a wish. For a few minutes, imagine the wish coming true, letting your mind wander and drift where it will. Then shift gears. Spend a few more minutes imagining the obstacles that stand in the way of realizing your wish.
This simple process, which my colleagues and I call “mental contrasting,” has produced powerful results in laboratory experiments. When participants have performed mental contrasting with reasonable, potentially attainable wishes, they have come away more energized and achieved better results compared with participants who either positively fantasized or dwelt on the obstacles.
When participants have performed mental contrasting with wishes that are not reasonable or attainable, they have disengaged more from these wishes. Mental contrasting spurs us on when it makes sense to pursue a wish, and lets us abandon wishes more readily when it doesn’t, so that we can go after other, more reasonable ambitions.
Mental contrasting is one of the more tested useful interventions in psychology, including in field studies intended to help actual people with their actual goals. (Though in field studies it's often paired with implementation intentions, an even-more-tested intervention, to give people a double dose of help, which makes those studies less informative about the benefits of either intervention.)
The papers cited in the op-ed, and many others, are available on Oettingen's website. One of the papers is a 2012 review article summarizing the research; it's rather long but you can get a decent picture by reading all the section headings (and then diving into whatever seems interesting):
Oettingen, G. (2012). Future thought and behavior change.%20In%20W.%20Stroebe%20&%20M.%20Hewstone.pdf). In W. Stroebe & M. Hewstone (Eds.), European Review of Social Psychology, 23, 1-63.