Peter trank *in einer Stunde / eine Stunde (lang) (das ganze Leben) Bier.
Peter drank in one hour / one hour (long) (the whole life) beer
Peter drank beer *in an hour / for an hour (his whole life long).