diff options
author | nanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2003-05-27 02:37:47 +0000 |
---|---|---|
committer | nanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2003-05-27 02:37:47 +0000 |
commit | 564ee3e3e7f8f6852299e45d4f3df2dda60f458e (patch) | |
tree | 4e29adf0ff32aa02ff1ee0b3e0e2f67f11d5f62e | |
parent | 1949427cd9f1141fd82b203578f517c671114fa0 (diff) | |
download | ATCD-564ee3e3e7f8f6852299e45d4f3df2dda60f458e.tar.gz |
ChangeLogTag:Mon May 26 21:34:48 2003 Nanbor Wang <nanbor@cs.wustl.edu>
-rw-r--r-- | TAO/CIAO/ChangeLog | 10 | ||||
-rw-r--r-- | TAO/CIAO/tools/Simple_Component_Server/README | 33 | ||||
-rw-r--r-- | TAO/CIAO/tools/Simple_Component_Server/Simple_Component_Server.cpp | 23 |
3 files changed, 46 insertions, 20 deletions
diff --git a/TAO/CIAO/ChangeLog b/TAO/CIAO/ChangeLog index a955271438a..e4528c8099f 100644 --- a/TAO/CIAO/ChangeLog +++ b/TAO/CIAO/ChangeLog @@ -1,3 +1,13 @@ +Mon May 26 21:34:48 2003 Nanbor Wang <nanbor@cs.wustl.edu> + + * tools/Simple_Component_Server/Simple_Component_Server.cpp: + Change the IOR output logic to write the component IOR if one is + instatiated with the -c flag instead of the home IOR (when the + -c flag is not specified.) + + * tools/Simple_Component_Server/README: Updated documentation for + simple component server. + Mon May 26 21:13:10 2003 Nanbor Wang <nanbor@cs.wustl.edu> * tools/Simple_Component_Server/Simple_Server.idl: diff --git a/TAO/CIAO/tools/Simple_Component_Server/README b/TAO/CIAO/tools/Simple_Component_Server/README index b4e34da174e..47c0509284b 100644 --- a/TAO/CIAO/tools/Simple_Component_Server/README +++ b/TAO/CIAO/tools/Simple_Component_Server/README @@ -4,27 +4,34 @@ Summary ------- This directory contains an implmentation for a "simple" component -server. +server. It is simple because it circumvent the mechanism to read the +XML descriptors and therefore there's no way to configure the +container or the component server thru these XML descriptors. It is, +however, useful for testing the correct functioning of a single +component and its home (as you don't need to jump thru a bunch of +hoops to instantiate them for testing.) Running ------- To run the component server, invoke it from command line as foloowing: - Simple_Component_Server -i <config_file> -o <home_finder_ior_output_file> + Simple_Component_Server -c -i <config_file> -o <home or component ior_output_filename> -The <config_file> currently contains information the component server -needs to install component implementations. The detail format of the -file will be explained at the end of this file. This configuration -mechanism should eventually be replaced by the standard component -deployment interfaces so component are installed and instantiated -through a set of interfaces. +The <config_file> contains information the component server needs to +install component implementations. The detail format of the file will +be explained at the end of this file. This configuration mechanism +should eventually be replaced by the standard component deployment +interfaces so component are installed and instantiated through a set +of interfaces. -The <home_finder_ior_output_file> points to the file name where the -component server will output a IOR (for the HomeFinder interfaces) -hosted on the component server. Currently, Simple_Component_Server -always instantiates a HomeRegistrar service within the server process. +If "-c" flag is specify, the simple component server creates a +component writes the IOR for the component into the file specified by +-o flag. Otherwise, only the component home is instantiated and the +IOR for the home is written to the file. +The <ior_output_filename> points to the file name where the +component server will output the IOR to. Server Configuration: --------------------- @@ -56,6 +63,8 @@ Here's a breakdown of what each field contains: 5 -> Repo ID for the managed component interface 6 -> Canonical name for the installed component home. +** Currently, only the first 4 config values are used (field 0-3). + Todos ----- diff --git a/TAO/CIAO/tools/Simple_Component_Server/Simple_Component_Server.cpp b/TAO/CIAO/tools/Simple_Component_Server/Simple_Component_Server.cpp index 4606366dd7a..e8220ae8f5e 100644 --- a/TAO/CIAO/tools/Simple_Component_Server/Simple_Component_Server.cpp +++ b/TAO/CIAO/tools/Simple_Component_Server/Simple_Component_Server.cpp @@ -219,20 +219,27 @@ main (int argc, char *argv[]) // Implicit activation CIAO::Simple_Server_var server = servant->_this (); - CORBA::String_var str = - orb->object_to_string (server.in () - ACE_ENV_ARG_PARAMETER); - ACE_TRY_CHECK; - - write_IOR (str.in ()); + CORBA::String_var str; + Components::CCMObject_var temp; if (create_component != 0) { - Components::CCMObject_var temp - = server->get_component (ACE_ENV_SINGLE_ARG_PARAMETER); + temp = server->get_component (ACE_ENV_SINGLE_ARG_PARAMETER); + ACE_TRY_CHECK; + + str = orb->object_to_string (temp.in () + ACE_ENV_ARG_PARAMETER); + ACE_TRY_CHECK; + } + else + { + str = orb->object_to_string (server.in () + ACE_ENV_ARG_PARAMETER); ACE_TRY_CHECK; } + write_IOR (str.in ()); + ACE_DEBUG ((LM_DEBUG, "Running the simple generic server...\n")); |