use of org.apache.phoenix.hbase.index.write.LeaveIndexActiveFailurePolicy in project phoenix by apache.
the class PhoenixTransactionalIndexer method start.
@Override
public void start(CoprocessorEnvironment e) throws IOException {
final RegionCoprocessorEnvironment env = (RegionCoprocessorEnvironment) e;
String serverName = env.getRegionServerServices().getServerName().getServerName();
codec = new PhoenixIndexCodec();
codec.initialize(env);
// setup the actual index writer
// For transactional tables, we keep the index active upon a write failure
// since we have the all versus none behavior for transactions.
this.writer = new IndexWriter(new LeaveIndexActiveFailurePolicy(), env, serverName + "-tx-index-writer");
}
Aggregations