FACT++  1.0
int main ( int  argc,
char *  argv[] 
)

Definition at line 8 of file benchServer.cxx.

References i, sprintf(), DimServer::start(), and DimService::updateService().

9 {
10  int i, msgSize, nServices, pid;
11  char *msg, servName[64];
12  DimService **services;
13 
14  if(argc){}
15  sscanf(argv[1],"%d",&msgSize);
16  sscanf(argv[2],"%d",&nServices);
17  msg = new char[msgSize];
18  services = new DimService*[nServices];
19 
20  pid = getpid();
21  for(i = 0; i < nServices; i++)
22  {
23  sprintf(servName,"BENCH_SERVICE_%d_%03d",pid, i);
24  services[i] = new DimService(servName, "C", msg, msgSize);
25  }
26  sprintf(servName,"BENCH_%d",pid);
27  DimServer::start(servName);
28  while(1)
29  {
30  for(i = 0; i < nServices; i++)
31  {
32  services[i]->updateService();
33  }
34  }
35  return 0;
36 }
int i
Definition: db_dim_client.c:21
int updateService()
Definition: discpp.cxx:1016
static void start()
Definition: discpp.cxx:512
sprintf(name1,"NewService%d", i)

+ Here is the call graph for this function: