@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); if (hasNamespace()) { hash = (37 * hash) + NAMESPACE_FIELD_NUMBER; hash = (53 * hash) + getNamespace().hashCode(); } if (hasQualifier()) { hash = (37 * hash) + QUALIFIER_FIELD_NUMBER; hash = (53 * hash) + getQualifier().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; }
public static TableName toTableName(HBaseProtos.TableName tableNamePB) { return TableName.valueOf(tableNamePB.getNamespace().asReadOnlyByteBuffer(), tableNamePB.getQualifier().asReadOnlyByteBuffer()); }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName)) { return super.equals(obj); } org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName other = (org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName) obj; boolean result = true; result = result && (hasNamespace() == other.hasNamespace()); if (hasNamespace()) { result = result && getNamespace() .equals(other.getNamespace()); } result = result && (hasQualifier() == other.hasQualifier()); if (hasQualifier()) { result = result && getQualifier() .equals(other.getQualifier()); } result = result && getUnknownFields().equals(other.getUnknownFields()); return result; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName)) { return super.equals(obj); } org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName other = (org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName) obj; boolean result = true; result = result && (hasNamespace() == other.hasNamespace()); if (hasNamespace()) { result = result && getNamespace() .equals(other.getNamespace()); } result = result && (hasQualifier() == other.hasQualifier()); if (hasQualifier()) { result = result && getQualifier() .equals(other.getQualifier()); } result = result && getUnknownFields().equals(other.getUnknownFields()); return result; }
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); if (hasNamespace()) { hash = (37 * hash) + NAMESPACE_FIELD_NUMBER; hash = (53 * hash) + getNamespace().hashCode(); } if (hasQualifier()) { hash = (37 * hash) + QUALIFIER_FIELD_NUMBER; hash = (53 * hash) + getQualifier().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; }
@Override public void handleMetadata(byte[] ownerMetadata) { ZooKeeperProtos.TableLock data = TableLockManager.fromBytes(ownerMetadata); String msg = "Table lock acquire attempt found:"; if (data != null) { msg = msg + String.format("[tableName=%s:%s, lockOwner=%s, threadId=%s, " + "purpose=%s, isShared=%s, createTime=%s]", data.getTableName().getNamespace().toStringUtf8(), data.getTableName().getQualifier().toStringUtf8(), ProtobufUtil.toServerName(data.getLockOwner()), data.getThreadId(), data.getPurpose(), data.getIsShared(), data.getCreateTime()); } if (data != null && data.hasCreateTime() && data.getCreateTime() < expireDate) { errorReporter.reportError(HBaseFsck.ErrorReporter.ERROR_CODE.EXPIRED_TABLE_LOCK, msg); } else { errorReporter.print(msg); } } };
@Override public void handleMetadata(byte[] ownerMetadata) { if (!LOG.isDebugEnabled()) { return; } ZooKeeperProtos.TableLock data = fromBytes(ownerMetadata); if (data == null) { return; } LOG.debug("Table is locked by " + String.format("[tableName=%s:%s, lockOwner=%s, threadId=%s, " + "purpose=%s, isShared=%s, createTime=%s]", data.getTableName().getNamespace().toStringUtf8(), data.getTableName().getQualifier().toStringUtf8(), ProtobufUtil.toServerName(data.getLockOwner()), data.getThreadId(), data.getPurpose(), data.getIsShared(), data.getCreateTime())); } };
public static TableName toTableName(HBaseProtos.TableName tableNamePB) { return TableName.valueOf(tableNamePB.getNamespace().asReadOnlyByteBuffer(), tableNamePB.getQualifier().asReadOnlyByteBuffer()); }
public Builder mergeFrom(org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName other) { if (other == org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName.getDefaultInstance()) return this; if (other.hasNamespace()) { setNamespace(other.getNamespace()); } if (other.hasQualifier()) { setQualifier(other.getQualifier()); } this.mergeUnknownFields(other.getUnknownFields()); return this; }
/** * <code>required bytes qualifier = 2;</code> */ public Builder clearQualifier() { bitField0_ = (bitField0_ & ~0x00000002); qualifier_ = getDefaultInstance().getQualifier(); onChanged(); return this; }
/** * <code>required bytes qualifier = 2;</code> */ public Builder clearQualifier() { bitField0_ = (bitField0_ & ~0x00000002); qualifier_ = getDefaultInstance().getQualifier(); onChanged(); return this; }
public Builder mergeFrom(org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName other) { if (other == org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.TableName.getDefaultInstance()) return this; if (other.hasNamespace()) { setNamespace(other.getNamespace()); } if (other.hasQualifier()) { setQualifier(other.getQualifier()); } this.mergeUnknownFields(other.getUnknownFields()); return this; }