summaryrefslogtreecommitdiff
path: root/modules/CIAO/docs/tutorials/Quoter/Simple/descriptors/runNodeDaemons.pl
blob: 76b72fefe4fba847eaa934b4bb651568eb91460d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
    & eval 'exec perl -S $0 $argv:q'
    if 0;

# $Id$
# -*- perl -*-

use lib "$ENV{ACE_ROOT}/bin";
use PerlACE::TestTarget;

$tg_deamons = PerlACE::TestTarget::create_target (1) || die "Create target for ns failed\n";

$ior_base1 = "NodeApp1.ior";
$ior_file1 = $tg_deamons->LocalFile ($ior_base1);
$ior_base2 = "NodeApp2.ior";
$ior_file2 = $tg_deamons->LocalFile ($ior_base2);

#for ($iter = 0; $iter <= $#ARGV; $iter++) {
#    if ($ARGV[$iter] eq "-h" || $ARGV[$iter] eq "-?") {
#      print "Run_Test Perl script for NodeApplicationTest \n\n";
#      print "run_test \n";
#      print "\n";
#      print "-h                  -- prints this information\n";
#      exit 0;
#  }
#}

$ior_file1 = $tg_deamons->DeleteFile ($ior_base1);
$ior_file2 = $tg_deamons->DeleteFile ($ior_base2);

$CIAO_ROOT=$ENV{'CIAO_ROOT'};
$DANCE_ROOT=$ENV{'DANCE_ROOT'};

$SV1 = $tg_deamons->CreateProcess ("$DANCE_ROOT/bin/dance_node_manager",
                             "-ORBEndpoint iiop://localhost:30000 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -d 1000");

$SV2 = $tg_deamons->CreateProcess ("$DANCE_ROOT/bin/dance_node_manager",
                             "-ORBEndpoint iiop://localhost:40000 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -d 1000");

$SV1->Spawn ();
$SV2->Spawn ();

sleep (99999999999);