manually managing partial reads is silly. a dsl is the right approach here.