@Nonnull
    @Override
    public byte[] serializeToByteArray(@Nonnull final Object object) {
        return SerializationUtils.serializeAndEncodeObject(cipher, (Serializable) object);
    }
This is {@link MessageQueueMessageSerializationHandler}.

@author Misagh Moayyed
@since 7.0.0
core/cas-server-core-tickets-api/src/main/java/org/apereo/cas/ticket/registry/pubsub/MessageQueueMessageSerializationHandler.java