For nearly a decade I have had the privilege of teaching veterans of the Iraq and Afghanistan wars, though they have taught me more.

Most of them were Army captains and majors who had done three or four tours of duty. And here’s the most remarkable thing: Not one of these men and women complained about what we asked of them.

They have, however, occasionally objected to the shameful fact that after the first few years of hostilities, these became largely invisible conflicts. In the final stages of the Iraq War and for a long time now in Afghanistan, there has been something close to media silence even as our fellow Americans continue to fight and die.

The ongoing war barely impinges on our daily discussions, and we don’t bother to argue much about our Afghanistan policy. Mostly, we hope President Obama can keep his promise to bring our troops home.

My Thanksgiving thoughts have often turned toward my military students at Georgetown University’s Public Policy Institute, and to the thousands like them who have done very hard duty with little notice.

But this year, the gratitude they inspire has been heightened, perhaps paradoxically, by the news about Gen. David Petraeus, his affair, and the mess left behind. I won’t add to the mountain of Petraeus commentary, so much of which has been driven by pre-existing attitudes toward Petraeus himself, the wars he led, or the matter of how we should deal publicly with sexuality.

What’s troubled me is how writing on all sides has aggravated the understandable but disturbing tendency to lay so much stress on the role of famous generals that we forget both the centrality of midlevel military leadership and the daily sacrifices and bravery of those in the enlisted ranks who carry out orders from on high.

There is, of course, nothing at all new about celebrity generals, and many of them truly deserved the accolades that came their way. One thinks, for example, of Ulysses S. Grant, who is enjoying a comeback among historians, and Dwight D. Eisenhower, whose subsequent presidency should give Republicans trying to rebuild their party some useful guidance.

But our military has been at its best when it combined two deeply American impulses, one more honored on the right, the other on the left.

We are an entrepreneurial country, and members of our officer corps do extraordinary work when they are given the freedom to think for themselves and to innovate.

We are also a democratic nation, and although the military is necessarily rank-conscious, the American armed forces have traditionally nurtured an egalitarian ethos that cultivated loyalty all the way down. This is one reason why reports of rather privileged living by generals are grating, even if none of us begrudges a bit of comfort for those — including people at the top — who give their lives to service.

The entrepreneurial and democratic spirits are important in battle, but they are even more important to the many noncombat tasks we are now asking our military to undertake. Petraeus’ approach to Iraq depended upon officers who had exceptional political gifts and an ability to improvise as they worked with local leaders. As an Army major serving in Iraq wrote in a memo that was shared with me back in 2007, “We discovered that we were not fighting a military campaign, but a political campaign — not too different from what a small town mayor might do to win re-election back in the U.S.” The surge was as much about this kind of inventiveness as it was about military planning.

We can show our gratitude toward these officers and their troops in at least two ways. First, as my MSNBC colleague Rachel Maddow keeps reminding us, we need to cut through what the Iraq and Afghanistan Veterans of America calls the VA’s “egregious failure to process the claims of our veterans” in a timely and effective way.

And we need to recognize the contribution that this new generation of veterans can make to our nation. The character of the “Greatest Generation” that fought World War II was established not by the generals but by the officers in the lower ranks and the millions of enlisted men and women who carried into civilian life both the skills and the sense of service and community they learned in the war years.

My students taught me that we don’t need to be nostalgic about the Greatest Generation. It’s right here among us.

E.J. Dionne’s e-mail address is ejdionne(at)washpost.com.