← Back to team overview

openstack team mailing list archive

[openstack] [nova-api] How to explain the 'POST' APIRouter in nova-api .release F?

 

Hi friends, I got the confused at the 'POST' Mapper Router in nova-api,
release F.

*code*:

self.resources['servers'] = servers.create_resource(ext_mgr)

    mapper.resource("server", "servers",

                    controller=self.resources['servers'],

                    collection={'detail': 'GET'},

                    member={'action': 'POST'})

ok, 'GET' is fine.

the 'GET' req, such as /v2/servers which coming from *nova list* cmd, the *
method* detail will be used to handler the req in
*controller*servers.Controller.

but how the 'POST', such as *cmd* nova pause <server>. Question list:

   1. what are the controller and action?
   2. how to explain the routing?

Tks all

Lawrency Meng
------------------------------

mail: mengql112233@xxxxxxxxx

phone: 13811465151