1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.hadoop.hbase.backup;
20
21 import java.util.List;
22
23 import org.apache.hadoop.hbase.TableName;
24 import org.apache.hadoop.hbase.backup.BackupType;
25 import org.apache.hadoop.hbase.classification.InterfaceAudience;
26 import org.apache.hadoop.hbase.classification.InterfaceStability;
27
28
29
30
31 @InterfaceAudience.Public
32 @InterfaceStability.Evolving
33 public final class BackupRequest {
34 private BackupType type;
35 private List<TableName> tableList;
36 private String targetRootDir;
37 private int workers = -1;
38 private long bandwidth = -1L;
39
40 public BackupRequest() {
41 }
42
43 public BackupRequest setBackupType(BackupType type) {
44 this.type = type;
45 return this;
46 }
47 public BackupType getBackupType() {
48 return this.type;
49 }
50
51 public BackupRequest setTableList(List<TableName> tableList) {
52 this.tableList = tableList;
53 return this;
54 }
55 public List<TableName> getTableList() {
56 return this.tableList;
57 }
58
59 public BackupRequest setTargetRootDir(String targetRootDir) {
60 this.targetRootDir = targetRootDir;
61 return this;
62 }
63 public String getTargetRootDir() {
64 return this.targetRootDir;
65 }
66
67 public BackupRequest setWorkers(int workers) {
68 this.workers = workers;
69 return this;
70 }
71 public int getWorkers() {
72 return this.workers;
73 }
74
75 public BackupRequest setBandwidth(long bandwidth) {
76 this.bandwidth = bandwidth;
77 return this;
78 }
79 public long getBandwidth() {
80 return this.bandwidth;
81 }
82 }