(Hopefull) fix compatibility issue with Hadoop 1.x and Hadoop 2.0

Hadoop 2 changed the TaskAttemptContext from a class to an interface,
breaking our code.  Therefore, we need to instantiate a difference class
for TaskAttemptContext depending on the version of Hadoop.  Wanting to
maintain compatibility with both versions of Hadoop, this commit reworks the
code to use reflection to try both known options and use the first one
that works.