[MapProxy] Multiple URLs mapped to same WSGI MP config

Just van den Broecke just at justobjects.nl
Thu Mar 19 11:46:29 PDT 2015


Hi,

I need to map different URLs to the same WSGI MapProxy app and yaml file 
in Apache. From 
http://www.mediacore.com/blog/hosting-multiple-wsgi-applications-with-apache 
I learned that this can be done
with WSGIApplicationGroup %{GLOBAL}. Otherwise the first URL works ok, 
but any other URL will trigger an MP error:

../loader.py", line 1621, in load_configuration_file
[:error] [pid 20840] ...    if 'base' in current_dict:
[:error] [pid 20840] ... TypeError: argument of type 'NoneType' is not 
iterable

But if I use WSGIApplicationGroup as follows, it works ok:

     WSGIApplicationGroup
     WSGIScriptAlias /guest /var/mapproxy/config.py
     WSGIScriptAlias /user1 /var/mapproxy/config.py
     WSGIScriptAlias /user2 /var/mapproxy/config.py

config.py calls make_wsgi_app() always with the same .yaml file. I use 
not other WSGI-directives.

The question is: is this a safe thing to do or are there concurrency 
issues that may pop up at high load? Is this scenario what MultiMapProxy 
is meant for?

Best,

--Just








More information about the MapProxy mailing list