ACCUMULO-2950 Add an RpcWrapper class

  Adds an RpcWrapper class to reintroduce the previous behavior in Thrift 0.9.0
  that was broken by THRIFT-1805 in Thrift 0.9.1. This is done by extending the
  InvocationHandler that was already being used to incorporate Trace information
  into the RPC calls, but now also translates exceptions to one that Thrift
  0.9.1 will expose to the client as a TApplicationException.INTERNAL_ERROR
diff --git a/src/main/java/org/apache/accumulo/proxy/Proxy.java b/src/main/java/org/apache/accumulo/proxy/Proxy.java
index 3e404b1..8130631 100644
--- a/src/main/java/org/apache/accumulo/proxy/Proxy.java
+++ b/src/main/java/org/apache/accumulo/proxy/Proxy.java
@@ -27,6 +27,7 @@
 import org.apache.accumulo.core.conf.AccumuloConfiguration;
 import org.apache.accumulo.minicluster.MiniAccumuloCluster;
 import org.apache.accumulo.proxy.thrift.AccumuloProxy;
+import org.apache.accumulo.server.util.RpcWrapper;
 import org.apache.log4j.Logger;
 import org.apache.thrift.TProcessor;
 import org.apache.thrift.protocol.TCompactProtocol;
@@ -100,6 +101,7 @@
       opts.prop.setProperty("instance", accumulo.getConfig().getInstanceName());
       opts.prop.setProperty("zookeepers", accumulo.getZooKeepers());
       Runtime.getRuntime().addShutdownHook(new Thread() {
+        @Override
         public void start() {
           try {
             accumulo.stop();
@@ -133,7 +135,7 @@
     @SuppressWarnings("unchecked")
     Constructor<? extends TProcessor> proxyProcConstructor = (Constructor<? extends TProcessor>) proxyProcClass.getConstructor(proxyIfaceClass);
     
-    final TProcessor processor = proxyProcConstructor.newInstance(impl);
+    final TProcessor processor = proxyProcConstructor.newInstance(RpcWrapper.service(impl));
     
     THsHaServer.Args args = new THsHaServer.Args(socket);
     args.processor(processor);