This needs to use TreeWalk.forPath().  And translating IOException to a RuntimeException is bad.  :-)

But actually, this should be set in the constructor as a final field.  It appears to be known by anyone who constructs an origin, and its a performance sensitive thing to be able to respond with the ObjectId of the content.  (See OriginWalk findLastSameCommit.)