Single number scaling

After some difficult hours dealing with some architecture issues for my server application, I feel that I will need to use single player games to achieve my goal. Purely for the following reasons (justifying my smell):

  • I do not need to pass expensive objects to the call stack
  • I can perform functions on singleton control objects in any context. (A lot of code already exists, and therefore I do not want to rewrite extensive pieces of code that works differently).

In addition, the Singletones offer another problem. My server application is essentially a DLL with a class that can call multiple server instances. The server instance class contains singleton control objects. This is usually managed by the Windows service, so the server: machine ratio will be 1: 1.

Thus, you can view it as (where → is 1: 1, => 1: many):

MACHINE -> ServiceHost (Windows service?) -> Server Instance -> Singleton Management Objects

However, we would like to allow the SaaS model, which requires the service host (whether it be a Windows service or a Win32 application) to be able to run several servers, as required by business. Therefore, a physical machine can start a single server host, which will run multiple server instances.

What will happen (where → is 1: 1, => 1: a lot):

MACHINE → ServiceHost ( Windows?) = > → Singleton

, . . 1:1 .

, , , , / ?

, EXE ( WCF ), . , , .

+3
1

AppDomains ""?

+2

Source: https://habr.com/ru/post/1727757/


All Articles