Giter Site home page Giter Site logo

Comments (4)

jaymell avatar jaymell commented on June 24, 2024

Hi, can you provide an example of what you're trying to do exactly?

from redis-rs.

0xAlcibiades avatar 0xAlcibiades commented on June 24, 2024

Hi, can you provide an example of what you're trying to do exactly?

So particularly I'm trying to set a binary value, a protobuf data structure, and then get it back out. The set works fine, but the get fails because the data is not valid utf-8. This works fine if I use pub/sub via this library and get_payload_bytes. So basically the reproducter would be to set a value to a key, where the value is not valid UTF8, and then try to get it back out with the higher level methods this library exposes.

from redis-rs.

jaymell avatar jaymell commented on June 24, 2024

If I do something like reading a binary file into a Vec and setting/retrieving a key with that data, I have no issues, so I'm still not sure I understand fully what you're running into. Can you possibly paste a snippet of code as an example?

from redis-rs.

0xAlcibiades avatar 0xAlcibiades commented on June 24, 2024

If I do something like reading a binary file into a Vec and setting/retrieving a key with that data, I have no issues, so I'm still not sure I understand fully what you're running into. Can you possibly paste a snippet of code as an example?

What I'm running into is that the get fails as not being a utf-8 string. I'll write up a reproducer. What I end up having to do is base64 encode to a string. What I'm doing is using the get and set methods to store protobuf in a redis key.

from redis-rs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.