US totally does: https://www.irs.gov/individuals/international-taxpayers/expa... - long-term (8y+) green card holders may need to pay up.
One big difference is that the clock only start ticking after you get green card, whereas with Germany any residence year counts. Oh, and citizens of course aren't affected - since US continues to tax them wherever, but Germany like almost all other countries practices residence-based taxation.