The Dvedhavitakka Sutta, Part Two
When thoughts arose, the Buddha used them to practice mindfulness and, moreover, found that he could abandon thinking, rest the mind and gain concentration. He practiced both tranquility and insight meditation alternately and maintained mindfulness in both situations.