参考:http://techbackground.blogspot.tw/2013/03/if-you-are-new-to-openstack-you-may-be.html
If you are new to OpenStack you may be wondering what
ini files like this are all about. OpenStack services (Nova, Glance, Quantum etc) use
Paste Deployment to wire up middleware like authorisation, API extensions, request rate limiting etc. It helps to have a basic knowledge of this stuff for installing and troubleshooting. This post is a simple example based on this
presentation. Here I have put the various parts in different modules.
First the application in a module named app_layer which uses
WebOb
So this script reads the config file, and for each item in the pipeline list, it jumps to that section to find the module name and factory function name for it. Now it is possible to see how the http server can be setup so incoming requests will flow through a pipeline of functions that were returned by the factories.
So now by just editing the config file, you can swap out the auth for a different implementation, or remove it completely, or add more filters.