Interface KafkaPrincipalSerde
-
public interface KafkaPrincipalSerde
Serializer/Deserializer interface forKafkaPrincipal
for the purpose of inter-broker forwarding. Any serialization/deserialization failure should raise aSerializationException
to be consistent.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description KafkaPrincipal
deserialize(byte[] bytes)
Deserialize aKafkaPrincipal
from byte array.byte[]
serialize(KafkaPrincipal principal)
Serialize aKafkaPrincipal
into byte array.
-
-
-
Method Detail
-
serialize
byte[] serialize(KafkaPrincipal principal) throws SerializationException
Serialize aKafkaPrincipal
into byte array.- Parameters:
principal
- principal to be serialized- Returns:
- serialized bytes
- Throws:
SerializationException
-
deserialize
KafkaPrincipal deserialize(byte[] bytes) throws SerializationException
Deserialize aKafkaPrincipal
from byte array.- Parameters:
bytes
- byte array to be deserialized- Returns:
- the deserialized principal
- Throws:
SerializationException
-
-