$Id: README 96760 2013-02-05 21:11:03Z stanleyk $

Here are a few tests for the ImplRepo.  The best way to test is to
use the run_test.pl passing it one of the following arguments:

airplane                  runs airplane client and server without ImplRepo.
airplane_ir               same as above but uses ImplRepo.
nt_service_ir             same as above but runs ImplRepo as an NT service.
nestea                    runs nestea client and server without ImplRepo.
nestea_ir                 same as above but uses ImplRepo.
both_ir                   combines airplane_ir and nestea_ir.
persistent_ir             same as airplane_ir, but using persistent
                          "-x <file>" flag for the ImplRepo.
persistent_ir_hash        same as persistent_ir, but using "-p <file>" flag.
persistent_ir_registry    same as persistent_ir, but using "-r" flag
                          (windows registry flag).
persistent_ir_shared      same as persistent_ir, but using
                          "--directory <dir>" flag.
persistent_ft             runs a primary and backup ImR Locator, verifying
                          persistence works in different scenarios of
                          the primary or backup being shutdown. Must also
                          pass the "-replica" command to run_test.pl for
                          this test to run.
failover                  runs a primary and backup ImR Locator, verifying
                          different scenarios of the primary or backup being
                          shutdown and clients, servers, activators, and
                          tao_imr activities being unaffected. Must also
                          pass the "-replica" command to run_test.pl for
                          this test to run.

The nt_service_ir and persistent_ir_registry tests will work only on Win32
platforms. For the test to run successfully, these conditions must be met:

--  The user must be logged in as administrator, or have administrative
    priveleges (in order to register an NT service).

--  ACE_ROOT must be set to the ACE_wrappers directory in the system
    environment.

--  ACE_ROOT/bin must be in the system path.

How to use NT ImR Services
==================================

The first step is to install one or both ImplRepo applications as NT
services. To do this run:

ImplRepo_Service -c install
ImR_Activator -c install

If you want to reinstall or change the installed settings then you
must first use:

ImplRepo_Service -c remove
ImR_Activator -c remove

Any extra command line options, will be saved in the Windows registry,
and used when the service is actually started.

In the following example I start the activator service, and then the
ImplRepo itself on port 8888 using iiop. I also tell the activator to use
xml as its persistence format, and to timeout unresponsive servers in 60 seconds.
I disable debug output for both, as there seems to be no way to access it anyway.

* copy the exe's to the same location as their dll's
cd %ace_root%\lib
copy %tao_root%\orbsvcs\ImplRepo_Service\*.exe .\

* Register the services. (You may have to remove them first)
ImR_Activator -c install -x activator.xml -t 60 -d 0 -orbinitref ImplRepoService=corbaloc::localhost:8888/ImplRepoService
ImplRepo_Service -c install -d 0 -orbendpoint iiop://:8888

* Start both services.
net start taoimrlocator
net start taoimractivator

* Register a server
cd %tao_root%\orbsvcs\tests\ImplRepo
%tao_root%\orbsvcs\ImplRepo_service\tao_imr add airplane_server -orbuseimr 1 -orbinitref ImplRepoService=corbaloc::localhost:8888/ImplRepoService

* Run the server
airplane_server -o airplane.ior -orbuseimr 1 -orbinitref ImplRepoService=corbaloc::localhost:8888/ImplRepoService

* Run the client
airplane_client -k file://airplane.ior
--or--
airplane_client -k corbaloc::localhost:8888/airplane_server


More information about the Implementation Repository can be found in
TAO/docs.

