As far as i can tell the writable will only be null if the newInstance below returns null, which only happens for NullWritables, no? Why not handle nullwritables like others? Instead of storing null for them, shouldn't you return a nullwritable object. If this is specifically designed for edge values, then for edges you have checks for null edge values above. This null checkings are a bit confusing to me.