Git Product home page Git Product logo

Comments (3)

dillaman avatar dillaman commented on June 30, 2024

It's not currently exposed via the API. Right now, the gwcli just grabs it directly. There are several things that the gwcli does directly and eventually it would be great to eliminate it's usage of python-rados/python-rbd.

from ceph-iscsi.

wwdillingham avatar wwdillingham commented on June 30, 2024

Thanks for info. Hmm I would love to be able to contribute something perhaps I can try not sure if I have the coding chops to do so but for those things that the API cant do directly is it feasible for the internals of the API to either use the same method gwcli uses or for the API to rely on the gwcli to facilitate grabbing the information? I know the gwcli relies on the API itself so its kind of backwards to do that, perhaps?

from ceph-iscsi.

dillaman avatar dillaman commented on June 30, 2024

The API is already hooked into and using python-rados and python-rbd, so it should be relatively straightforward.

I think the hardest part would be the full disk scan [1] since right now it uses multiple threads to open and extract metadata from images. If you have a lot of RBD images in-use for backing LUNs, you wouldn't necessarily want the REST API call to block for 10s of seconds while it gathers the data, so you might need to have it pre-cached and periodically refreshed in the background of the API.

There is also a disk-specific data gatherer [2] which wouldn't be too hard to just implement as a REST call since opening a single image in read-only mode should be relatively fast. For this case, you could probably tweak the existing /disk/<pool>/<image> REST API [3] to return the backing image meta-data (features, size, and snapshots).

[1] https://github.com/ceph/ceph-iscsi/blob/master/gwcli/storage.py#L55
[2] https://github.com/ceph/ceph-iscsi/blob/master/gwcli/storage.py#L746
[3] https://github.com/ceph/ceph-iscsi/blob/master/rbd-target-api.py#L978

from ceph-iscsi.

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.