Hi all,

The following is more a best practices question.

We've been developing WSGI apps for a while, and also maintain a REST
server micro-framework. Our applications like everything else in the Python
world is made of micro-frameworks. We would typically use something like
webapp2 to serve out "pages" and then build APIs using prestans.

Both frameworks provide routers, and we end up having routes in Apache like

    Alias       /assets/        /srv/app/static/assets/
    Alias       /js/            /srv/app/static/js/

    WSGIScriptAliasMatch    ^/api/(.*)  /srv/app/wsgi/api.wsgi
    WSGIScriptAliasMatch    ^/(.*)      /srv/app/wsgi/app.wsgi

where the two WSGI endpoints point to routers provided by the two
frameworks.

Most examples (on mod_wsgi docs) and from seeing configuration of
mod_wsgi-express and frameworks like werkzeug seem to suggest that a WSGI
app should have a single WSGI endpoint, and then perhaps use a middleware
to wrap/dispatch the routes?

Is there a correct way of addressing this? Any thoughts / experiences?

If middlwares are the solution, any suggestions on where / which frameworks
to look at?

Many thanks for sparing your time.

-- 
You received this message because you are subscribed to the Google Groups 
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/d/optout.

Reply via email to