class ObjectRedisSerializer implements RedisSerializer<Object> {

    static final FastThreadLocal<ByteArrayOutputStream> STREAM_LOCAL = new FastThreadLocal<ByteArrayOutputStream>() {
        @Override
        protected ByteArrayOutputStream initialValue() {
            return new ByteArrayOutputStream(1024) {
                @Override
                public void close() {
                    reset();
                }
            };
        }
    };

    @Override
    @SneakyThrows
    public byte[] serialize(Object o) throws SerializationException {<FILL_FUNCTION_BODY>}

    @Override
    @SneakyThrows
    public Object deserialize(byte[] bytes) throws SerializationException {
        if (bytes == null) {
            return null;
        }
        try (ObjectInput input = Serializers
            .getDefault()
            .createInput(new ByteArrayInputStream(bytes))) {
            return SerializeUtils.readObject(input);
        } catch (Throwable e) {
            log.error(e.getMessage(), e);
            throw e;
        }
    }
}

        if (o == null) {
            return null;
        }
        ByteArrayOutputStream arr = STREAM_LOCAL.get();
        try (ObjectOutput output = Serializers.getDefault().createOutput(arr)) {

            SerializeUtils.writeObject(o, output);
            output.flush();

            return arr.toByteArray();
        } catch (Throwable e) {
            log.error(e.getMessage(), e);
            throw e;
        }
    
<no_super_class>