[prev in list] [next in list] [prev in thread] [next in thread]
List: mapguide-internals
Subject: =?gbk?Q?=BB=D8=B8=B4:RE:_[mapguide-internals]_How_can_MapGuide_?=
From: sftp <sftp () 163 ! com>
Date: 2009-02-23 5:44:25
Message-ID: 14127147.203501235367865564.JavaMail.coremail () bj163app58 ! 163 ! com
[Download RAW message or body]
Trevor Wekel,
Thank you very much!
Several days ago, I just wanted to know how the MapGuide server controls the number \
of connections for Client,Admin,Site separately. And i found no logic in the source \
code to limit the max connections for the services. So i read the source code of \
ClientAcceptor,ClientHandler and found ACE_Reactor and ACE_WFMO_Reactor ,then my \
original question came up.
Yesterday, i reread the source code and found the MgServerConnection implementation \
and found the sockets pool.
But i still have two question:
1. How did the MapGuide server control the max connections of each kind of service \
(client,admin,site)? 2. Imagine a extreme senario: If there are several WebTier \
process in the same/different machines, and they all have their own socket pool, if \
the sum of sockets are more than 64, the clientAcceptor can accept the connections, \
but the socket read/write operations will fail because the dispatcher can not \
dispatch more than 64 connections. Am i right?
> I have not looked deeply into the interaction between the MgClientAcceptor
> class and the ACE::reactor. It is possible that there may be a limitation
> on the number of connections to the server. From what I remember,
> MgClientAcceptor creates new connections and MgClientHandler handles the
> processing for these connections. Each MgClientHandler operates on a
> separate thread.
>
> > From an architectural perspective, I do not believe this will be a
> performance problem. The communications channel between the server and web
> tier has been designed to pool and reuse the TCP/IP connections between the
> two processes. This means a TCP/IP connection is only active when there is
> an actual service request (MgRenderingService, MgMappingService, etc) being
> performed. Once the request is completed, the connection is freed up to be
> used by another client.
>
> This means even with a limitation of 64 connections, the MapGuide Server
> would be simultaneously processing work on 64 separate threads. Since no
> manufacturer currently makes a machine with more than 24 cores, a 64
> connections/threads limit would still keep the MapGuide Server very busy.
>
> Are you trying to solve an issue related to
> http://trac.osgeo.org/mapguide/ticket/726?
>
> I did a quick check on the implementation of the web tier's connection logic
> (MgServerConnection, MgServerConnectionStack, etc). Even though we reuse
> connections, it looks as though we do not set a hard limit on the number of
> connections a web tier will make to the server. A large number of users
> running very slow operations could force the web tier to create more
> connections than the server can handle.
>
> We could add an additional parameter to webconfig.ini which puts a hard
> limit on the number of connections the web tier will create. The only
> problem with this approach is that the limit will be per process and apply
> to both the mapagent and any implementation of the web extensions (PHP,
> .Net, Java). This will get a bit tricky when web servers like IIS spin up
> multiple instances of these processes.
>
> Thanks,
> Trevor
>
>
> -----Original Message-----
> From: mapguide-internals-bounces@lists.osgeo.org
> [mailto:mapguide-internals-bounces@lists.osgeo.org] On Behalf Of sftp
> Sent: Sunday, February 22, 2009 12:46 AM
> To: mapguide-internals@lists.osgeo.org
> Subject: [mapguide-internals] How can MapGuide support more than 64
> connections on Windows ?
>
>
> I have read the source code and i found that it used ACE::reactor default
> implementation ACE_WFMO_Reactor on Windows.
> ACE_WFMO_Reactor can only handle no more than 64 handles in one thread, so
> how can
> MapGuide support more than 64 socket connections?
>
> Maybe I didn't understand the source code.
> Can anybody help me out?
> --
> View this message in context:
> http://n2.nabble.com/How-can-MapGuide-support-more-than-64-connections-on-Wi
> ndows---tp2366663p2366663.html
> Sent from the MapGuide Internals mailing list archive at Nabble.com.
>
> _______________________________________________
> mapguide-internals mailing list
> mapguide-internals@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-internals
>
> _______________________________________________
> mapguide-internals mailing list
> mapguide-internals@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-internals
_______________________________________________
mapguide-internals mailing list
mapguide-internals@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapguide-internals
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic