class FastJsonRedisSerializer<T>
        implements RedisSerializer<T> {
    private final Class<T> type;
    private FastJsonConfig fastJsonConfig = new FastJsonConfig();

    public FastJsonRedisSerializer(Class<T> type) {
        this.type = type;
    }

    public FastJsonConfig getFastJsonConfig() {
        return fastJsonConfig;
    }

    public void setFastJsonConfig(FastJsonConfig fastJsonConfig) {
        this.fastJsonConfig = fastJsonConfig;
    }

    @Override
    public byte[] serialize(T type) throws SerializationException {
        if (type == null) {
            return new byte[0];
        }
        try {
            return JSON.toJSONBytes(type, fastJsonConfig.getSerializeFilters(), fastJsonConfig.getSerializerFeatures());
        } catch (Exception ex) {
            throw new SerializationException("Could not serialize: " + ex.getMessage(), ex);
        }
    }

    @Override
    public T deserialize(byte[] bytes) throws SerializationException {<FILL_FUNCTION_BODY>}
}

        if (bytes == null || bytes.length == 0) {
            return null;
        }
        try {
            return JSON.parseObject(bytes, type, fastJsonConfig.getFeatures());
        } catch (Exception ex) {
            throw new SerializationException("Could not deserialize: " + ex.getMessage(), ex);
        }
    
<no_super_class>