@Test public void testToString() { ServerName hsa1 = ServerName.valueOf("localhost", 1234, -1L); HRegionLocation hrl1 = new HRegionLocation(HRegionInfo.FIRST_META_REGIONINFO, hsa1); System.out.println(hrl1.toString()); }
protected String getRegionDebugInfoSafe(Table table, byte[] rowKey) { HRegionLocation cached = null, real = null; try { cached = connection.getRegionLocation(tableName, rowKey, false); real = connection.getRegionLocation(tableName, rowKey, true); } catch (Throwable t) { // Cannot obtain region information for another catch block - too bad! } String result = "no information can be obtained"; if (cached != null) { result = "cached: " + cached.toString(); } if (real != null && real.getServerName() != null) { if (cached != null && cached.getServerName() != null && real.equals(cached)) { result += "; cache is up to date"; } else { result = (cached != null) ? (result + "; ") : ""; result += "real: " + real.toString(); } } return result; }
getConnection().relocateRegion(getTableName(), scan.getStartRow()); LOG.info("Scanner=" + scannerId + " expired, current region location is " + location.toString()); } catch (Throwable t) { LOG.info("Failed to relocate region", t);
private ScanResponse openScanner() throws IOException { incRPCCallsMetrics(scanMetrics, isRegionServerRemote); ScanRequest request = RequestConverter.buildScanRequest( getLocation().getRegionInfo().getRegionName(), this.scan, this.caching, false); try { ScanResponse response = getStub().scan(getRpcController(), request); long id = response.getScannerId(); if (logScannerActivity) { LOG.info("Open scanner=" + id + " for scan=" + scan.toString() + " on region " + getLocation().toString()); } if (response.hasMvccReadPoint()) { this.scan.setMvccReadPoint(response.getMvccReadPoint()); } this.scannerId = id; return response; } catch (Exception e) { throw ProtobufUtil.handleRemoteException(e); } }
LOG.info("Found " + firstGoodPair.toString());
getConnection().relocateRegion(getTableName(), scan.getStartRow()); LOG.info("Scanner=" + scannerId + " expired, current region location is " + location.toString()); } catch (Throwable t) { LOG.info("Failed to relocate region", t);
private ScanResponse openScanner() throws IOException { incRPCCallsMetrics(scanMetrics, isRegionServerRemote); ScanRequest request = RequestConverter.buildScanRequest( getLocation().getRegionInfo().getRegionName(), this.scan, this.caching, false); try { ScanResponse response = getStub().scan(getRpcController(), request); long id = response.getScannerId(); if (logScannerActivity) { LOG.info("Open scanner=" + id + " for scan=" + scan.toString() + " on region " + getLocation().toString()); } if (response.hasMvccReadPoint()) { this.scan.setMvccReadPoint(response.getMvccReadPoint()); } this.scannerId = id; return response; } catch (Exception e) { throw ProtobufUtil.handleRemoteException(e); } }
protected long openScanner() throws IOException { incRPCcallsMetrics(); long id = this.server.openScanner(this.location.getRegionInfo().getRegionName(), this.scan); if (logScannerActivity) { LOG.info("Open scanner=" + id + " for scan=" + scan.toString() + " on region " + this.location.toString() + " ip:" + this.location.getServerAddress().getBindAddress()); } return id; }
@Test public void testToString() { ServerName hsa1 = ServerName.valueOf("localhost", 1234, -1L); HRegionLocation hrl1 = new HRegionLocation(HRegionInfo.FIRST_META_REGIONINFO, hsa1); System.out.println(hrl1.toString()); }
connection.relocateRegion(tableName, scan.getStartRow()); LOG.info("Scanner=" + scannerId + " expired, current region location is " + location.toString() + " ip:" + location.getServerAddress().getBindAddress()); } catch (Throwable t) {
protected String getRegionDebugInfoSafe(Table table, byte[] rowKey) { HRegionLocation cached = null, real = null; try { cached = connection.getRegionLocation(tableName, rowKey, false); real = connection.getRegionLocation(tableName, rowKey, true); } catch (Throwable t) { // Cannot obtain region information for another catch block - too bad! } String result = "no information can be obtained"; if (cached != null) { result = "cached: " + cached.toString(); } if (real != null && real.getServerName() != null) { if (cached != null && cached.getServerName() != null && real.equals(cached)) { result += "; cache is up to date"; } else { result = (cached != null) ? (result + "; ") : ""; result += "real: " + real.toString(); } } return result; }
getConnection().relocateRegion(getTableName(), scan.getStartRow()); LOG.info("Scanner=" + scannerId + " expired, current region location is " + location.toString()); } catch (Throwable t) { LOG.info("Failed to relocate region", t);
private ScanResponse openScanner() throws IOException { incRPCCallsMetrics(scanMetrics, isRegionServerRemote); ScanRequest request = RequestConverter.buildScanRequest( getLocation().getRegionInfo().getRegionName(), this.scan, this.caching, false); try { ScanResponse response = getStub().scan(getRpcController(), request); long id = response.getScannerId(); if (logScannerActivity) { LOG.info("Open scanner=" + id + " for scan=" + scan.toString() + " on region " + getLocation().toString()); } if (response.hasMvccReadPoint()) { this.scan.setMvccReadPoint(response.getMvccReadPoint()); } this.scannerId = id; return response; } catch (Exception e) { throw ProtobufUtil.handleRemoteException(e); } }
protected long openScanner() throws IOException { incRPCcallsMetrics(); ScanRequest request = RequestConverter.buildScanRequest( getLocation().getRegionInfo().getRegionName(), this.scan, 0, false); try { ScanResponse response = getStub().scan(null, request); long id = response.getScannerId(); if (logScannerActivity) { LOG.info("Open scanner=" + id + " for scan=" + scan.toString() + " on region " + getLocation().toString()); } return id; } catch (ServiceException se) { throw ProtobufUtil.getRemoteException(se); } }
getConnection().relocateRegion(getTableName(), scan.getStartRow()); LOG.info("Scanner=" + scannerId + " expired, current region location is " + location.toString()); } catch (Throwable t) { LOG.info("Failed to relocate region", t);
LOG.info("Found " + firstGoodPair.toString());