The Staged Event-Driven Architecture (SEDA) is a new design for building scalable Internet services.

源代码在线查看: run-client.pl

软件大小: 597 K
上传用户: xackw
关键词: Event-Driven Architecture Internet building
下载地址: 免注册下载 普通下载 VIP

相关代码

				#!/usr/bin/perl								# Front-end script to run MultiClient save logs								if (($#ARGV != 3) && ($#ARGV != 4)) {				  print "Usage: run-client.pl [-p]    \n";				  print "Options:\n";				  print "\t-p\tDisplay output directly; do not send to file\n";				  exit -1;				}								$LOGDIR = shift;				if ($LOGDIR eq "-p") {				  $DIRECT_OUTPUT = 1;				  $LOGDIR = shift;				}				$SERVER = shift;				$NUMNODES = shift;				$NUMCLIENTTHREADS = shift;								$SENDMSGSIZE = 8192;				$SENDBURSTSIZE = 1000;				$RECVMSGSIZE = 32;				$RECVBURSTSIZE = 1;								if (!$DIRECT_OUTPUT) {				  if (system("mkdir -p $LOGDIR")) { die "Can't run mkdir\n"; }				}								$logfile = "$LOGDIR/LOG.$NUMNODES.$NUMCLIENTTHREADS.$SENDMSGSIZE.$SENDBURSTSIZE.$RECVMSGSIZE.$RECVBURSTSIZE";								if (!$DIRECT_OUTPUT) {				  $out = "> $logfile 2>&1";				} else {				  "2>&1";				}								$cmd = "rexec -n $NUMNODES java -ms256M -mx256M MultiClient $SERVER $NUMCLIENTTHREADS $SENDMSGSIZE $SENDBURSTSIZE $RECVMSGSIZE $RECVBURSTSIZE $out";				#$cmd = "safe-rexec -n $NUMNODES run-client-localdisk.sh $SERVER $NUMCLIENTTHREADS $SENDMSGSIZE $SENDBURSTSIZE $RECVMSGSIZE $RECVBURSTSIZE $out";								print STDERR "Running for $logfile\n";								system($cmd);							

相关资源