[MapProxy] tms request via gunicorn

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[MapProxy] tms request via gunicorn

andrew terry

Hi,

 

I’ve been following the mapproxy, gunicorn, eventlet, nginx demo and have a sticking point.

 

Direct calls to mapproxy tms demo work fine but when I do this via nginx/gunicorn I can get everything to work (e.g. WMS requests) but the tms is slow and regularly fails workers.

 

At the moment, I’m using proxy through nginx with an additional:

 

    location /mapproxy/demo/static {

        try_files $uri $uri/;

    }

 

Which allows me to load the demo site including html and css. I presume this is necessary to combat gunicorn static file issues but perhaps this is my first error.

 

From the gunicorn logging I see:

 

[2016-09-07 15:20:42 +0000] [2325] [DEBUG] GET /mapproxy/tms/1.0.0/test_wms_cache/EPSG27700/0/1/1.jpeg

[2016-09-07 15:21:11 +0000] [2319] [CRITICAL] WORKER TIMEOUT (pid:2325)

 

Whereas just mapproxy dev running direct works fine for:

 

[info] XXX.XXX.XXX.XXX - - [07/Sep/2016 14:52:19] "GET /tms/1.0.0/test_wms_cache/EPSG27700/0/1/1.jpeg HTTP/1.1" 200 –

 

Any pointers or prompts to where I can read more gratefully appreciated.

 

Andy


_______________________________________________
MapProxy mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapproxy
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] tms request via gunicorn

Travis Kirstine
Are you running gunicorn on a specific port and proxy request via nginx?

docs


On 7 September 2016 at 11:57, Andrew Terry <[hidden email]> wrote:

Hi,

 

I’ve been following the mapproxy, gunicorn, eventlet, nginx demo and have a sticking point.

 

Direct calls to mapproxy tms demo work fine but when I do this via nginx/gunicorn I can get everything to work (e.g. WMS requests) but the tms is slow and regularly fails workers.

 

At the moment, I’m using proxy through nginx with an additional:

 

    location /mapproxy/demo/static {

        try_files $uri $uri/;

    }

 

Which allows me to load the demo site including html and css. I presume this is necessary to combat gunicorn static file issues but perhaps this is my first error.

 

From the gunicorn logging I see:

 

[2016-09-07 15:20:42 +0000] [2325] [DEBUG] GET /mapproxy/tms/1.0.0/test_wms_cache/EPSG27700/0/1/1.jpeg

[2016-09-07 15:21:11 +0000] [2319] [CRITICAL] WORKER TIMEOUT (pid:2325)

 

Whereas just mapproxy dev running direct works fine for:

 

[info] XXX.XXX.XXX.XXX - - [07/Sep/2016 14:52:19] "GET /tms/1.0.0/test_wms_cache/EPSG27700/0/1/1.jpeg HTTP/1.1" 200 –

 

Any pointers or prompts to where I can read more gratefully appreciated.

 

Andy


_______________________________________________
MapProxy mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapproxy


_______________________________________________
MapProxy mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapproxy
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] tms request via gunicorn

Oliver Tonnhofer-3
In reply to this post by andrew terry
Hi,

> On 07.09.2016, at 17:57, Andrew Terry <[hidden email]> wrote:
>
> [...]
>
> From the gunicorn logging I see:
>
>  
>
> [2016-09-07 15:20:42 +0000] [2325] [DEBUG] GET /mapproxy/tms/1.0.0/test_wms_cache/EPSG27700/0/1/1.jpeg
>
> [2016-09-07 15:21:11 +0000] [2319] [CRITICAL] WORKER TIMEOUT (pid:2325)



I noticed yesterday that the latest gunicorn version does not work. Hanging requests and worker timeouts as you are seeing. Gunicorn 18.0.0 does work however. I just needed it for some testing, so I didn't spend any time to look for the cause.



Regards,
Oliver

--
Oliver Tonnhofer  | Omniscale GmbH & Co KG  | http://omniscale.com
OpenStreetMap WMS and tile services         | http://maps.omniscale.com



_______________________________________________
MapProxy mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapproxy
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] tms request via gunicorn

andrew terry
Hi Oliver,

I was convinced it was just me, wish I'd asked sooner!

Can confirm Gunicorn 18.0.0 has fixed the problem and also means my original inclusion of a try_files to point to static files (css etc) was actually superfluous and entirely optional.

Andy

-----Original Message-----

> I noticed yesterday that the latest gunicorn version does not work. Hanging requests and worker timeouts as you are seeing. Gunicorn 18.0.0 does work however. I just needed it for some testing, so I didn't spend any time to look for the cause.



_______________________________________________
MapProxy mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapproxy