From 552932953f66950469ecb7c65d94d2ad5bfb78c3 Mon Sep 17 00:00:00 2001 From: Lars George Date: Wed, 10 Jul 2013 20:28:44 +0000 Subject: [PATCH] HBASE-8826 Ensure HBASE-8695 is covered in Thrift 2 git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1501968 13f79535-47bb-0310-9956-ffa450edef68 --- .../java/org/apache/hadoop/hbase/thrift2/ThriftServer.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/thrift2/ThriftServer.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/thrift2/ThriftServer.java index c06b2ecb910..87b89b5f563 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/thrift2/ThriftServer.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/thrift2/ThriftServer.java @@ -260,14 +260,16 @@ public class ThriftServer { registerFilters(conf); // Construct correct ProtocolFactory - boolean compact = cmd.hasOption("compact"); + boolean compact = cmd.hasOption("compact") || + conf.getBoolean("hbase.regionserver.thrift.compact", false); TProtocolFactory protocolFactory = getTProtocolFactory(compact); THBaseService.Iface handler = ThriftHBaseServiceHandler.newInstance(conf, metrics); THBaseService.Processor processor = new THBaseService.Processor(handler); conf.setBoolean("hbase.regionserver.thrift.compact", compact); - boolean framed = cmd.hasOption("framed") || nonblocking || hsha; + boolean framed = cmd.hasOption("framed") || + conf.getBoolean("hbase.regionserver.thrift.framed", false) || nonblocking || hsha; TTransportFactory transportFactory = getTTransportFactory(framed); InetSocketAddress inetSocketAddress = bindToPort(cmd.getOptionValue("bind"), listenPort); conf.setBoolean("hbase.regionserver.thrift.framed", framed);