http://git-wip-us.apache.org/repos/asf/hbase-site/blob/f07ee53f/apidocs/src-html/org/apache/hadoop/hbase/client/Query.html
----------------------------------------------------------------------
diff --git a/apidocs/src-html/org/apache/hadoop/hbase/client/Query.html 
b/apidocs/src-html/org/apache/hadoop/hbase/client/Query.html
index 417e13a..13eb321 100644
--- a/apidocs/src-html/org/apache/hadoop/hbase/client/Query.html
+++ b/apidocs/src-html/org/apache/hadoop/hbase/client/Query.html
@@ -52,7 +52,7 @@
 <span class="sourceLineNo">044</span>  protected int targetReplicaId = -1;<a 
name="line.44"></a>
 <span class="sourceLineNo">045</span>  protected Consistency consistency = 
Consistency.STRONG;<a name="line.45"></a>
 <span class="sourceLineNo">046</span>  protected Map&lt;byte[], TimeRange&gt; 
colFamTimeRangeMap = Maps.newTreeMap(Bytes.BYTES_COMPARATOR);<a 
name="line.46"></a>
-<span class="sourceLineNo">047</span><a name="line.47"></a>
+<span class="sourceLineNo">047</span>  protected Boolean 
loadColumnFamiliesOnDemand = null;<a name="line.47"></a>
 <span class="sourceLineNo">048</span>  /**<a name="line.48"></a>
 <span class="sourceLineNo">049</span>   * @return Filter<a name="line.49"></a>
 <span class="sourceLineNo">050</span>   */<a name="line.50"></a>
@@ -187,32 +187,67 @@
 <span class="sourceLineNo">179</span>                          
IsolationLevel.fromBytes(attr);<a name="line.179"></a>
 <span class="sourceLineNo">180</span>  }<a name="line.180"></a>
 <span class="sourceLineNo">181</span><a name="line.181"></a>
-<span class="sourceLineNo">182</span><a name="line.182"></a>
-<span class="sourceLineNo">183</span>  /**<a name="line.183"></a>
-<span class="sourceLineNo">184</span>   * Get versions of columns only within 
the specified timestamp range,<a name="line.184"></a>
-<span class="sourceLineNo">185</span>   * [minStamp, maxStamp) on a per CF 
bases.  Note, default maximum versions to return is 1.  If<a 
name="line.185"></a>
-<span class="sourceLineNo">186</span>   * your time range spans more than one 
version and you want all versions<a name="line.186"></a>
-<span class="sourceLineNo">187</span>   * returned, up the number of versions 
beyond the default.<a name="line.187"></a>
-<span class="sourceLineNo">188</span>   * Column Family time ranges take 
precedence over the global time range.<a name="line.188"></a>
-<span class="sourceLineNo">189</span>   *<a name="line.189"></a>
-<span class="sourceLineNo">190</span>   * @param cf       the column family 
for which you want to restrict<a name="line.190"></a>
-<span class="sourceLineNo">191</span>   * @param minStamp minimum timestamp 
value, inclusive<a name="line.191"></a>
-<span class="sourceLineNo">192</span>   * @param maxStamp maximum timestamp 
value, exclusive<a name="line.192"></a>
-<span class="sourceLineNo">193</span>   * @return this<a name="line.193"></a>
-<span class="sourceLineNo">194</span>   */<a name="line.194"></a>
-<span class="sourceLineNo">195</span><a name="line.195"></a>
-<span class="sourceLineNo">196</span>  public Query 
setColumnFamilyTimeRange(byte[] cf, long minStamp, long maxStamp) {<a 
name="line.196"></a>
-<span class="sourceLineNo">197</span>    colFamTimeRangeMap.put(cf, new 
TimeRange(minStamp, maxStamp));<a name="line.197"></a>
-<span class="sourceLineNo">198</span>    return this;<a name="line.198"></a>
-<span class="sourceLineNo">199</span>  }<a name="line.199"></a>
-<span class="sourceLineNo">200</span><a name="line.200"></a>
-<span class="sourceLineNo">201</span>  /**<a name="line.201"></a>
-<span class="sourceLineNo">202</span>   * @return A map of column families to 
time ranges<a name="line.202"></a>
-<span class="sourceLineNo">203</span>   */<a name="line.203"></a>
-<span class="sourceLineNo">204</span>  public Map&lt;byte[], TimeRange&gt; 
getColumnFamilyTimeRange() {<a name="line.204"></a>
-<span class="sourceLineNo">205</span>    return this.colFamTimeRangeMap;<a 
name="line.205"></a>
-<span class="sourceLineNo">206</span>  }<a name="line.206"></a>
-<span class="sourceLineNo">207</span>}<a name="line.207"></a>
+<span class="sourceLineNo">182</span>  /**<a name="line.182"></a>
+<span class="sourceLineNo">183</span>   * Set the value indicating whether 
loading CFs on demand should be allowed (cluster<a name="line.183"></a>
+<span class="sourceLineNo">184</span>   * default is false). On-demand CF 
loading doesn't load column families until necessary, e.g.<a 
name="line.184"></a>
+<span class="sourceLineNo">185</span>   * if you filter on one column, the 
other column family data will be loaded only for the rows<a name="line.185"></a>
+<span class="sourceLineNo">186</span>   * that are included in result, not all 
rows like in normal case.<a name="line.186"></a>
+<span class="sourceLineNo">187</span>   * With column-specific filters, like 
SingleColumnValueFilter w/filterIfMissing == true,<a name="line.187"></a>
+<span class="sourceLineNo">188</span>   * this can deliver huge perf gains 
when there's a cf with lots of data; however, it can<a name="line.188"></a>
+<span class="sourceLineNo">189</span>   * also lead to some inconsistent 
results, as follows:<a name="line.189"></a>
+<span class="sourceLineNo">190</span>   * - if someone does a concurrent 
update to both column families in question you may get a row<a 
name="line.190"></a>
+<span class="sourceLineNo">191</span>   *   that never existed, e.g. for { 
rowKey = 5, { cat_videos =&amp;gt; 1 }, { video =&amp;gt; "my cat" } }<a 
name="line.191"></a>
+<span class="sourceLineNo">192</span>   *   someone puts rowKey 5 with { 
cat_videos =&amp;gt; 0 }, { video =&amp;gt; "my dog" }, concurrent scan<a 
name="line.192"></a>
+<span class="sourceLineNo">193</span>   *   filtering on "cat_videos == 1" can 
get { rowKey = 5, { cat_videos =&amp;gt; 1 },<a name="line.193"></a>
+<span class="sourceLineNo">194</span>   *   { video =&amp;gt; "my dog" } }.<a 
name="line.194"></a>
+<span class="sourceLineNo">195</span>   * - if there's a concurrent split and 
you have more than 2 column families, some rows may be<a name="line.195"></a>
+<span class="sourceLineNo">196</span>   *   missing some column families.<a 
name="line.196"></a>
+<span class="sourceLineNo">197</span>   */<a name="line.197"></a>
+<span class="sourceLineNo">198</span>  public Query 
setLoadColumnFamiliesOnDemand(boolean value) {<a name="line.198"></a>
+<span class="sourceLineNo">199</span>    this.loadColumnFamiliesOnDemand = 
value;<a name="line.199"></a>
+<span class="sourceLineNo">200</span>    return this;<a name="line.200"></a>
+<span class="sourceLineNo">201</span>  }<a name="line.201"></a>
+<span class="sourceLineNo">202</span><a name="line.202"></a>
+<span class="sourceLineNo">203</span>  /**<a name="line.203"></a>
+<span class="sourceLineNo">204</span>   * Get the raw 
loadColumnFamiliesOnDemand setting; if it's not set, can be null.<a 
name="line.204"></a>
+<span class="sourceLineNo">205</span>   */<a name="line.205"></a>
+<span class="sourceLineNo">206</span>  public Boolean 
getLoadColumnFamiliesOnDemandValue() {<a name="line.206"></a>
+<span class="sourceLineNo">207</span>    return 
this.loadColumnFamiliesOnDemand;<a name="line.207"></a>
+<span class="sourceLineNo">208</span>  }<a name="line.208"></a>
+<span class="sourceLineNo">209</span><a name="line.209"></a>
+<span class="sourceLineNo">210</span>  /**<a name="line.210"></a>
+<span class="sourceLineNo">211</span>   * Get the logical value indicating 
whether on-demand CF loading should be allowed.<a name="line.211"></a>
+<span class="sourceLineNo">212</span>   */<a name="line.212"></a>
+<span class="sourceLineNo">213</span>  public boolean 
doLoadColumnFamiliesOnDemand() {<a name="line.213"></a>
+<span class="sourceLineNo">214</span>    return 
(this.loadColumnFamiliesOnDemand != null)<a name="line.214"></a>
+<span class="sourceLineNo">215</span>      &amp;&amp; 
this.loadColumnFamiliesOnDemand;<a name="line.215"></a>
+<span class="sourceLineNo">216</span>  }<a name="line.216"></a>
+<span class="sourceLineNo">217</span><a name="line.217"></a>
+<span class="sourceLineNo">218</span>  /**<a name="line.218"></a>
+<span class="sourceLineNo">219</span>   * Get versions of columns only within 
the specified timestamp range,<a name="line.219"></a>
+<span class="sourceLineNo">220</span>   * [minStamp, maxStamp) on a per CF 
bases.  Note, default maximum versions to return is 1.  If<a 
name="line.220"></a>
+<span class="sourceLineNo">221</span>   * your time range spans more than one 
version and you want all versions<a name="line.221"></a>
+<span class="sourceLineNo">222</span>   * returned, up the number of versions 
beyond the default.<a name="line.222"></a>
+<span class="sourceLineNo">223</span>   * Column Family time ranges take 
precedence over the global time range.<a name="line.223"></a>
+<span class="sourceLineNo">224</span>   *<a name="line.224"></a>
+<span class="sourceLineNo">225</span>   * @param cf       the column family 
for which you want to restrict<a name="line.225"></a>
+<span class="sourceLineNo">226</span>   * @param minStamp minimum timestamp 
value, inclusive<a name="line.226"></a>
+<span class="sourceLineNo">227</span>   * @param maxStamp maximum timestamp 
value, exclusive<a name="line.227"></a>
+<span class="sourceLineNo">228</span>   * @return this<a name="line.228"></a>
+<span class="sourceLineNo">229</span>   */<a name="line.229"></a>
+<span class="sourceLineNo">230</span><a name="line.230"></a>
+<span class="sourceLineNo">231</span>  public Query 
setColumnFamilyTimeRange(byte[] cf, long minStamp, long maxStamp) {<a 
name="line.231"></a>
+<span class="sourceLineNo">232</span>    colFamTimeRangeMap.put(cf, new 
TimeRange(minStamp, maxStamp));<a name="line.232"></a>
+<span class="sourceLineNo">233</span>    return this;<a name="line.233"></a>
+<span class="sourceLineNo">234</span>  }<a name="line.234"></a>
+<span class="sourceLineNo">235</span><a name="line.235"></a>
+<span class="sourceLineNo">236</span>  /**<a name="line.236"></a>
+<span class="sourceLineNo">237</span>   * @return A map of column families to 
time ranges<a name="line.237"></a>
+<span class="sourceLineNo">238</span>   */<a name="line.238"></a>
+<span class="sourceLineNo">239</span>  public Map&lt;byte[], TimeRange&gt; 
getColumnFamilyTimeRange() {<a name="line.239"></a>
+<span class="sourceLineNo">240</span>    return this.colFamTimeRangeMap;<a 
name="line.240"></a>
+<span class="sourceLineNo">241</span>  }<a name="line.241"></a>
+<span class="sourceLineNo">242</span>}<a name="line.242"></a>
 
 
 

http://git-wip-us.apache.org/repos/asf/hbase-site/blob/f07ee53f/apidocs/src-html/org/apache/hadoop/hbase/client/Scan.html
----------------------------------------------------------------------
diff --git a/apidocs/src-html/org/apache/hadoop/hbase/client/Scan.html 
b/apidocs/src-html/org/apache/hadoop/hbase/client/Scan.html
index 274255a..67d3a00 100644
--- a/apidocs/src-html/org/apache/hadoop/hbase/client/Scan.html
+++ b/apidocs/src-html/org/apache/hadoop/hbase/client/Scan.html
@@ -145,142 +145,142 @@
 <span class="sourceLineNo">137</span>  private TimeRange tr = new 
TimeRange();<a name="line.137"></a>
 <span class="sourceLineNo">138</span>  private Map&lt;byte [], 
NavigableSet&lt;byte []&gt;&gt; familyMap =<a name="line.138"></a>
 <span class="sourceLineNo">139</span>    new TreeMap&lt;byte [], 
NavigableSet&lt;byte []&gt;&gt;(Bytes.BYTES_COMPARATOR);<a name="line.139"></a>
-<span class="sourceLineNo">140</span>  private Boolean 
loadColumnFamiliesOnDemand = null;<a name="line.140"></a>
-<span class="sourceLineNo">141</span>  private Boolean asyncPrefetch = null;<a 
name="line.141"></a>
-<span class="sourceLineNo">142</span><a name="line.142"></a>
-<span class="sourceLineNo">143</span>  /**<a name="line.143"></a>
-<span class="sourceLineNo">144</span>   * Parameter name for client scanner 
sync/async prefetch toggle.<a name="line.144"></a>
-<span class="sourceLineNo">145</span>   * When using async scanner, 
prefetching data from the server is done at the background.<a 
name="line.145"></a>
-<span class="sourceLineNo">146</span>   * The parameter currently won't have 
any effect in the case that the user has set<a name="line.146"></a>
-<span class="sourceLineNo">147</span>   * Scan#setSmall or Scan#setReversed<a 
name="line.147"></a>
-<span class="sourceLineNo">148</span>   */<a name="line.148"></a>
-<span class="sourceLineNo">149</span>  public static final String 
HBASE_CLIENT_SCANNER_ASYNC_PREFETCH =<a name="line.149"></a>
-<span class="sourceLineNo">150</span>      
"hbase.client.scanner.async.prefetch";<a name="line.150"></a>
-<span class="sourceLineNo">151</span><a name="line.151"></a>
-<span class="sourceLineNo">152</span>  /**<a name="line.152"></a>
-<span class="sourceLineNo">153</span>   * Default value of {@link 
#HBASE_CLIENT_SCANNER_ASYNC_PREFETCH}.<a name="line.153"></a>
-<span class="sourceLineNo">154</span>   */<a name="line.154"></a>
-<span class="sourceLineNo">155</span>  public static final boolean 
DEFAULT_HBASE_CLIENT_SCANNER_ASYNC_PREFETCH = false;<a name="line.155"></a>
-<span class="sourceLineNo">156</span><a name="line.156"></a>
-<span class="sourceLineNo">157</span>   /**<a name="line.157"></a>
-<span class="sourceLineNo">158</span>   * Set it true for small scan to get 
better performance<a name="line.158"></a>
-<span class="sourceLineNo">159</span>   *<a name="line.159"></a>
-<span class="sourceLineNo">160</span>   * Small scan should use pread and big 
scan can use seek + read<a name="line.160"></a>
-<span class="sourceLineNo">161</span>   *<a name="line.161"></a>
-<span class="sourceLineNo">162</span>   * seek + read is fast but can cause 
two problem (1) resource contention (2)<a name="line.162"></a>
-<span class="sourceLineNo">163</span>   * cause too much network io<a 
name="line.163"></a>
-<span class="sourceLineNo">164</span>   *<a name="line.164"></a>
-<span class="sourceLineNo">165</span>   * [89-fb] Using pread for 
non-compaction read request<a name="line.165"></a>
-<span class="sourceLineNo">166</span>   * 
https://issues.apache.org/jira/browse/HBASE-7266<a name="line.166"></a>
-<span class="sourceLineNo">167</span>   *<a name="line.167"></a>
-<span class="sourceLineNo">168</span>   * On the other hand, if setting it 
true, we would do<a name="line.168"></a>
-<span class="sourceLineNo">169</span>   * openScanner,next,closeScanner in one 
RPC call. It means the better<a name="line.169"></a>
-<span class="sourceLineNo">170</span>   * performance for small scan. 
[HBASE-9488].<a name="line.170"></a>
-<span class="sourceLineNo">171</span>   *<a name="line.171"></a>
-<span class="sourceLineNo">172</span>   * Generally, if the scan range is 
within one data block(64KB), it could be<a name="line.172"></a>
-<span class="sourceLineNo">173</span>   * considered as a small scan.<a 
name="line.173"></a>
-<span class="sourceLineNo">174</span>   */<a name="line.174"></a>
-<span class="sourceLineNo">175</span>  private boolean small = false;<a 
name="line.175"></a>
-<span class="sourceLineNo">176</span><a name="line.176"></a>
-<span class="sourceLineNo">177</span>  /**<a name="line.177"></a>
-<span class="sourceLineNo">178</span>   * Create a Scan operation across all 
rows.<a name="line.178"></a>
-<span class="sourceLineNo">179</span>   */<a name="line.179"></a>
-<span class="sourceLineNo">180</span>  public Scan() {}<a name="line.180"></a>
-<span class="sourceLineNo">181</span><a name="line.181"></a>
-<span class="sourceLineNo">182</span>  public Scan(byte [] startRow, Filter 
filter) {<a name="line.182"></a>
-<span class="sourceLineNo">183</span>    this(startRow);<a name="line.183"></a>
-<span class="sourceLineNo">184</span>    this.filter = filter;<a 
name="line.184"></a>
-<span class="sourceLineNo">185</span>  }<a name="line.185"></a>
-<span class="sourceLineNo">186</span><a name="line.186"></a>
-<span class="sourceLineNo">187</span>  /**<a name="line.187"></a>
-<span class="sourceLineNo">188</span>   * Create a Scan operation starting at 
the specified row.<a name="line.188"></a>
-<span class="sourceLineNo">189</span>   * &lt;p&gt;<a name="line.189"></a>
-<span class="sourceLineNo">190</span>   * If the specified row does not exist, 
the Scanner will start from the<a name="line.190"></a>
-<span class="sourceLineNo">191</span>   * next closest row after the specified 
row.<a name="line.191"></a>
-<span class="sourceLineNo">192</span>   * @param startRow row to start scanner 
at or after<a name="line.192"></a>
-<span class="sourceLineNo">193</span>   */<a name="line.193"></a>
-<span class="sourceLineNo">194</span>  public Scan(byte [] startRow) {<a 
name="line.194"></a>
-<span class="sourceLineNo">195</span>    this.startRow = startRow;<a 
name="line.195"></a>
-<span class="sourceLineNo">196</span>  }<a name="line.196"></a>
-<span class="sourceLineNo">197</span><a name="line.197"></a>
-<span class="sourceLineNo">198</span>  /**<a name="line.198"></a>
-<span class="sourceLineNo">199</span>   * Create a Scan operation for the 
range of rows specified.<a name="line.199"></a>
-<span class="sourceLineNo">200</span>   * @param startRow row to start scanner 
at or after (inclusive)<a name="line.200"></a>
-<span class="sourceLineNo">201</span>   * @param stopRow row to stop scanner 
before (exclusive)<a name="line.201"></a>
-<span class="sourceLineNo">202</span>   */<a name="line.202"></a>
-<span class="sourceLineNo">203</span>  public Scan(byte [] startRow, byte [] 
stopRow) {<a name="line.203"></a>
-<span class="sourceLineNo">204</span>    this.startRow = startRow;<a 
name="line.204"></a>
-<span class="sourceLineNo">205</span>    this.stopRow = stopRow;<a 
name="line.205"></a>
-<span class="sourceLineNo">206</span>    //if the startRow and stopRow both 
are empty, it is not a Get<a name="line.206"></a>
-<span class="sourceLineNo">207</span>    this.getScan = 
isStartRowAndEqualsStopRow();<a name="line.207"></a>
-<span class="sourceLineNo">208</span>  }<a name="line.208"></a>
-<span class="sourceLineNo">209</span><a name="line.209"></a>
-<span class="sourceLineNo">210</span>  /**<a name="line.210"></a>
-<span class="sourceLineNo">211</span>   * Creates a new instance of this class 
while copying all values.<a name="line.211"></a>
-<span class="sourceLineNo">212</span>   *<a name="line.212"></a>
-<span class="sourceLineNo">213</span>   * @param scan  The scan instance to 
copy from.<a name="line.213"></a>
-<span class="sourceLineNo">214</span>   * @throws IOException When copying the 
values fails.<a name="line.214"></a>
-<span class="sourceLineNo">215</span>   */<a name="line.215"></a>
-<span class="sourceLineNo">216</span>  public Scan(Scan scan) throws 
IOException {<a name="line.216"></a>
-<span class="sourceLineNo">217</span>    startRow = scan.getStartRow();<a 
name="line.217"></a>
-<span class="sourceLineNo">218</span>    stopRow  = scan.getStopRow();<a 
name="line.218"></a>
-<span class="sourceLineNo">219</span>    maxVersions = 
scan.getMaxVersions();<a name="line.219"></a>
-<span class="sourceLineNo">220</span>    batch = scan.getBatch();<a 
name="line.220"></a>
-<span class="sourceLineNo">221</span>    storeLimit = 
scan.getMaxResultsPerColumnFamily();<a name="line.221"></a>
-<span class="sourceLineNo">222</span>    storeOffset = 
scan.getRowOffsetPerColumnFamily();<a name="line.222"></a>
-<span class="sourceLineNo">223</span>    caching = scan.getCaching();<a 
name="line.223"></a>
-<span class="sourceLineNo">224</span>    maxResultSize = 
scan.getMaxResultSize();<a name="line.224"></a>
-<span class="sourceLineNo">225</span>    cacheBlocks = 
scan.getCacheBlocks();<a name="line.225"></a>
-<span class="sourceLineNo">226</span>    getScan = scan.isGetScan();<a 
name="line.226"></a>
-<span class="sourceLineNo">227</span>    filter = scan.getFilter(); // 
clone?<a name="line.227"></a>
-<span class="sourceLineNo">228</span>    loadColumnFamiliesOnDemand = 
scan.getLoadColumnFamiliesOnDemandValue();<a name="line.228"></a>
-<span class="sourceLineNo">229</span>    consistency = 
scan.getConsistency();<a name="line.229"></a>
-<span class="sourceLineNo">230</span>    
this.setIsolationLevel(scan.getIsolationLevel());<a name="line.230"></a>
-<span class="sourceLineNo">231</span>    reversed = scan.isReversed();<a 
name="line.231"></a>
-<span class="sourceLineNo">232</span>    asyncPrefetch = 
scan.isAsyncPrefetch();<a name="line.232"></a>
-<span class="sourceLineNo">233</span>    small = scan.isSmall();<a 
name="line.233"></a>
-<span class="sourceLineNo">234</span>    allowPartialResults = 
scan.getAllowPartialResults();<a name="line.234"></a>
-<span class="sourceLineNo">235</span>    TimeRange ctr = 
scan.getTimeRange();<a name="line.235"></a>
-<span class="sourceLineNo">236</span>    tr = new TimeRange(ctr.getMin(), 
ctr.getMax());<a name="line.236"></a>
-<span class="sourceLineNo">237</span>    Map&lt;byte[], 
NavigableSet&lt;byte[]&gt;&gt; fams = scan.getFamilyMap();<a 
name="line.237"></a>
-<span class="sourceLineNo">238</span>    for 
(Map.Entry&lt;byte[],NavigableSet&lt;byte[]&gt;&gt; entry : fams.entrySet()) 
{<a name="line.238"></a>
-<span class="sourceLineNo">239</span>      byte [] fam = entry.getKey();<a 
name="line.239"></a>
-<span class="sourceLineNo">240</span>      NavigableSet&lt;byte[]&gt; cols = 
entry.getValue();<a name="line.240"></a>
-<span class="sourceLineNo">241</span>      if (cols != null &amp;&amp; 
cols.size() &gt; 0) {<a name="line.241"></a>
-<span class="sourceLineNo">242</span>        for (byte[] col : cols) {<a 
name="line.242"></a>
-<span class="sourceLineNo">243</span>          addColumn(fam, col);<a 
name="line.243"></a>
-<span class="sourceLineNo">244</span>        }<a name="line.244"></a>
-<span class="sourceLineNo">245</span>      } else {<a name="line.245"></a>
-<span class="sourceLineNo">246</span>        addFamily(fam);<a 
name="line.246"></a>
-<span class="sourceLineNo">247</span>      }<a name="line.247"></a>
-<span class="sourceLineNo">248</span>    }<a name="line.248"></a>
-<span class="sourceLineNo">249</span>    for (Map.Entry&lt;String, byte[]&gt; 
attr : scan.getAttributesMap().entrySet()) {<a name="line.249"></a>
-<span class="sourceLineNo">250</span>      setAttribute(attr.getKey(), 
attr.getValue());<a name="line.250"></a>
-<span class="sourceLineNo">251</span>    }<a name="line.251"></a>
-<span class="sourceLineNo">252</span>    for (Map.Entry&lt;byte[], 
TimeRange&gt; entry : scan.getColumnFamilyTimeRange().entrySet()) {<a 
name="line.252"></a>
-<span class="sourceLineNo">253</span>      TimeRange tr = entry.getValue();<a 
name="line.253"></a>
-<span class="sourceLineNo">254</span>      
setColumnFamilyTimeRange(entry.getKey(), tr.getMin(), tr.getMax());<a 
name="line.254"></a>
-<span class="sourceLineNo">255</span>    }<a name="line.255"></a>
-<span class="sourceLineNo">256</span>  }<a name="line.256"></a>
-<span class="sourceLineNo">257</span><a name="line.257"></a>
-<span class="sourceLineNo">258</span>  /**<a name="line.258"></a>
-<span class="sourceLineNo">259</span>   * Builds a scan object with the same 
specs as get.<a name="line.259"></a>
-<span class="sourceLineNo">260</span>   * @param get get to model scan after<a 
name="line.260"></a>
-<span class="sourceLineNo">261</span>   */<a name="line.261"></a>
-<span class="sourceLineNo">262</span>  public Scan(Get get) {<a 
name="line.262"></a>
-<span class="sourceLineNo">263</span>    this.startRow = get.getRow();<a 
name="line.263"></a>
-<span class="sourceLineNo">264</span>    this.stopRow = get.getRow();<a 
name="line.264"></a>
-<span class="sourceLineNo">265</span>    this.filter = get.getFilter();<a 
name="line.265"></a>
-<span class="sourceLineNo">266</span>    this.cacheBlocks = 
get.getCacheBlocks();<a name="line.266"></a>
-<span class="sourceLineNo">267</span>    this.maxVersions = 
get.getMaxVersions();<a name="line.267"></a>
-<span class="sourceLineNo">268</span>    this.storeLimit = 
get.getMaxResultsPerColumnFamily();<a name="line.268"></a>
-<span class="sourceLineNo">269</span>    this.storeOffset = 
get.getRowOffsetPerColumnFamily();<a name="line.269"></a>
-<span class="sourceLineNo">270</span>    this.tr = get.getTimeRange();<a 
name="line.270"></a>
-<span class="sourceLineNo">271</span>    this.familyMap = 
get.getFamilyMap();<a name="line.271"></a>
-<span class="sourceLineNo">272</span>    this.getScan = true;<a 
name="line.272"></a>
-<span class="sourceLineNo">273</span>    this.asyncPrefetch = false;<a 
name="line.273"></a>
-<span class="sourceLineNo">274</span>    this.consistency = 
get.getConsistency();<a name="line.274"></a>
-<span class="sourceLineNo">275</span>    
this.setIsolationLevel(get.getIsolationLevel());<a name="line.275"></a>
+<span class="sourceLineNo">140</span>  private Boolean asyncPrefetch = null;<a 
name="line.140"></a>
+<span class="sourceLineNo">141</span><a name="line.141"></a>
+<span class="sourceLineNo">142</span>  /**<a name="line.142"></a>
+<span class="sourceLineNo">143</span>   * Parameter name for client scanner 
sync/async prefetch toggle.<a name="line.143"></a>
+<span class="sourceLineNo">144</span>   * When using async scanner, 
prefetching data from the server is done at the background.<a 
name="line.144"></a>
+<span class="sourceLineNo">145</span>   * The parameter currently won't have 
any effect in the case that the user has set<a name="line.145"></a>
+<span class="sourceLineNo">146</span>   * Scan#setSmall or Scan#setReversed<a 
name="line.146"></a>
+<span class="sourceLineNo">147</span>   */<a name="line.147"></a>
+<span class="sourceLineNo">148</span>  public static final String 
HBASE_CLIENT_SCANNER_ASYNC_PREFETCH =<a name="line.148"></a>
+<span class="sourceLineNo">149</span>      
"hbase.client.scanner.async.prefetch";<a name="line.149"></a>
+<span class="sourceLineNo">150</span><a name="line.150"></a>
+<span class="sourceLineNo">151</span>  /**<a name="line.151"></a>
+<span class="sourceLineNo">152</span>   * Default value of {@link 
#HBASE_CLIENT_SCANNER_ASYNC_PREFETCH}.<a name="line.152"></a>
+<span class="sourceLineNo">153</span>   */<a name="line.153"></a>
+<span class="sourceLineNo">154</span>  public static final boolean 
DEFAULT_HBASE_CLIENT_SCANNER_ASYNC_PREFETCH = false;<a name="line.154"></a>
+<span class="sourceLineNo">155</span><a name="line.155"></a>
+<span class="sourceLineNo">156</span>   /**<a name="line.156"></a>
+<span class="sourceLineNo">157</span>   * Set it true for small scan to get 
better performance<a name="line.157"></a>
+<span class="sourceLineNo">158</span>   *<a name="line.158"></a>
+<span class="sourceLineNo">159</span>   * Small scan should use pread and big 
scan can use seek + read<a name="line.159"></a>
+<span class="sourceLineNo">160</span>   *<a name="line.160"></a>
+<span class="sourceLineNo">161</span>   * seek + read is fast but can cause 
two problem (1) resource contention (2)<a name="line.161"></a>
+<span class="sourceLineNo">162</span>   * cause too much network io<a 
name="line.162"></a>
+<span class="sourceLineNo">163</span>   *<a name="line.163"></a>
+<span class="sourceLineNo">164</span>   * [89-fb] Using pread for 
non-compaction read request<a name="line.164"></a>
+<span class="sourceLineNo">165</span>   * 
https://issues.apache.org/jira/browse/HBASE-7266<a name="line.165"></a>
+<span class="sourceLineNo">166</span>   *<a name="line.166"></a>
+<span class="sourceLineNo">167</span>   * On the other hand, if setting it 
true, we would do<a name="line.167"></a>
+<span class="sourceLineNo">168</span>   * openScanner,next,closeScanner in one 
RPC call. It means the better<a name="line.168"></a>
+<span class="sourceLineNo">169</span>   * performance for small scan. 
[HBASE-9488].<a name="line.169"></a>
+<span class="sourceLineNo">170</span>   *<a name="line.170"></a>
+<span class="sourceLineNo">171</span>   * Generally, if the scan range is 
within one data block(64KB), it could be<a name="line.171"></a>
+<span class="sourceLineNo">172</span>   * considered as a small scan.<a 
name="line.172"></a>
+<span class="sourceLineNo">173</span>   */<a name="line.173"></a>
+<span class="sourceLineNo">174</span>  private boolean small = false;<a 
name="line.174"></a>
+<span class="sourceLineNo">175</span><a name="line.175"></a>
+<span class="sourceLineNo">176</span>  /**<a name="line.176"></a>
+<span class="sourceLineNo">177</span>   * Create a Scan operation across all 
rows.<a name="line.177"></a>
+<span class="sourceLineNo">178</span>   */<a name="line.178"></a>
+<span class="sourceLineNo">179</span>  public Scan() {}<a name="line.179"></a>
+<span class="sourceLineNo">180</span><a name="line.180"></a>
+<span class="sourceLineNo">181</span>  public Scan(byte [] startRow, Filter 
filter) {<a name="line.181"></a>
+<span class="sourceLineNo">182</span>    this(startRow);<a name="line.182"></a>
+<span class="sourceLineNo">183</span>    this.filter = filter;<a 
name="line.183"></a>
+<span class="sourceLineNo">184</span>  }<a name="line.184"></a>
+<span class="sourceLineNo">185</span><a name="line.185"></a>
+<span class="sourceLineNo">186</span>  /**<a name="line.186"></a>
+<span class="sourceLineNo">187</span>   * Create a Scan operation starting at 
the specified row.<a name="line.187"></a>
+<span class="sourceLineNo">188</span>   * &lt;p&gt;<a name="line.188"></a>
+<span class="sourceLineNo">189</span>   * If the specified row does not exist, 
the Scanner will start from the<a name="line.189"></a>
+<span class="sourceLineNo">190</span>   * next closest row after the specified 
row.<a name="line.190"></a>
+<span class="sourceLineNo">191</span>   * @param startRow row to start scanner 
at or after<a name="line.191"></a>
+<span class="sourceLineNo">192</span>   */<a name="line.192"></a>
+<span class="sourceLineNo">193</span>  public Scan(byte [] startRow) {<a 
name="line.193"></a>
+<span class="sourceLineNo">194</span>    this.startRow = startRow;<a 
name="line.194"></a>
+<span class="sourceLineNo">195</span>  }<a name="line.195"></a>
+<span class="sourceLineNo">196</span><a name="line.196"></a>
+<span class="sourceLineNo">197</span>  /**<a name="line.197"></a>
+<span class="sourceLineNo">198</span>   * Create a Scan operation for the 
range of rows specified.<a name="line.198"></a>
+<span class="sourceLineNo">199</span>   * @param startRow row to start scanner 
at or after (inclusive)<a name="line.199"></a>
+<span class="sourceLineNo">200</span>   * @param stopRow row to stop scanner 
before (exclusive)<a name="line.200"></a>
+<span class="sourceLineNo">201</span>   */<a name="line.201"></a>
+<span class="sourceLineNo">202</span>  public Scan(byte [] startRow, byte [] 
stopRow) {<a name="line.202"></a>
+<span class="sourceLineNo">203</span>    this.startRow = startRow;<a 
name="line.203"></a>
+<span class="sourceLineNo">204</span>    this.stopRow = stopRow;<a 
name="line.204"></a>
+<span class="sourceLineNo">205</span>    //if the startRow and stopRow both 
are empty, it is not a Get<a name="line.205"></a>
+<span class="sourceLineNo">206</span>    this.getScan = 
isStartRowAndEqualsStopRow();<a name="line.206"></a>
+<span class="sourceLineNo">207</span>  }<a name="line.207"></a>
+<span class="sourceLineNo">208</span><a name="line.208"></a>
+<span class="sourceLineNo">209</span>  /**<a name="line.209"></a>
+<span class="sourceLineNo">210</span>   * Creates a new instance of this class 
while copying all values.<a name="line.210"></a>
+<span class="sourceLineNo">211</span>   *<a name="line.211"></a>
+<span class="sourceLineNo">212</span>   * @param scan  The scan instance to 
copy from.<a name="line.212"></a>
+<span class="sourceLineNo">213</span>   * @throws IOException When copying the 
values fails.<a name="line.213"></a>
+<span class="sourceLineNo">214</span>   */<a name="line.214"></a>
+<span class="sourceLineNo">215</span>  public Scan(Scan scan) throws 
IOException {<a name="line.215"></a>
+<span class="sourceLineNo">216</span>    startRow = scan.getStartRow();<a 
name="line.216"></a>
+<span class="sourceLineNo">217</span>    stopRow  = scan.getStopRow();<a 
name="line.217"></a>
+<span class="sourceLineNo">218</span>    maxVersions = 
scan.getMaxVersions();<a name="line.218"></a>
+<span class="sourceLineNo">219</span>    batch = scan.getBatch();<a 
name="line.219"></a>
+<span class="sourceLineNo">220</span>    storeLimit = 
scan.getMaxResultsPerColumnFamily();<a name="line.220"></a>
+<span class="sourceLineNo">221</span>    storeOffset = 
scan.getRowOffsetPerColumnFamily();<a name="line.221"></a>
+<span class="sourceLineNo">222</span>    caching = scan.getCaching();<a 
name="line.222"></a>
+<span class="sourceLineNo">223</span>    maxResultSize = 
scan.getMaxResultSize();<a name="line.223"></a>
+<span class="sourceLineNo">224</span>    cacheBlocks = 
scan.getCacheBlocks();<a name="line.224"></a>
+<span class="sourceLineNo">225</span>    getScan = scan.isGetScan();<a 
name="line.225"></a>
+<span class="sourceLineNo">226</span>    filter = scan.getFilter(); // 
clone?<a name="line.226"></a>
+<span class="sourceLineNo">227</span>    loadColumnFamiliesOnDemand = 
scan.getLoadColumnFamiliesOnDemandValue();<a name="line.227"></a>
+<span class="sourceLineNo">228</span>    consistency = 
scan.getConsistency();<a name="line.228"></a>
+<span class="sourceLineNo">229</span>    
this.setIsolationLevel(scan.getIsolationLevel());<a name="line.229"></a>
+<span class="sourceLineNo">230</span>    reversed = scan.isReversed();<a 
name="line.230"></a>
+<span class="sourceLineNo">231</span>    asyncPrefetch = 
scan.isAsyncPrefetch();<a name="line.231"></a>
+<span class="sourceLineNo">232</span>    small = scan.isSmall();<a 
name="line.232"></a>
+<span class="sourceLineNo">233</span>    allowPartialResults = 
scan.getAllowPartialResults();<a name="line.233"></a>
+<span class="sourceLineNo">234</span>    TimeRange ctr = 
scan.getTimeRange();<a name="line.234"></a>
+<span class="sourceLineNo">235</span>    tr = new TimeRange(ctr.getMin(), 
ctr.getMax());<a name="line.235"></a>
+<span class="sourceLineNo">236</span>    Map&lt;byte[], 
NavigableSet&lt;byte[]&gt;&gt; fams = scan.getFamilyMap();<a 
name="line.236"></a>
+<span class="sourceLineNo">237</span>    for 
(Map.Entry&lt;byte[],NavigableSet&lt;byte[]&gt;&gt; entry : fams.entrySet()) 
{<a name="line.237"></a>
+<span class="sourceLineNo">238</span>      byte [] fam = entry.getKey();<a 
name="line.238"></a>
+<span class="sourceLineNo">239</span>      NavigableSet&lt;byte[]&gt; cols = 
entry.getValue();<a name="line.239"></a>
+<span class="sourceLineNo">240</span>      if (cols != null &amp;&amp; 
cols.size() &gt; 0) {<a name="line.240"></a>
+<span class="sourceLineNo">241</span>        for (byte[] col : cols) {<a 
name="line.241"></a>
+<span class="sourceLineNo">242</span>          addColumn(fam, col);<a 
name="line.242"></a>
+<span class="sourceLineNo">243</span>        }<a name="line.243"></a>
+<span class="sourceLineNo">244</span>      } else {<a name="line.244"></a>
+<span class="sourceLineNo">245</span>        addFamily(fam);<a 
name="line.245"></a>
+<span class="sourceLineNo">246</span>      }<a name="line.246"></a>
+<span class="sourceLineNo">247</span>    }<a name="line.247"></a>
+<span class="sourceLineNo">248</span>    for (Map.Entry&lt;String, byte[]&gt; 
attr : scan.getAttributesMap().entrySet()) {<a name="line.248"></a>
+<span class="sourceLineNo">249</span>      setAttribute(attr.getKey(), 
attr.getValue());<a name="line.249"></a>
+<span class="sourceLineNo">250</span>    }<a name="line.250"></a>
+<span class="sourceLineNo">251</span>    for (Map.Entry&lt;byte[], 
TimeRange&gt; entry : scan.getColumnFamilyTimeRange().entrySet()) {<a 
name="line.251"></a>
+<span class="sourceLineNo">252</span>      TimeRange tr = entry.getValue();<a 
name="line.252"></a>
+<span class="sourceLineNo">253</span>      
setColumnFamilyTimeRange(entry.getKey(), tr.getMin(), tr.getMax());<a 
name="line.253"></a>
+<span class="sourceLineNo">254</span>    }<a name="line.254"></a>
+<span class="sourceLineNo">255</span>  }<a name="line.255"></a>
+<span class="sourceLineNo">256</span><a name="line.256"></a>
+<span class="sourceLineNo">257</span>  /**<a name="line.257"></a>
+<span class="sourceLineNo">258</span>   * Builds a scan object with the same 
specs as get.<a name="line.258"></a>
+<span class="sourceLineNo">259</span>   * @param get get to model scan after<a 
name="line.259"></a>
+<span class="sourceLineNo">260</span>   */<a name="line.260"></a>
+<span class="sourceLineNo">261</span>  public Scan(Get get) {<a 
name="line.261"></a>
+<span class="sourceLineNo">262</span>    this.startRow = get.getRow();<a 
name="line.262"></a>
+<span class="sourceLineNo">263</span>    this.stopRow = get.getRow();<a 
name="line.263"></a>
+<span class="sourceLineNo">264</span>    this.filter = get.getFilter();<a 
name="line.264"></a>
+<span class="sourceLineNo">265</span>    this.cacheBlocks = 
get.getCacheBlocks();<a name="line.265"></a>
+<span class="sourceLineNo">266</span>    this.maxVersions = 
get.getMaxVersions();<a name="line.266"></a>
+<span class="sourceLineNo">267</span>    this.storeLimit = 
get.getMaxResultsPerColumnFamily();<a name="line.267"></a>
+<span class="sourceLineNo">268</span>    this.storeOffset = 
get.getRowOffsetPerColumnFamily();<a name="line.268"></a>
+<span class="sourceLineNo">269</span>    this.tr = get.getTimeRange();<a 
name="line.269"></a>
+<span class="sourceLineNo">270</span>    this.familyMap = 
get.getFamilyMap();<a name="line.270"></a>
+<span class="sourceLineNo">271</span>    this.getScan = true;<a 
name="line.271"></a>
+<span class="sourceLineNo">272</span>    this.asyncPrefetch = false;<a 
name="line.272"></a>
+<span class="sourceLineNo">273</span>    this.consistency = 
get.getConsistency();<a name="line.273"></a>
+<span class="sourceLineNo">274</span>    
this.setIsolationLevel(get.getIsolationLevel());<a name="line.274"></a>
+<span class="sourceLineNo">275</span>    this.loadColumnFamiliesOnDemand = 
get.getLoadColumnFamiliesOnDemandValue();<a name="line.275"></a>
 <span class="sourceLineNo">276</span>    for (Map.Entry&lt;String, byte[]&gt; 
attr : get.getAttributesMap().entrySet()) {<a name="line.276"></a>
 <span class="sourceLineNo">277</span>      setAttribute(attr.getKey(), 
attr.getValue());<a name="line.277"></a>
 <span class="sourceLineNo">278</span>    }<a name="line.278"></a>
@@ -761,261 +761,229 @@
 <span class="sourceLineNo">753</span>    return allowPartialResults;<a 
name="line.753"></a>
 <span class="sourceLineNo">754</span>  }<a name="line.754"></a>
 <span class="sourceLineNo">755</span><a name="line.755"></a>
-<span class="sourceLineNo">756</span>  /**<a name="line.756"></a>
-<span class="sourceLineNo">757</span>   * Set the value indicating whether 
loading CFs on demand should be allowed (cluster<a name="line.757"></a>
-<span class="sourceLineNo">758</span>   * default is false). On-demand CF 
loading doesn't load column families until necessary, e.g.<a 
name="line.758"></a>
-<span class="sourceLineNo">759</span>   * if you filter on one column, the 
other column family data will be loaded only for the rows<a name="line.759"></a>
-<span class="sourceLineNo">760</span>   * that are included in result, not all 
rows like in normal case.<a name="line.760"></a>
-<span class="sourceLineNo">761</span>   * With column-specific filters, like 
SingleColumnValueFilter w/filterIfMissing == true,<a name="line.761"></a>
-<span class="sourceLineNo">762</span>   * this can deliver huge perf gains 
when there's a cf with lots of data; however, it can<a name="line.762"></a>
-<span class="sourceLineNo">763</span>   * also lead to some inconsistent 
results, as follows:<a name="line.763"></a>
-<span class="sourceLineNo">764</span>   * - if someone does a concurrent 
update to both column families in question you may get a row<a 
name="line.764"></a>
-<span class="sourceLineNo">765</span>   *   that never existed, e.g. for { 
rowKey = 5, { cat_videos =&amp;gt; 1 }, { video =&amp;gt; "my cat" } }<a 
name="line.765"></a>
-<span class="sourceLineNo">766</span>   *   someone puts rowKey 5 with { 
cat_videos =&amp;gt; 0 }, { video =&amp;gt; "my dog" }, concurrent scan<a 
name="line.766"></a>
-<span class="sourceLineNo">767</span>   *   filtering on "cat_videos == 1" can 
get { rowKey = 5, { cat_videos =&amp;gt; 1 },<a name="line.767"></a>
-<span class="sourceLineNo">768</span>   *   { video =&amp;gt; "my dog" } }.<a 
name="line.768"></a>
-<span class="sourceLineNo">769</span>   * - if there's a concurrent split and 
you have more than 2 column families, some rows may be<a name="line.769"></a>
-<span class="sourceLineNo">770</span>   *   missing some column families.<a 
name="line.770"></a>
-<span class="sourceLineNo">771</span>   */<a name="line.771"></a>
-<span class="sourceLineNo">772</span>  public Scan 
setLoadColumnFamiliesOnDemand(boolean value) {<a name="line.772"></a>
-<span class="sourceLineNo">773</span>    this.loadColumnFamiliesOnDemand = 
value;<a name="line.773"></a>
-<span class="sourceLineNo">774</span>    return this;<a name="line.774"></a>
-<span class="sourceLineNo">775</span>  }<a name="line.775"></a>
-<span class="sourceLineNo">776</span><a name="line.776"></a>
-<span class="sourceLineNo">777</span>  /**<a name="line.777"></a>
-<span class="sourceLineNo">778</span>   * Get the raw 
loadColumnFamiliesOnDemand setting; if it's not set, can be null.<a 
name="line.778"></a>
-<span class="sourceLineNo">779</span>   */<a name="line.779"></a>
-<span class="sourceLineNo">780</span>  public Boolean 
getLoadColumnFamiliesOnDemandValue() {<a name="line.780"></a>
-<span class="sourceLineNo">781</span>    return 
this.loadColumnFamiliesOnDemand;<a name="line.781"></a>
-<span class="sourceLineNo">782</span>  }<a name="line.782"></a>
-<span class="sourceLineNo">783</span><a name="line.783"></a>
-<span class="sourceLineNo">784</span>  /**<a name="line.784"></a>
-<span class="sourceLineNo">785</span>   * Get the logical value indicating 
whether on-demand CF loading should be allowed.<a name="line.785"></a>
-<span class="sourceLineNo">786</span>   */<a name="line.786"></a>
-<span class="sourceLineNo">787</span>  public boolean 
doLoadColumnFamiliesOnDemand() {<a name="line.787"></a>
-<span class="sourceLineNo">788</span>    return 
(this.loadColumnFamiliesOnDemand != null)<a name="line.788"></a>
-<span class="sourceLineNo">789</span>      &amp;&amp; 
this.loadColumnFamiliesOnDemand.booleanValue();<a name="line.789"></a>
-<span class="sourceLineNo">790</span>  }<a name="line.790"></a>
-<span class="sourceLineNo">791</span><a name="line.791"></a>
-<span class="sourceLineNo">792</span>  /**<a name="line.792"></a>
-<span class="sourceLineNo">793</span>   * Compile the table and column family 
(i.e. schema) information<a name="line.793"></a>
-<span class="sourceLineNo">794</span>   * into a String. Useful for parsing 
and aggregation by debugging,<a name="line.794"></a>
-<span class="sourceLineNo">795</span>   * logging, and administration tools.<a 
name="line.795"></a>
-<span class="sourceLineNo">796</span>   * @return Map<a name="line.796"></a>
-<span class="sourceLineNo">797</span>   */<a name="line.797"></a>
-<span class="sourceLineNo">798</span>  @Override<a name="line.798"></a>
-<span class="sourceLineNo">799</span>  public Map&lt;String, Object&gt; 
getFingerprint() {<a name="line.799"></a>
-<span class="sourceLineNo">800</span>    Map&lt;String, Object&gt; map = new 
HashMap&lt;String, Object&gt;();<a name="line.800"></a>
-<span class="sourceLineNo">801</span>    List&lt;String&gt; families = new 
ArrayList&lt;String&gt;();<a name="line.801"></a>
-<span class="sourceLineNo">802</span>    if(this.familyMap.size() == 0) {<a 
name="line.802"></a>
-<span class="sourceLineNo">803</span>      map.put("families", "ALL");<a 
name="line.803"></a>
-<span class="sourceLineNo">804</span>      return map;<a name="line.804"></a>
-<span class="sourceLineNo">805</span>    } else {<a name="line.805"></a>
-<span class="sourceLineNo">806</span>      map.put("families", families);<a 
name="line.806"></a>
-<span class="sourceLineNo">807</span>    }<a name="line.807"></a>
-<span class="sourceLineNo">808</span>    for (Map.Entry&lt;byte [], 
NavigableSet&lt;byte[]&gt;&gt; entry :<a name="line.808"></a>
-<span class="sourceLineNo">809</span>        this.familyMap.entrySet()) {<a 
name="line.809"></a>
-<span class="sourceLineNo">810</span>      
families.add(Bytes.toStringBinary(entry.getKey()));<a name="line.810"></a>
-<span class="sourceLineNo">811</span>    }<a name="line.811"></a>
-<span class="sourceLineNo">812</span>    return map;<a name="line.812"></a>
-<span class="sourceLineNo">813</span>  }<a name="line.813"></a>
-<span class="sourceLineNo">814</span><a name="line.814"></a>
-<span class="sourceLineNo">815</span>  /**<a name="line.815"></a>
-<span class="sourceLineNo">816</span>   * Compile the details beyond the scope 
of getFingerprint (row, columns,<a name="line.816"></a>
-<span class="sourceLineNo">817</span>   * timestamps, etc.) into a Map along 
with the fingerprinted information.<a name="line.817"></a>
-<span class="sourceLineNo">818</span>   * Useful for debugging, logging, and 
administration tools.<a name="line.818"></a>
-<span class="sourceLineNo">819</span>   * @param maxCols a limit on the number 
of columns output prior to truncation<a name="line.819"></a>
-<span class="sourceLineNo">820</span>   * @return Map<a name="line.820"></a>
-<span class="sourceLineNo">821</span>   */<a name="line.821"></a>
-<span class="sourceLineNo">822</span>  @Override<a name="line.822"></a>
-<span class="sourceLineNo">823</span>  public Map&lt;String, Object&gt; 
toMap(int maxCols) {<a name="line.823"></a>
-<span class="sourceLineNo">824</span>    // start with the fingerpring map and 
build on top of it<a name="line.824"></a>
-<span class="sourceLineNo">825</span>    Map&lt;String, Object&gt; map = 
getFingerprint();<a name="line.825"></a>
-<span class="sourceLineNo">826</span>    // map from families to column list 
replaces fingerprint's list of families<a name="line.826"></a>
-<span class="sourceLineNo">827</span>    Map&lt;String, List&lt;String&gt;&gt; 
familyColumns =<a name="line.827"></a>
-<span class="sourceLineNo">828</span>      new HashMap&lt;String, 
List&lt;String&gt;&gt;();<a name="line.828"></a>
-<span class="sourceLineNo">829</span>    map.put("families", familyColumns);<a 
name="line.829"></a>
-<span class="sourceLineNo">830</span>    // add scalar information first<a 
name="line.830"></a>
-<span class="sourceLineNo">831</span>    map.put("startRow", 
Bytes.toStringBinary(this.startRow));<a name="line.831"></a>
-<span class="sourceLineNo">832</span>    map.put("stopRow", 
Bytes.toStringBinary(this.stopRow));<a name="line.832"></a>
-<span class="sourceLineNo">833</span>    map.put("maxVersions", 
this.maxVersions);<a name="line.833"></a>
-<span class="sourceLineNo">834</span>    map.put("batch", this.batch);<a 
name="line.834"></a>
-<span class="sourceLineNo">835</span>    map.put("caching", this.caching);<a 
name="line.835"></a>
-<span class="sourceLineNo">836</span>    map.put("maxResultSize", 
this.maxResultSize);<a name="line.836"></a>
-<span class="sourceLineNo">837</span>    map.put("cacheBlocks", 
this.cacheBlocks);<a name="line.837"></a>
-<span class="sourceLineNo">838</span>    map.put("loadColumnFamiliesOnDemand", 
this.loadColumnFamiliesOnDemand);<a name="line.838"></a>
-<span class="sourceLineNo">839</span>    List&lt;Long&gt; timeRange = new 
ArrayList&lt;Long&gt;();<a name="line.839"></a>
-<span class="sourceLineNo">840</span>    timeRange.add(this.tr.getMin());<a 
name="line.840"></a>
-<span class="sourceLineNo">841</span>    timeRange.add(this.tr.getMax());<a 
name="line.841"></a>
-<span class="sourceLineNo">842</span>    map.put("timeRange", timeRange);<a 
name="line.842"></a>
-<span class="sourceLineNo">843</span>    int colCount = 0;<a 
name="line.843"></a>
-<span class="sourceLineNo">844</span>    // iterate through affected families 
and list out up to maxCols columns<a name="line.844"></a>
-<span class="sourceLineNo">845</span>    for (Map.Entry&lt;byte [], 
NavigableSet&lt;byte[]&gt;&gt; entry :<a name="line.845"></a>
-<span class="sourceLineNo">846</span>      this.familyMap.entrySet()) {<a 
name="line.846"></a>
-<span class="sourceLineNo">847</span>      List&lt;String&gt; columns = new 
ArrayList&lt;String&gt;();<a name="line.847"></a>
-<span class="sourceLineNo">848</span>      
familyColumns.put(Bytes.toStringBinary(entry.getKey()), columns);<a 
name="line.848"></a>
-<span class="sourceLineNo">849</span>      if(entry.getValue() == null) {<a 
name="line.849"></a>
-<span class="sourceLineNo">850</span>        colCount++;<a name="line.850"></a>
-<span class="sourceLineNo">851</span>        --maxCols;<a name="line.851"></a>
-<span class="sourceLineNo">852</span>        columns.add("ALL");<a 
name="line.852"></a>
-<span class="sourceLineNo">853</span>      } else {<a name="line.853"></a>
-<span class="sourceLineNo">854</span>        colCount += 
entry.getValue().size();<a name="line.854"></a>
-<span class="sourceLineNo">855</span>        if (maxCols &lt;= 0) {<a 
name="line.855"></a>
-<span class="sourceLineNo">856</span>          continue;<a name="line.856"></a>
-<span class="sourceLineNo">857</span>        }<a name="line.857"></a>
-<span class="sourceLineNo">858</span>        for (byte [] column : 
entry.getValue()) {<a name="line.858"></a>
-<span class="sourceLineNo">859</span>          if (--maxCols &lt;= 0) {<a 
name="line.859"></a>
-<span class="sourceLineNo">860</span>            continue;<a 
name="line.860"></a>
-<span class="sourceLineNo">861</span>          }<a name="line.861"></a>
-<span class="sourceLineNo">862</span>          
columns.add(Bytes.toStringBinary(column));<a name="line.862"></a>
-<span class="sourceLineNo">863</span>        }<a name="line.863"></a>
-<span class="sourceLineNo">864</span>      }<a name="line.864"></a>
-<span class="sourceLineNo">865</span>    }<a name="line.865"></a>
-<span class="sourceLineNo">866</span>    map.put("totalColumns", colCount);<a 
name="line.866"></a>
-<span class="sourceLineNo">867</span>    if (this.filter != null) {<a 
name="line.867"></a>
-<span class="sourceLineNo">868</span>      map.put("filter", 
this.filter.toString());<a name="line.868"></a>
-<span class="sourceLineNo">869</span>    }<a name="line.869"></a>
-<span class="sourceLineNo">870</span>    // add the id if set<a 
name="line.870"></a>
-<span class="sourceLineNo">871</span>    if (getId() != null) {<a 
name="line.871"></a>
-<span class="sourceLineNo">872</span>      map.put("id", getId());<a 
name="line.872"></a>
-<span class="sourceLineNo">873</span>    }<a name="line.873"></a>
-<span class="sourceLineNo">874</span>    return map;<a name="line.874"></a>
-<span class="sourceLineNo">875</span>  }<a name="line.875"></a>
-<span class="sourceLineNo">876</span><a name="line.876"></a>
-<span class="sourceLineNo">877</span>  /**<a name="line.877"></a>
-<span class="sourceLineNo">878</span>   * Enable/disable "raw" mode for this 
scan.<a name="line.878"></a>
-<span class="sourceLineNo">879</span>   * If "raw" is enabled the scan will 
return all<a name="line.879"></a>
-<span class="sourceLineNo">880</span>   * delete marker and deleted rows that 
have not<a name="line.880"></a>
-<span class="sourceLineNo">881</span>   * been collected, yet.<a 
name="line.881"></a>
-<span class="sourceLineNo">882</span>   * This is mostly useful for Scan on 
column families<a name="line.882"></a>
-<span class="sourceLineNo">883</span>   * that have KEEP_DELETED_ROWS 
enabled.<a name="line.883"></a>
-<span class="sourceLineNo">884</span>   * It is an error to specify any column 
when "raw" is set.<a name="line.884"></a>
-<span class="sourceLineNo">885</span>   * @param raw True/False to 
enable/disable "raw" mode.<a name="line.885"></a>
-<span class="sourceLineNo">886</span>   */<a name="line.886"></a>
-<span class="sourceLineNo">887</span>  public Scan setRaw(boolean raw) {<a 
name="line.887"></a>
-<span class="sourceLineNo">888</span>    setAttribute(RAW_ATTR, 
Bytes.toBytes(raw));<a name="line.888"></a>
-<span class="sourceLineNo">889</span>    return this;<a name="line.889"></a>
-<span class="sourceLineNo">890</span>  }<a name="line.890"></a>
-<span class="sourceLineNo">891</span><a name="line.891"></a>
-<span class="sourceLineNo">892</span>  /**<a name="line.892"></a>
-<span class="sourceLineNo">893</span>   * @return True if this Scan is in 
"raw" mode.<a name="line.893"></a>
-<span class="sourceLineNo">894</span>   */<a name="line.894"></a>
-<span class="sourceLineNo">895</span>  public boolean isRaw() {<a 
name="line.895"></a>
-<span class="sourceLineNo">896</span>    byte[] attr = 
getAttribute(RAW_ATTR);<a name="line.896"></a>
-<span class="sourceLineNo">897</span>    return attr == null ? false : 
Bytes.toBoolean(attr);<a name="line.897"></a>
-<span class="sourceLineNo">898</span>  }<a name="line.898"></a>
-<span class="sourceLineNo">899</span><a name="line.899"></a>
-<span class="sourceLineNo">900</span><a name="line.900"></a>
-<span class="sourceLineNo">901</span><a name="line.901"></a>
-<span class="sourceLineNo">902</span>  /**<a name="line.902"></a>
-<span class="sourceLineNo">903</span>   * Set whether this scan is a small 
scan<a name="line.903"></a>
-<span class="sourceLineNo">904</span>   * &lt;p&gt;<a name="line.904"></a>
-<span class="sourceLineNo">905</span>   * Small scan should use pread and big 
scan can use seek + read<a name="line.905"></a>
-<span class="sourceLineNo">906</span>   *<a name="line.906"></a>
-<span class="sourceLineNo">907</span>   * seek + read is fast but can cause 
two problem (1) resource contention (2)<a name="line.907"></a>
-<span class="sourceLineNo">908</span>   * cause too much network io<a 
name="line.908"></a>
-<span class="sourceLineNo">909</span>   *<a name="line.909"></a>
-<span class="sourceLineNo">910</span>   * [89-fb] Using pread for 
non-compaction read request<a name="line.910"></a>
-<span class="sourceLineNo">911</span>   * 
https://issues.apache.org/jira/browse/HBASE-7266<a name="line.911"></a>
-<span class="sourceLineNo">912</span>   *<a name="line.912"></a>
-<span class="sourceLineNo">913</span>   * On the other hand, if setting it 
true, we would do<a name="line.913"></a>
-<span class="sourceLineNo">914</span>   * openScanner,next,closeScanner in one 
RPC call. It means the better<a name="line.914"></a>
-<span class="sourceLineNo">915</span>   * performance for small scan. 
[HBASE-9488].<a name="line.915"></a>
-<span class="sourceLineNo">916</span>   *<a name="line.916"></a>
-<span class="sourceLineNo">917</span>   * Generally, if the scan range is 
within one data block(64KB), it could be<a name="line.917"></a>
-<span class="sourceLineNo">918</span>   * considered as a small scan.<a 
name="line.918"></a>
-<span class="sourceLineNo">919</span>   *<a name="line.919"></a>
-<span class="sourceLineNo">920</span>   * @param small<a name="line.920"></a>
-<span class="sourceLineNo">921</span>   */<a name="line.921"></a>
-<span class="sourceLineNo">922</span>  public Scan setSmall(boolean small) {<a 
name="line.922"></a>
-<span class="sourceLineNo">923</span>    this.small = small;<a 
name="line.923"></a>
-<span class="sourceLineNo">924</span>    return this;<a name="line.924"></a>
-<span class="sourceLineNo">925</span>  }<a name="line.925"></a>
-<span class="sourceLineNo">926</span><a name="line.926"></a>
-<span class="sourceLineNo">927</span>  /**<a name="line.927"></a>
-<span class="sourceLineNo">928</span>   * Get whether this scan is a small 
scan<a name="line.928"></a>
-<span class="sourceLineNo">929</span>   * @return true if small scan<a 
name="line.929"></a>
-<span class="sourceLineNo">930</span>   */<a name="line.930"></a>
-<span class="sourceLineNo">931</span>  public boolean isSmall() {<a 
name="line.931"></a>
-<span class="sourceLineNo">932</span>    return small;<a name="line.932"></a>
-<span class="sourceLineNo">933</span>  }<a name="line.933"></a>
-<span class="sourceLineNo">934</span><a name="line.934"></a>
-<span class="sourceLineNo">935</span>  @Override<a name="line.935"></a>
-<span class="sourceLineNo">936</span>  public Scan setAttribute(String name, 
byte[] value) {<a name="line.936"></a>
-<span class="sourceLineNo">937</span>    return (Scan) 
super.setAttribute(name, value);<a name="line.937"></a>
-<span class="sourceLineNo">938</span>  }<a name="line.938"></a>
-<span class="sourceLineNo">939</span><a name="line.939"></a>
-<span class="sourceLineNo">940</span>  @Override<a name="line.940"></a>
-<span class="sourceLineNo">941</span>  public Scan setId(String id) {<a 
name="line.941"></a>
-<span class="sourceLineNo">942</span>    return (Scan) super.setId(id);<a 
name="line.942"></a>
-<span class="sourceLineNo">943</span>  }<a name="line.943"></a>
-<span class="sourceLineNo">944</span><a name="line.944"></a>
-<span class="sourceLineNo">945</span>  @Override<a name="line.945"></a>
-<span class="sourceLineNo">946</span>  public Scan 
setAuthorizations(Authorizations authorizations) {<a name="line.946"></a>
-<span class="sourceLineNo">947</span>    return (Scan) 
super.setAuthorizations(authorizations);<a name="line.947"></a>
-<span class="sourceLineNo">948</span>  }<a name="line.948"></a>
-<span class="sourceLineNo">949</span><a name="line.949"></a>
-<span class="sourceLineNo">950</span>  @Override<a name="line.950"></a>
-<span class="sourceLineNo">951</span>  public Scan setACL(Map&lt;String, 
Permission&gt; perms) {<a name="line.951"></a>
-<span class="sourceLineNo">952</span>    return (Scan) super.setACL(perms);<a 
name="line.952"></a>
-<span class="sourceLineNo">953</span>  }<a name="line.953"></a>
-<span class="sourceLineNo">954</span><a name="line.954"></a>
-<span class="sourceLineNo">955</span>  @Override<a name="line.955"></a>
-<span class="sourceLineNo">956</span>  public Scan setACL(String user, 
Permission perms) {<a name="line.956"></a>
-<span class="sourceLineNo">957</span>    return (Scan) super.setACL(user, 
perms);<a name="line.957"></a>
+<span class="sourceLineNo">756</span>  public Scan 
setLoadColumnFamiliesOnDemand(boolean value) {<a name="line.756"></a>
+<span class="sourceLineNo">757</span>    return (Scan) 
super.setLoadColumnFamiliesOnDemand(value);<a name="line.757"></a>
+<span class="sourceLineNo">758</span>  }<a name="line.758"></a>
+<span class="sourceLineNo">759</span><a name="line.759"></a>
+<span class="sourceLineNo">760</span>  /**<a name="line.760"></a>
+<span class="sourceLineNo">761</span>   * Compile the table and column family 
(i.e. schema) information<a name="line.761"></a>
+<span class="sourceLineNo">762</span>   * into a String. Useful for parsing 
and aggregation by debugging,<a name="line.762"></a>
+<span class="sourceLineNo">763</span>   * logging, and administration tools.<a 
name="line.763"></a>
+<span class="sourceLineNo">764</span>   * @return Map<a name="line.764"></a>
+<span class="sourceLineNo">765</span>   */<a name="line.765"></a>
+<span class="sourceLineNo">766</span>  @Override<a name="line.766"></a>
+<span class="sourceLineNo">767</span>  public Map&lt;String, Object&gt; 
getFingerprint() {<a name="line.767"></a>
+<span class="sourceLineNo">768</span>    Map&lt;String, Object&gt; map = new 
HashMap&lt;String, Object&gt;();<a name="line.768"></a>
+<span class="sourceLineNo">769</span>    List&lt;String&gt; families = new 
ArrayList&lt;String&gt;();<a name="line.769"></a>
+<span class="sourceLineNo">770</span>    if(this.familyMap.size() == 0) {<a 
name="line.770"></a>
+<span class="sourceLineNo">771</span>      map.put("families", "ALL");<a 
name="line.771"></a>
+<span class="sourceLineNo">772</span>      return map;<a name="line.772"></a>
+<span class="sourceLineNo">773</span>    } else {<a name="line.773"></a>
+<span class="sourceLineNo">774</span>      map.put("families", families);<a 
name="line.774"></a>
+<span class="sourceLineNo">775</span>    }<a name="line.775"></a>
+<span class="sourceLineNo">776</span>    for (Map.Entry&lt;byte [], 
NavigableSet&lt;byte[]&gt;&gt; entry :<a name="line.776"></a>
+<span class="sourceLineNo">777</span>        this.familyMap.entrySet()) {<a 
name="line.777"></a>
+<span class="sourceLineNo">778</span>      
families.add(Bytes.toStringBinary(entry.getKey()));<a name="line.778"></a>
+<span class="sourceLineNo">779</span>    }<a name="line.779"></a>
+<span class="sourceLineNo">780</span>    return map;<a name="line.780"></a>
+<span class="sourceLineNo">781</span>  }<a name="line.781"></a>
+<span class="sourceLineNo">782</span><a name="line.782"></a>
+<span class="sourceLineNo">783</span>  /**<a name="line.783"></a>
+<span class="sourceLineNo">784</span>   * Compile the details beyond the scope 
of getFingerprint (row, columns,<a name="line.784"></a>
+<span class="sourceLineNo">785</span>   * timestamps, etc.) into a Map along 
with the fingerprinted information.<a name="line.785"></a>
+<span class="sourceLineNo">786</span>   * Useful for debugging, logging, and 
administration tools.<a name="line.786"></a>
+<span class="sourceLineNo">787</span>   * @param maxCols a limit on the number 
of columns output prior to truncation<a name="line.787"></a>
+<span class="sourceLineNo">788</span>   * @return Map<a name="line.788"></a>
+<span class="sourceLineNo">789</span>   */<a name="line.789"></a>
+<span class="sourceLineNo">790</span>  @Override<a name="line.790"></a>
+<span class="sourceLineNo">791</span>  public Map&lt;String, Object&gt; 
toMap(int maxCols) {<a name="line.791"></a>
+<span class="sourceLineNo">792</span>    // start with the fingerpring map and 
build on top of it<a name="line.792"></a>
+<span class="sourceLineNo">793</span>    Map&lt;String, Object&gt; map = 
getFingerprint();<a name="line.793"></a>
+<span class="sourceLineNo">794</span>    // map from families to column list 
replaces fingerprint's list of families<a name="line.794"></a>
+<span class="sourceLineNo">795</span>    Map&lt;String, List&lt;String&gt;&gt; 
familyColumns =<a name="line.795"></a>
+<span class="sourceLineNo">796</span>      new HashMap&lt;String, 
List&lt;String&gt;&gt;();<a name="line.796"></a>
+<span class="sourceLineNo">797</span>    map.put("families", familyColumns);<a 
name="line.797"></a>
+<span class="sourceLineNo">798</span>    // add scalar information first<a 
name="line.798"></a>
+<span class="sourceLineNo">799</span>    map.put("startRow", 
Bytes.toStringBinary(this.startRow));<a name="line.799"></a>
+<span class="sourceLineNo">800</span>    map.put("stopRow", 
Bytes.toStringBinary(this.stopRow));<a name="line.800"></a>
+<span class="sourceLineNo">801</span>    map.put("maxVersions", 
this.maxVersions);<a name="line.801"></a>
+<span class="sourceLineNo">802</span>    map.put("batch", this.batch);<a 
name="line.802"></a>
+<span class="sourceLineNo">803</span>    map.put("caching", this.caching);<a 
name="line.803"></a>
+<span class="sourceLineNo">804</span>    map.put("maxResultSize", 
this.maxResultSize);<a name="line.804"></a>
+<span class="sourceLineNo">805</span>    map.put("cacheBlocks", 
this.cacheBlocks);<a name="line.805"></a>
+<span class="sourceLineNo">806</span>    map.put("loadColumnFamiliesOnDemand", 
this.loadColumnFamiliesOnDemand);<a name="line.806"></a>
+<span class="sourceLineNo">807</span>    List&lt;Long&gt; timeRange = new 
ArrayList&lt;Long&gt;();<a name="line.807"></a>
+<span class="sourceLineNo">808</span>    timeRange.add(this.tr.getMin());<a 
name="line.808"></a>
+<span class="sourceLineNo">809</span>    timeRange.add(this.tr.getMax());<a 
name="line.809"></a>
+<span class="sourceLineNo">810</span>    map.put("timeRange", timeRange);<a 
name="line.810"></a>
+<span class="sourceLineNo">811</span>    int colCount = 0;<a 
name="line.811"></a>
+<span class="sourceLineNo">812</span>    // iterate through affected families 
and list out up to maxCols columns<a name="line.812"></a>
+<span class="sourceLineNo">813</span>    for (Map.Entry&lt;byte [], 
NavigableSet&lt;byte[]&gt;&gt; entry :<a name="line.813"></a>
+<span class="sourceLineNo">814</span>      this.familyMap.entrySet()) {<a 
name="line.814"></a>
+<span class="sourceLineNo">815</span>      List&lt;String&gt; columns = new 
ArrayList&lt;String&gt;();<a name="line.815"></a>
+<span class="sourceLineNo">816</span>      
familyColumns.put(Bytes.toStringBinary(entry.getKey()), columns);<a 
name="line.816"></a>
+<span class="sourceLineNo">817</span>      if(entry.getValue() == null) {<a 
name="line.817"></a>
+<span class="sourceLineNo">818</span>        colCount++;<a name="line.818"></a>
+<span class="sourceLineNo">819</span>        --maxCols;<a name="line.819"></a>
+<span class="sourceLineNo">820</span>        columns.add("ALL");<a 
name="line.820"></a>
+<span class="sourceLineNo">821</span>      } else {<a name="line.821"></a>
+<span class="sourceLineNo">822</span>        colCount += 
entry.getValue().size();<a name="line.822"></a>
+<span class="sourceLineNo">823</span>        if (maxCols &lt;= 0) {<a 
name="line.823"></a>
+<span class="sourceLineNo">824</span>          continue;<a name="line.824"></a>
+<span class="sourceLineNo">825</span>        }<a name="line.825"></a>
+<span class="sourceLineNo">826</span>        for (byte [] column : 
entry.getValue()) {<a name="line.826"></a>
+<span class="sourceLineNo">827</span>          if (--maxCols &lt;= 0) {<a 
name="line.827"></a>
+<span class="sourceLineNo">828</span>            continue;<a 
name="line.828"></a>
+<span class="sourceLineNo">829</span>          }<a name="line.829"></a>
+<span class="sourceLineNo">830</span>          
columns.add(Bytes.toStringBinary(column));<a name="line.830"></a>
+<span class="sourceLineNo">831</span>        }<a name="line.831"></a>
+<span class="sourceLineNo">832</span>      }<a name="line.832"></a>
+<span class="sourceLineNo">833</span>    }<a name="line.833"></a>
+<span class="sourceLineNo">834</span>    map.put("totalColumns", colCount);<a 
name="line.834"></a>
+<span class="sourceLineNo">835</span>    if (this.filter != null) {<a 
name="line.835"></a>
+<span class="sourceLineNo">836</span>      map.put("filter", 
this.filter.toString());<a name="line.836"></a>
+<span class="sourceLineNo">837</span>    }<a name="line.837"></a>
+<span class="sourceLineNo">838</span>    // add the id if set<a 
name="line.838"></a>
+<span class="sourceLineNo">839</span>    if (getId() != null) {<a 
name="line.839"></a>
+<span class="sourceLineNo">840</span>      map.put("id", getId());<a 
name="line.840"></a>
+<span class="sourceLineNo">841</span>    }<a name="line.841"></a>
+<span class="sourceLineNo">842</span>    return map;<a name="line.842"></a>
+<span class="sourceLineNo">843</span>  }<a name="line.843"></a>
+<span class="sourceLineNo">844</span><a name="line.844"></a>
+<span class="sourceLineNo">845</span>  /**<a name="line.845"></a>
+<span class="sourceLineNo">846</span>   * Enable/disable "raw" mode for this 
scan.<a name="line.846"></a>
+<span class="sourceLineNo">847</span>   * If "raw" is enabled the scan will 
return all<a name="line.847"></a>
+<span class="sourceLineNo">848</span>   * delete marker and deleted rows that 
have not<a name="line.848"></a>
+<span class="sourceLineNo">849</span>   * been collected, yet.<a 
name="line.849"></a>
+<span class="sourceLineNo">850</span>   * This is mostly useful for Scan on 
column families<a name="line.850"></a>
+<span class="sourceLineNo">851</span>   * that have KEEP_DELETED_ROWS 
enabled.<a name="line.851"></a>
+<span class="sourceLineNo">852</span>   * It is an error to specify any column 
when "raw" is set.<a name="line.852"></a>
+<span class="sourceLineNo">853</span>   * @param raw True/False to 
enable/disable "raw" mode.<a name="line.853"></a>
+<span class="sourceLineNo">854</span>   */<a name="line.854"></a>
+<span class="sourceLineNo">855</span>  public Scan setRaw(boolean raw) {<a 
name="line.855"></a>
+<span class="sourceLineNo">856</span>    setAttribute(RAW_ATTR, 
Bytes.toBytes(raw));<a name="line.856"></a>
+<span class="sourceLineNo">857</span>    return this;<a name="line.857"></a>
+<span class="sourceLineNo">858</span>  }<a name="line.858"></a>
+<span class="sourceLineNo">859</span><a name="line.859"></a>
+<span class="sourceLineNo">860</span>  /**<a name="line.860"></a>
+<span class="sourceLineNo">861</span>   * @return True if this Scan is in 
"raw" mode.<a name="line.861"></a>
+<span class="sourceLineNo">862</span>   */<a name="line.862"></a>
+<span class="sourceLineNo">863</span>  public boolean isRaw() {<a 
name="line.863"></a>
+<span class="sourceLineNo">864</span>    byte[] attr = 
getAttribute(RAW_ATTR);<a name="line.864"></a>
+<span class="sourceLineNo">865</span>    return attr == null ? false : 
Bytes.toBoolean(attr);<a name="line.865"></a>
+<span class="sourceLineNo">866</span>  }<a name="line.866"></a>
+<span class="sourceLineNo">867</span><a name="line.867"></a>
+<span class="sourceLineNo">868</span><a name="line.868"></a>
+<span class="sourceLineNo">869</span><a name="line.869"></a>
+<span class="sourceLineNo">870</span>  /**<a name="line.870"></a>
+<span class="sourceLineNo">871</span>   * Set whether this scan is a small 
scan<a name="line.871"></a>
+<span class="sourceLineNo">872</span>   * &lt;p&gt;<a name="line.872"></a>
+<span class="sourceLineNo">873</span>   * Small scan should use pread and big 
scan can use seek + read<a name="line.873"></a>
+<span class="sourceLineNo">874</span>   *<a name="line.874"></a>
+<span class="sourceLineNo">875</span>   * seek + read is fast but can cause 
two problem (1) resource contention (2)<a name="line.875"></a>
+<span class="sourceLineNo">876</span>   * cause too much network io<a 
name="line.876"></a>
+<span class="sourceLineNo">877</span>   *<a name="line.877"></a>
+<span class="sourceLineNo">878</span>   * [89-fb] Using pread for 
non-compaction read request<a name="line.878"></a>
+<span class="sourceLineNo">879</span>   * 
https://issues.apache.org/jira/browse/HBASE-7266<a name="line.879"></a>
+<span class="sourceLineNo">880</span>   *<a name="line.880"></a>
+<span class="sourceLineNo">881</span>   * On the other hand, if setting it 
true, we would do<a name="line.881"></a>
+<span class="sourceLineNo">882</span>   * openScanner,next,closeScanner in one 
RPC call. It means the better<a name="line.882"></a>
+<span class="sourceLineNo">883</span>   * performance for small scan. 
[HBASE-9488].<a name="line.883"></a>
+<span class="sourceLineNo">884</span>   *<a name="line.884"></a>
+<span class="sourceLineNo">885</span>   * Generally, if the scan range is 
within one data block(64KB), it could be<a name="line.885"></a>
+<span class="sourceLineNo">886</span>   * considered as a small scan.<a 
name="line.886"></a>
+<span class="sourceLineNo">887</span>   *<a name="line.887"></a>
+<span class="sourceLineNo">888</span>   * @param small<a name="line.888"></a>
+<span class="sourceLineNo">889</span>   */<a name="line.889"></a>
+<span class="sourceLineNo">890</span>  public Scan setSmall(boolean small) {<a 
name="line.890"></a>
+<span class="sourceLineNo">891</span>    this.small = small;<a 
name="line.891"></a>
+<span class="sourceLineNo">892</span>    return this;<a name="line.892"></a>
+<span class="sourceLineNo">893</span>  }<a name="line.893"></a>
+<span class="sourceLineNo">894</span><a name="line.894"></a>
+<span class="sourceLineNo">895</span>  /**<a name="line.895"></a>
+<span class="sourceLineNo">896</span>   * Get whether this scan is a small 
scan<a name="line.896"></a>
+<span class="sourceLineNo">897</span>   * @return true if small scan<a 
name="line.897"></a>
+<span class="sourceLineNo">898</span>   */<a name="line.898"></a>
+<span class="sourceLineNo">899</span>  public boolean isSmall() {<a 
name="line.899"></a>
+<span class="sourceLineNo">900</span>    return small;<a name="line.900"></a>
+<span class="sourceLineNo">901</span>  }<a name="line.901"></a>
+<span class="sourceLineNo">902</span><a name="line.902"></a>
+<span class="sourceLineNo">903</span>  @Override<a name="line.903"></a>
+<span class="sourceLineNo">904</span>  public Scan setAttribute(String name, 
byte[] value) {<a name="line.904"></a>
+<span class="sourceLineNo">905</span>    return (Scan) 
super.setAttribute(name, value);<a name="line.905"></a>
+<span class="sourceLineNo">906</span>  }<a name="line.906"></a>
+<span class="sourceLineNo">907</span><a name="line.907"></a>
+<span class="sourceLineNo">908</span>  @Override<a name="line.908"></a>
+<span class="sourceLineNo">909</span>  public Scan setId(String id) {<a 
name="line.909"></a>
+<span class="sourceLineNo">910</span>    return (Scan) super.setId(id);<a 
name="line.910"></a>
+<span class="sourceLineNo">911</span>  }<a name="line.911"></a>
+<span class="sourceLineNo">912</span><a name="line.912"></a>
+<span class="sourceLineNo">913</span>  @Override<a name="line.913"></a>
+<span class="sourceLineNo">914</span>  public Scan 
setAuthorizations(Authorizations authorizations) {<a name="line.914"></a>
+<span class="sourceLineNo">915</span>    return (Scan) 
super.setAuthorizations(authorizations);<a name="line.915"></a>
+<span class="sourceLineNo">916</span>  }<a name="line.916"></a>
+<span class="sourceLineNo">917</span><a name="line.917"></a>
+<span class="sourceLineNo">918</span>  @Override<a name="line.918"></a>
+<span class="sourceLineNo">919</span>  public Scan setACL(Map&lt;String, 
Permission&gt; perms) {<a name="line.919"></a>
+<span class="sourceLineNo">920</span>    return (Scan) super.setACL(perms);<a 
name="line.920"></a>
+<span class="sourceLineNo">921</span>  }<a name="line.921"></a>
+<span class="sourceLineNo">922</span><a name="line.922"></a>
+<span class="sourceLineNo">923</span>  @Override<a name="line.923"></a>
+<span class="sourceLineNo">924</span>  public Scan setACL(String user, 
Permission perms) {<a name="line.924"></a>
+<span class="sourceLineNo">925</span>    return (Scan) super.setACL(user, 
perms);<a name="line.925"></a>
+<span class="sourceLineNo">926</span>  }<a name="line.926"></a>
+<span class="sourceLineNo">927</span><a name="line.927"></a>
+<span class="sourceLineNo">928</span>  @Override<a name="line.928"></a>
+<span class="sourceLineNo">929</span>  public Scan setConsistency(Consistency 
consistency) {<a name="line.929"></a>
+<span class="sourceLineNo">930</span>    return (Scan) 
super.setConsistency(consistency);<a name="line.930"></a>
+<span class="sourceLineNo">931</span>  }<a name="line.931"></a>
+<span class="sourceLineNo">932</span><a name="line.932"></a>
+<span class="sourceLineNo">933</span>  @Override<a name="line.933"></a>
+<span class="sourceLineNo">934</span>  public Scan setReplicaId(int Id) {<a 
name="line.934"></a>
+<span class="sourceLineNo">935</span>    return (Scan) 
super.setReplicaId(Id);<a name="line.935"></a>
+<span class="sourceLineNo">936</span>  }<a name="line.936"></a>
+<span class="sourceLineNo">937</span><a name="line.937"></a>
+<span class="sourceLineNo">938</span>  @Override<a name="line.938"></a>
+<span class="sourceLineNo">939</span>  public Scan 
setIsolationLevel(IsolationLevel level) {<a name="line.939"></a>
+<span class="sourceLineNo">940</span>    return (Scan) 
super.setIsolationLevel(level);<a name="line.940"></a>
+<span class="sourceLineNo">941</span>  }<a name="line.941"></a>
+<span class="sourceLineNo">942</span><a name="line.942"></a>
+<span class="sourceLineNo">943</span>  /**<a name="line.943"></a>
+<span class="sourceLineNo">944</span>   * Enable collection of {@link 
ScanMetrics}. For advanced users.<a name="line.944"></a>
+<span class="sourceLineNo">945</span>   * @param enabled Set to true to enable 
accumulating scan metrics<a name="line.945"></a>
+<span class="sourceLineNo">946</span>   */<a name="line.946"></a>
+<span class="sourceLineNo">947</span>  public Scan setScanMetricsEnabled(final 
boolean enabled) {<a name="line.947"></a>
+<span class="sourceLineNo">948</span>    
setAttribute(Scan.SCAN_ATTRIBUTES_METRICS_ENABLE, 
Bytes.toBytes(Boolean.valueOf(enabled)));<a name="line.948"></a>
+<span class="sourceLineNo">949</span>    return this;<a name="line.949"></a>
+<span class="sourceLineNo">950</span>  }<a name="line.950"></a>
+<span class="sourceLineNo">951</span><a name="line.951"></a>
+<span class="sourceLineNo">952</span>  /**<a name="line.952"></a>
+<span class="sourceLineNo">953</span>   * @return True if collection of scan 
metrics is enabled. For advanced users.<a name="line.953"></a>
+<span class="sourceLineNo">954</span>   */<a name="line.954"></a>
+<span class="sourceLineNo">955</span>  public boolean isScanMetricsEnabled() 
{<a name="line.955"></a>
+<span class="sourceLineNo">956</span>    byte[] attr = 
getAttribute(Scan.SCAN_ATTRIBUTES_METRICS_ENABLE);<a name="line.956"></a>
+<span class="sourceLineNo">957</span>    return attr == null ? false : 
Bytes.toBoolean(attr);<a name="line.957"></a>
 <span class="sourceLineNo">958</span>  }<a name="line.958"></a>
 <span class="sourceLineNo">959</span><a name="line.959"></a>
-<span class="sourceLineNo">960</span>  @Override<a name="line.960"></a>
-<span class="sourceLineNo">961</span>  public Scan setConsistency(Consistency 
consistency) {<a name="line.961"></a>
-<span class="sourceLineNo">962</span>    return (Scan) 
super.setConsistency(consistency);<a name="line.962"></a>
-<span class="sourceLineNo">963</span>  }<a name="line.963"></a>
-<span class="sourceLineNo">964</span><a name="line.964"></a>
-<span class="sourceLineNo">965</span>  @Override<a name="line.965"></a>
-<span class="sourceLineNo">966</span>  public Scan setReplicaId(int Id) {<a 
name="line.966"></a>
-<span class="sourceLineNo">967</span>    return (Scan) 
super.setReplicaId(Id);<a name="line.967"></a>
+<span class="sourceLineNo">960</span>  /**<a name="line.960"></a>
+<span class="sourceLineNo">961</span>   * @return Metrics on this Scan, if 
metrics were enabled.<a name="line.961"></a>
+<span class="sourceLineNo">962</span>   * @see 
#setScanMetricsEnabled(boolean)<a name="line.962"></a>
+<span class="sourceLineNo">963</span>   */<a name="line.963"></a>
+<span class="sourceLineNo">964</span>  public ScanMetrics getScanMetrics() {<a 
name="line.964"></a>
+<span class="sourceLineNo">965</span>    byte [] bytes = 
getAttribute(Scan.SCAN_ATTRIBUTES_METRICS_DATA);<a name="line.965"></a>
+<span class="sourceLineNo">966</span>    if (bytes == null) return null;<a 
name="line.966"></a>
+<span class="sourceLineNo">967</span>    return 
ProtobufUtil.toScanMetrics(bytes);<a name="line.967"></a>
 <span class="sourceLineNo">968</span>  }<a name="line.968"></a>
 <span class="sourceLineNo">969</span><a name="line.969"></a>
-<span class="sourceLineNo">970</span>  @Override<a name="line.970"></a>
-<span class="sourceLineNo">971</span>  public Scan 
setIsolationLevel(IsolationLevel level) {<a name="line.971"></a>
-<span class="sourceLineNo">972</span>    return (Scan) 
super.setIsolationLevel(level);<a name="line.972"></a>
-<span class="sourceLineNo">973</span>  }<a name="line.973"></a>
-<span class="sourceLineNo">974</span><a name="line.974"></a>
-<span class="sourceLineNo">975</span>  /**<a name="line.975"></a>
-<span class="sourceLineNo">976</span>   * Enable collection of {@link 
ScanMetrics}. For advanced users.<a name="line.976"></a>
-<span class="sourceLineNo">977</span>   * @param enabled Set to true to enable 
accumulating scan metrics<a name="line.977"></a>
-<span class="sourceLineNo">978</span>   */<a name="line.978"></a>
-<span class="sourceLineNo">979</span>  public Scan setScanMetricsEnabled(final 
boolean enabled) {<a name="line.979"></a>
-<span class="sourceLineNo">980</span>    
setAttribute(Scan.SCAN_ATTRIBUTES_METRICS_ENABLE, 
Bytes.toBytes(Boolean.valueOf(enabled)));<a name="line.980"></a>
-<span class="sourceLineNo">981</span>    return this;<a name="line.981"></a>
-<span class="sourceLineNo">982</span>  }<a name="line.982"></a>
-<span class="sourceLineNo">983</span><a name="line.983"></a>
-<span class="sourceLineNo">984</span>  /**<a name="line.984"></a>
-<span class="sourceLineNo">985</span>   * @return True if collection of scan 
metrics is enabled. For advanced users.<a name="line.985"></a>
-<span class="sourceLineNo">986</span>   */<a name="line.986"></a>
-<span class="sourceLineNo">987</span>  public boolean isScanMetricsEnabled() 
{<a name="line.987"></a>
-<span class="sourceLineNo">988</span>    byte[] attr = 
getAttribute(Scan.SCAN_ATTRIBUTES_METRICS_ENABLE);<a name="line.988"></a>
-<span class="sourceLineNo">989</span>    return attr == null ? false : 
Bytes.toBoolean(attr);<a name="line.989"></a>
-<span class="sourceLineNo">990</span>  }<a name="line.990"></a>
-<span class="sourceLineNo">991</span><a name="line.991"></a>
-<span class="sourceLineNo">992</span>  /**<a name="line.992"></a>
-<span class="sourceLineNo">993</span>   * @return Metrics on this Scan, if 
metrics were enabled.<a name="line.993"></a>
-<span class="sourceLineNo">994</span>   * @see 
#setScanMetricsEnabled(boolean)<a name="line.994"></a>
-<span class="sourceLineNo">995</span>   */<a name="line.995"></a>
-<span class="sourceLineNo">996</span>  public ScanMetrics getScanMetrics() {<a 
name="line.996"></a>
-<span class="sourceLineNo">997</span>    byte [] bytes = 
getAttribute(Scan.SCAN_ATTRIBUTES_METRICS_DATA);<a name="line.997"></a>
-<span class="sourceLineNo">998</span>    if (bytes == null) return null;<a 
name="line.998"></a>
-<span class="sourceLineNo">999</span>    return 
ProtobufUtil.toScanMetrics(bytes);<a name="line.999"></a>
-<span class="sourceLineNo">1000</span>  }<a name="line.1000"></a>
-<span class="sourceLineNo">1001</span><a name="line.1001"></a>
-<span class="sourceLineNo">1002</span>  public Boolean isAsyncPrefetch() {<a 
name="line.1002"></a>
-<span class="sourceLineNo">1003</span>    return asyncPrefetch;<a 
name="line.1003"></a>
-<span class="sourceLineNo">1004</span>  }<a name="line.1004"></a>
-<span class="sourceLineNo">1005</span><a name="line.1005"></a>
-<span class="sourceLineNo">1006</span>  public Scan setAsyncPrefetch(boolean 
asyncPrefetch) {<a name="line.1006"></a>
-<span class="sourceLineNo">1007</span>    this.asyncPrefetch = 
asyncPrefetch;<a name="line.1007"></a>
-<span class="sourceLineNo">1008</span>    return this;<a name="line.1008"></a>
-<span class="sourceLineNo">1009</span>  }<a name="line.1009"></a>
-<span class="sourceLineNo">1010</span>}<a name="line.1010"></a>
+<span class="sourceLineNo">970</span>  public Boolean isAsyncPrefetch() {<a 
name="line.970"></a>
+<span class="sourceLineNo">971</span>    return asyncPrefetch;<a 
name="line.971"></a>
+<span class="sourceLineNo">972</span>  }<a name="line.972"></a>
+<span class="sourceLineNo">973</span><a name="line.973"></a>
+<span class="sourceLineNo">974</span>  public Scan setAsyncPrefetch(boolean 
asyncPrefetch) {<a name="line.974"></a>
+<span class="sourceLineNo">975</span>    this.asyncPrefetch = asyncPrefetch;<a 
name="line.975"></a>
+<span class="sourceLineNo">976</span>    return this;<a name="line.976"></a>
+<span class="sourceLineNo">977</span>  }<a name="line.977"></a>
+<span class="sourceLineNo">978</span>}<a name="line.978"></a>
 
 
 

Reply via email to