Hi, Frank,
Glad to hear you're done with the self-flagellation. It serves its purpose in some ways, but it runs its course and the best thing to do is learn and move forward.
A few thoughts:
Forensics: I'm closing in on 21 months of sobriety. In the first four or five months, cravings were occasional and always the way you described -- out of nowhere and without explanation. Usually in my car, when the ol' "auto pilot to the liquor store" hit me. Then came a long spell of no cravings.
In the last year, there have been a handful but they were situational, mostly in the wake of my father's unexpected death. (And thoughtless actions on the part of a former friend, who once was sober. Warning: friendships in recovery, IRL, can be tricky.) But all told, there haven't been that many cravings; they were never strong or lasted long.
It really does get easier. And your ability to deal with them grows stronger. I had a slight craving about a month ago -- again, related to Dad's death -- but it was fleeting. Two minutes, max. Again, though, I was in my car.
Coffee: Honestly, I think you're on to something. Others here have made connections with coffee and drink. I used to drink ridiculous amounts of coffee and though I still enjoy a nice cup, I have mainly become a tea drinker. It's good to change things in recovery -- new habits, new associations. Although there's caffeine in many of my tea choices, I think it's the change that has served me well. I've also noticed I get really jumpy when I have too much coffee.
One other thing: I've all but eliminated sodapop. It's not good for us.
You're doing this, Frank. And I'm glad you're back.
Hang in there.