go-ceph icon indicating copy to clipboard operation
go-ceph copied to clipboard

Support ceph-dencoder

Open mfatemipour opened this issue 2 years ago • 6 comments

Hi, Is there any plan to support decode/encode ceph structs ? like something that we have in ceph-dencoder tool

mfatemipour avatar Sep 03 '21 12:09 mfatemipour

Could you please post links to the features/tools in question? I'm not familiar with ceph-dencoder and just saying "encode/decode" could mean a lot of different things.

phlogistonjohn avatar Sep 03 '21 13:09 phlogistonjohn

@phlogistonjohn hi John, @mfatemipour might be referencing https://github.com/ceph/ceph/tree/master/src/tools/ceph-dencoder

tchaikov avatar Sep 03 '21 14:09 tchaikov

OK, I've also now looked at https://docs.ceph.com/en/latest/man/8/ceph-dencoder/ and have a rough idea of what the tool does. Unfortunately, I don't quite see how this fits in the grand scheme of things. Basically: if you would like someone else to implement this for you, we need to understand the use case - the why and the how - this would be used as part of go-ceph.

If you're more interested in contributing something, feel free to strike up a conversation or submit a prototype. :-)

phlogistonjohn avatar Sep 03 '21 14:09 phlogistonjohn

Actually I want to iterate on some rados objects and get some information about their manifets attribute (related to rgw), but rados get attributes as an encoded byte array, and there is not any programatically way to decode it unless using ceph-dencoder tool (as a exec cmd) that makes every procedure very very slow.

mfatemipour avatar Sep 06 '21 15:09 mfatemipour

Thanks @mfatemipour if I understand it correctly, you want to read data from rados that's not available in an API call and interpret the meaning.

So, we can look into it, but please do understand that if this isn't a fully-fledged C api that ceph provides it may be challenging to implement. I'm tagging this as a feature request now that I think I understand the request.

phlogistonjohn avatar Sep 07 '21 11:09 phlogistonjohn

/cc

iliul avatar Sep 08 '21 12:09 iliul