Class JGroupsRaftSerializationException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.jgroups.raft.exceptions.JRaftException
org.jgroups.raft.exceptions.JGroupsRaftSerializationException
- All Implemented Interfaces:
Serializable
Exception thrown when serialization or deserialization operations fail.
This exception is thrown by the binary serialization framework when errors occur during object encoding or decoding. It wraps underlying I/O exceptions or other failures to provide a consistent exception hierarchy for JGroups Raft errors.
Common Causes
- I/O failures: Writing to or reading from streams fails
- Buffer overflow: Data exceeds buffer capacity (rare due to auto-growth)
- Encoding errors: String encoding fails (e.g., invalid UTF-8)
- Wire format errors: Corrupted data or version mismatches during deserialization
Handling Strategy
Serialization failures are typically non-recoverable at the serialization layer. Callers should:
- Log the error with full stack trace for debugging
- Propagate to higher layers (e.g., as a Raft command failure)
- Consider the operation failed (do not retry at serialization level)
- Since:
- 2.0
- Author:
- José Bolina
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class JRaftException
stacklessMethods inherited from class Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
JGroupsRaftSerializationException
-