apache/hadoop · error · IOException
owner is too long to be serialized!
Error message
owner is too long to be serialized!
What it means
AbstractDelegationTokenIdentifier.write guards Text serialization limits: the owner field exceeds Text.DEFAULT_MAX_LEN, so the identifier would not deserialize safely on the wire and serialization is refused.
Solutions
- Shorten the owner name: the delegation token owner exceeds the maximum length that can be serialized into the token identifier. Use a shorter user/principal name.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenIdentifier.java:220 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of apache/hadoop@2add963021 (2026-08-22).
Data as JSON: /api/errors/a85729082e4af896.
Report an issue: GitHub.
Appendix: source
Thrown at hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenIdentifier.java:220
masterKeyId = WritableUtils.readVInt(in);
}
@VisibleForTesting
void writeImpl(DataOutput out) throws IOException {
out.writeByte(VERSION);
owner.write(out);
renewer.write(out);
realUser.write(out);
WritableUtils.writeVLong(out, issueDate);
WritableUtils.writeVLong(out, maxDate);
WritableUtils.writeVInt(out, sequenceNumber);
WritableUtils.writeVInt(out, masterKeyId);
}
@Override
public void write(DataOutput out) throws IOException {
if (owner.getLength() > Text.DEFAULT_MAX_LEN) {
throw new IOException("owner is too long to be serialized!");
}
if (renewer.getLength() > Text.DEFAULT_MAX_LEN) {
throw new IOException("renewer is too long to be serialized!");
}
if (realUser.getLength() > Text.DEFAULT_MAX_LEN) {
throw new IOException("realuser is too long to be serialized!");
}
writeImpl(out);
}
@Override
public String toString() {
StringBuilder buffer = new StringBuilder();
buffer
.append(getKind())
.append(" owner=").append(owner)
.append(", renewer=").append(renewer)
.append(", realUser=").append(realUser)View on GitHub (pinned to 2add963021)