How do you add an extension to python-novaclient?

Asked by Cosmin Dumitrache

Hi there,

I need to change python-novaclient to support a slightly different API that extends OpenStack. I need to add extra API calls or extra fields to existing API calls, etc.

I see that there is an extension mechanism built into novaclient, but I have not been able to find any documentation of how to write an extension.

I've found some sample extensions like this one [1] but I get problems (ERROR: 'module' object has no attribute 'do_zone_boot').

I would really appreciate if someone could point me to some documentation or a working example.

Thanks,

Cosmin

[1] http://pypi.python.org/simple/rax-diskconfig-python-novaclient-ext/

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu python-novaclient Edit question
Assignee:
No assignee Edit question
Solved by:
Cosmin Dumitrache
Solved:
Last query:
Last reply:
Revision history for this message
Miha Gašperšič (miha.gaspersic) said :
#1

Hi Cosmin,

I am aware, that documentation doesn't exists for python novaclient. I have had recently used some of this libraries, but I also didn't found any usefull documentation about it. I suggest you to read this page if you didn't and it might help you a bit on your journey of coding :) Link can be found here: http://pypi.python.org/pypi/python-novaclient/

If this helps you solve your question, please mark thread as solved.

Regards,
Miha

Revision history for this message
Cosmin Dumitrache (cosmin-dumitrache) said :
#2

Thanks Miha.

I did find an example that works fine which is probably a good starting point if anyone else stumbles across this post [1]

There is also this example on github [2] but it's not using the extension mechanism. Not exactly what I want.

If you can provide some more examples that would be great.

Cosmin

[1] http://linux.softpedia.com/get/Programming/Libraries/rax-instance-backup-python-novaclient-ext-80400.shtml
[2] https://github.com/cloudbuilders/simple_nova_extension