It's pretty well-known in political circles that Comey has been toying with the idea of running for president one day, and involving himself in numerous political scandals was part of the strategy.  He built up much more name recognition than any of the past directors in modern history, which is what you need to run for the big seat.  Agency directors with huge name recognition can definitely run for POTUS (think GHWB), so Comey rolled the dice, pushed a little too hard and this time he lost.

But don't go feeling sorry for Jim.  He a month he'll be sitting on the boards of numerous defense and intelligence corporations, having gone from a low six-figure salary to a high-seven, and if he really plays his cards right and pens an expose tell-all on what he learned about Bill and Hillary, the mere advance on that bad boy is going to make an eight-figure man.

When you fire an agency director you're truly doing him/her a favor.  He'll be smiling on Fox News next week.