[openstack-dev] Creating new resource in quantum + horizon

Akihiro MOTOKI amotoki at gmail.com
Mon Nov 5 12:29:12 UTC 2012


Hi,

When I implemented "Networks" panel, I usually did debuging with two steps:
(1) Does quantumclient get an expected data from quantum server?
(2) Does Horizon display an expected result?

According to your mail, quantumclient does not receive what you expect.
If so, debugging quantumclient can easily be done by using python
interactive shell as below:

I hope it will help you.

Akihiro

ubuntu at ostack03:~$ ipython
In [1]: from quantumclient.v2_0 import client as qclient
In [2]: client = qclient.Client(username='demo', password='usapro',
   ...:   tenant_name='demo', auth_url='http://127.0.0.1:5000/v2.0')
In [3]: client.list_networks()
Out[3]:
{u'networks': [{u'admin_state_up': True,
   u'id': u'ab6353ee-b450-4d95-913e-acadeaf59c2a',
   u'name': u'net1',
   u'router:external': False,
   u'shared': False,
   u'status': u'ACTIVE',
   u'subnets': [u'90047d46-3f8f-4882-95f5-87ccfe805b60'],
   u'tenant_id': u'0298dd211bc8401b91624af24e6e4a0b'},
  {u'admin_state_up': True,
   u'id': u'd4a48e33-40e4-415b-ba53-73f3669bd153',
   u'name': u'ext_net',
   u'router:external': True,
   u'shared': False,
   u'status': u'ACTIVE',
   u'subnets': [u'dd6c4e4f-dd44-4d5f-add0-1f8269a6824e'],
   u'tenant_id': u'16d3af901557496886140f1d72f468a4'}]}


2012/11/2 Srikanth Kumar Lingala <srikanthkumar.lingala at gmail.com>:
>
> Hi,
> I just want to get data from a custom table created in Quantum and show it
> in horizon.(Just like list networks in horizon)
> I followed same architecture followed for showing Networks in horizon.
> I am able to send the request to quantum-server. And query also executing
> fine and getting data as a hash dump. I am able to see those in
> quantum-server log.
> But, while displaying in horizon, it is showing 'Internal Server Error' in
> the browser.
> While debugging, I put debug logs to identify where it is getting problem.
> From these debug logs, quantum-server ovs-agent plug-in able to get the data
> from DB and sending. But, at quantumclient, I am not able get that data.
> Can you please let me know the steps while getting information from Quantum
> DB and sending it to quantumclient and then it in turn passes the
> information to organize in Horizon?
>
> --
> ----
> Srikanth.
>
>
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>

-- 
Akihiro MOTOKI <amotoki at gmail.com>



More information about the OpenStack-dev mailing list