3 This is a simple CORBA example that makes a grid of user defined size.
4 The grid can be imagined as a matrix with cells that can hold values.
5 This example creates a simple grid server with user defined sizes. If
6 the user does not define the size a default grid is created. The user
7 can give a value to be held in the grid.
9 run_test.pl : This is a perl script to run the server and client as :
14 This perl script runs the server and client and shuts down the server
17 Passing the Server IOR to Clients:
18 ---------------------------------
20 To keep this example simple, the server advertises its IOR in the
21 following manner - The server program writes its server object's IOR
22 to a ior_file. Later on, the client reads this IOR from the specified
23 ior_file and uses the <string_to_object> method to obtain a reference
26 For this mechanism to work, the file must be readable and writable. If
27 it doesn't exist, a new file is created by the server. Moreover, the
28 file path must be accessible to both the client and server.
30 If the client and server are on different machine, then there must be
31 a shared directory accessible by both. On UNIX system's this is
32 typically done via the NFS mount command. On Windows, the 'explorer'
33 application provides an option to share drives.
35 In general if no such file sharing option is available, then using the
36 the Naming Service mechanism is the only alternative, as described by
42 server [-d] [-o <ior_output_file>] [-n]
46 -d Debug flag (It is additive more -d flags will give debugging).
47 -o Outputs the ior to the file
48 The ior is the reference using which the client can interact with
49 the target server object.
50 -n Use the naming service
52 When the server is started, you should see as the first line of output
53 something that looks like
55 iiop:1.0//danzon.cs.wustl.edu:10015/P35ad159600081a38/child_poa/server
58 IOR:000000000000001649444c3a43756269745...
61 Using -d turns on debugging messages. This option is additive, i.e.,
62 the more -d options provided, the more debugging you can get. At the
63 moment, only 2 levels of debugging are implemented, and more than 2 -d
69 client [-d] [-x] [-f <Server_ior_file>] [-n iterations] [-k ior] [-n] [-p]
75 -x Tells the server to shutdown at the end of the test.
76 -f Reads the server ior from the file
78 -k IOR or The IOR can also be given in the format like file://[file.ior]
80 -n Use the naming service
81 -p A horizontal position of the grid where the value [v] is stored
82 -q A vertical position of the grid where the value [v] is stored
85 -v Value that needs to be stored in the grid.
87 The last four options ie. p,q,w,h,v have default values. So, if the client
88 is invoked without these options then default values of one or all are
91 You can either cut and paste the IOR from the server to the client
92 (with the -k option), have the client read the IOR from a file using
93 the -f option (this file is produced using the -o option of the
94 server), or use the naming service (with the -s option).