Plugin info api does not expose parent child relationships.

Bug #1557778 reported by Travis Tripp
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Searchlight
Fix Released
Medium
Lakshmi N Sampath

Bug Description

The plugin info api is missing the parent child relationships.

Changed in searchlight:
milestone: none → mitaka-rc1
assignee: nobody → Steve McLellan (sjmc7)
Changed in searchlight:
milestone: mitaka-rc1 → newton-1
Revision history for this message
Steve McLellan (sjmc7) wrote :

My suggestion is to add this inline. I would probably stop at one level (don't list grandchildren):

{
            "plugins": [
                {
                    "index": "searchlight-search",
                    "type": "OS::Designate::Zone",
                    "name": "OS::Designate::Zone",
                    "child_plugins": [
                        {
                            "type": "OS::Designate::RecordSet",
                            "parent_field": "zone_id"
                        }
                    ]
                },
                {
                    "index": "searchlight-search",
                    "type": "OS::Designate::RecordSet",
                    "name": "OS::Designate::RecordSet",
                    "parent_plugin": {
                        "type": "OS::Designate::Zone",
                        "parent_field": "zone_id"
                    }
                },
               {
                   "index": "searchlight-search",
                   "type": "OS::Swift::Container",
                   "name": "OS::Swift::Container",
                   "child_plugins": [
                       { ... blah OS::Swift::Object }
                   ],
                   "parent_plugin": { blah OS::Swift::Account }
                }
            ]
        }

Revision history for this message
Travis Tripp (travis-tripp) wrote :

i agree in not adding more than one level. the tree can be reconstructed from this.

Changed in searchlight:
assignee: Steve McLellan (sjmc7) → Lakshmi N Sampath (lakshmi-sampath)
Revision history for this message
Lakshmi N Sampath (lakshmi-sampath) wrote :

I currently coded it as a tree structure. Is flat structure the most useful for horizon use case? Or do we need both based on input to request?

Also i removed name since its just an alias for document type and not worth repeating same field twice.

{
    "plugins": [
        {
            "index": "searchlight-search",
            "type": "OS::Cinder::Volume",
            "children": {
                "index": "searchlight-search",
                "type": "OS::Cinder::Snapshot"
            }
        },
        {
            "index": "searchlight-search",
            "type": "OS::Glance::Image"
        },
        {
            "index": "searchlight-search",
            "type": "OS::Glance::Metadef"
        },
        {
            "index": "searchlight-search",
            "type": "OS::Neutron::Net",
            "children": {
                "index": "searchlight-search",
                "type": "OS::Neutron::Port"
            }
        },
        {
            "index": "searchlight-search",
            "type": "OS::Neutron::Router"
        },
        {
            "index": "searchlight-search",
            "type": "OS::Nova::Server"
        },
        {
            "index": "searchlight-search",
            "type": "OS::Swift::Account",
            "children": {
                "index": "searchlight-search",
                "type": "OS::Swift::Container",
                "children": {
                    "index": "searchlight-search",
                    "type": "OS::Swift::Object"
                }
            }
        }
    ]
}

Steve McLellan (sjmc7)
Changed in searchlight:
importance: Undecided → Medium
Revision history for this message
Steve McLellan (sjmc7) wrote :

Going to close this in favor of https://blueprints.launchpad.net/searchlight/+spec/disoverable-resource-type-relationships; parent-child relationships are a special case of those discoverable resource types.

Changed in searchlight:
status: New → Invalid
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to searchlight (master)

Reviewed: https://review.openstack.org/367021
Committed: https://git.openstack.org/cgit/openstack/searchlight/commit/?id=87fc192df307ec5fff559a784a776a31852833b2
Submitter: Jenkins
Branch: master

commit 87fc192df307ec5fff559a784a776a31852833b2
Author: Rick Aulino <email address hidden>
Date: Wed Sep 7 16:58:12 2016 -0600

    Disable returning options for the facet fields.

    Change-Id: Ia78a839d09c2f1d6e5a4f9adf8737a87e7dc89c9
    Closes-Bug: #1557778

Changed in searchlight:
status: Invalid → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/searchlight 1.0.0.0rc1

This issue was fixed in the openstack/searchlight 1.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.