How to increase the number of threads

19 views
Skip to first unread message

Xiao Xiao

unread,
Oct 27, 2022, 10:03:22 AM10/27/22
to Lunaserv
Dear Nick,

When a layer loads 200 files, the web page displays very slowly. Meanwhile, the maximum number of thread "map_raster_layer" is 5.

I want to increase the number of threads to improve the page display speed.

So how to increase the number of threads?

Thanks much
Xiao

Nick Estes

unread,
Oct 27, 2022, 10:14:44 AM10/27/22
to Xiao Xiao, Lunaserv
The maximum threads that can run at a time is controlled by the web
server. There is no inherent limitation in Lunaserv for the level of
concurrency.

If you're using Passenger as recommended, start by looking at the
PassengerMaxPoolSize option. It defaults to 6, so that will need to be
increased to however many is appropriate for your server. Depending on
which web server is being used, there may also be client or pool size
options that need to be increased at the server level. The Passenger
documentation has details on optimizing these settings for standalone,
Nginx, and Apache.

Yes, 200 files will tend to render slowly in Lunaserv. If these are
individual stamps, you might not have a lot of options, but if these are
part of a larger tiled map, there are a couple of things you can try.
Using the stamp_db layer type can help with tiled maps since the db
query can limit the request to just the tiles needed for a given map
area. This won't help when you're zoomed out, but it will speed up as
you zoom into an area that way. The other option is to retile the data
into bigger tiles. If the libtiff on your system supports bigtiff, the
pyramidal tiff input files can be quite large, and a smaller number of
larger ptiffs tends to perform better in Lunaserv.

--Nick
> --
> You received this message because you are subscribed to the Google
> Groups "Lunaserv" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lunaserv+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/lunaserv/419ae296-25c1-45f2-b4ba-eb77af325463n%40googlegroups.com
> [1].
>
>
> Links:
> ------
> [1]
> https://groups.google.com/d/msgid/lunaserv/419ae296-25c1-45f2-b4ba-eb77af325463n%40googlegroups.com?utm_medium=email&utm_source=footer
Reply all
Reply to author
Forward
0 new messages