1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.hadoop.hbase.io.hfile.bucket;
20
21 import java.io.IOException;
22
23 import org.apache.hadoop.hbase.classification.InterfaceAudience;
24
25
26
27
28
29 @InterfaceAudience.Private
30 public class CacheFullException extends IOException {
31 private static final long serialVersionUID = 3265127301824638920L;
32 private int requestedSize, bucketIndex;
33
34 CacheFullException(int requestedSize, int bucketIndex) {
35 super();
36 this.requestedSize = requestedSize;
37 this.bucketIndex = bucketIndex;
38 }
39
40 public int bucketIndex() {
41 return bucketIndex;
42 }
43
44 public int requestedSize() {
45 return requestedSize;
46 }
47
48 @Override
49 public String toString() {
50 StringBuilder sb = new StringBuilder(1024);
51 sb.append("Allocator requested size ").append(requestedSize);
52 sb.append(" for bucket ").append(bucketIndex);
53 return sb.toString();
54 }
55 }