summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/tests/LoadBalancing
diff options
context:
space:
mode:
authorWilliam R. Otte <wotte@dre.vanderbilt.edu>2006-07-24 15:50:11 +0000
committerWilliam R. Otte <wotte@dre.vanderbilt.edu>2006-07-24 15:50:11 +0000
commit8008dd09ccf88d4edef237a184a698cac42f2952 (patch)
treeda50d054f9c761c3f6a5923f6979e93306c56d68 /TAO/orbsvcs/tests/LoadBalancing
parent13d6e89af439164c0ade48e6f5c3e9b3f971e8c9 (diff)
downloadATCD-8008dd09ccf88d4edef237a184a698cac42f2952.tar.gz
Repo restructuring
Diffstat (limited to 'TAO/orbsvcs/tests/LoadBalancing')
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Application_Controlled.mpc32
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.cpp72
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.h59
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.cpp212
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.h86
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Makefile.am147
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/README11
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Test.idl23
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/client.cpp92
-rwxr-xr-xTAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/run_test.pl86
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/server.cpp112
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/svc.conf2
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf3
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf.xml8
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.cpp107
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.h75
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.cpp9
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.h27
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.cpp5
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.h34
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Infrastructure_Controlled.mpc34
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.cpp249
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.h71
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Makefile.am154
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/README8
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.cpp18
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.h32
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Test.idl15
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/client.cpp86
-rwxr-xr-xTAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/run_test.pl72
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/server.cpp31
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf3
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf.xml8
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Makefile.am15
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.cpp81
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.h64
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.cpp349
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.h107
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Makefile.am110
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Manage_Object_Group.mpc11
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.cpp81
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.h66
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Test.idl38
-rwxr-xr-xTAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/run_test.pl61
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/server.cpp132
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf3
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf.xml8
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/LoadMonitorCPU.mpc4
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/Makefile.am63
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/README11
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/client.cpp180
-rwxr-xr-xTAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/run_test.pl61
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/Makefile.am13
-rw-r--r--TAO/orbsvcs/tests/LoadBalancing/Makefile.am14
54 files changed, 0 insertions, 3455 deletions
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Application_Controlled.mpc b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Application_Controlled.mpc
deleted file mode 100644
index 91756218ae9..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Application_Controlled.mpc
+++ /dev/null
@@ -1,32 +0,0 @@
-// -*- MPC -*-
-// $Id$
-
-project(*idl): taoidldefaults {
- IDL_Files {
- Test.idl
- }
- custom_only = 1
-}
-
-project(*server): orbsvcsexe, portablegroup, loadbalancing, naming, svc_utils {
- after += *idl
- Source_Files {
- server.cpp
- LB_server.cpp
- Basic.cpp
- TestS.cpp
- TestC.cpp
- }
- IDL_Files {
- }
-}
-
-project(*client): orbsvcsexe, portablegroup, loadbalancing, naming, svc_utils {
- after += *idl
- Source_Files {
- client.cpp
- TestC.cpp
- }
- IDL_Files {
- }
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.cpp
deleted file mode 100644
index 0fc3f158fc1..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.cpp
+++ /dev/null
@@ -1,72 +0,0 @@
-#include "Basic.h"
-#include "LB_server.h"
-
-
-ACE_RCSID (Application_Controlled,
- Basic,
- "$Id$")
-
-
-Basic::Basic (CORBA::Object_ptr object_group,
- CosLoadBalancing::LoadManager_ptr lm,
- CORBA::ORB_ptr orb,
- const char *loc)
- : orb_ (CORBA::ORB::_duplicate (orb))
-{
- this->object_group_ = CORBA::Object::_duplicate (object_group);
- this->lm_ = CosLoadBalancing::LoadManager::_duplicate (lm);
- this->location_ = CORBA::string_dup (loc);
-}
-
-char *
-Basic::get_string (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- return CORBA::string_dup (this->location_);
-}
-
-void
-Basic::remove_member (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- ACE_TRY
- {
- PortableGroup::Location location (1);
- location.length (1);
- location[0].id = CORBA::string_dup (this->location_);
- this->lm_->remove_member (this->object_group_.in (),
- location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) - Removed Member at Location <%s>\n",
- this->location_));
-
- }
- ACE_CATCH (PortableGroup::ObjectNotFound, ex)
- {
- ACE_PRINT_EXCEPTION (ex,
- "Caught exception in remove_member");
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
- ACE_CATCH (PortableGroup::MemberNotFound, ex)
- {
- ACE_PRINT_EXCEPTION (ex,
- "Caught exception in remove_member");
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while destroying member\n");
- }
- ACE_ENDTRY;
-
-}
-
-void
-Basic::shutdown (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- this->orb_->shutdown (0 ACE_ENV_ARG_PARAMETER);
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.h
deleted file mode 100644
index 72a6aeb8977..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Basic.h
+++ /dev/null
@@ -1,59 +0,0 @@
-// -*- C++ -*-
-//
-// $Id$
-
-#ifndef BASIC_H
-#define BASIC_H
-
-#include "TestS.h"
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroupC.h"
-
-#if defined (_MSC_VER)
-# pragma warning(push)
-# pragma warning (disable:4250)
-#endif /* _MSC_VER */
-
-class LB_Basic_Test;
-
-/// Implement the Test::Basic interface
-class Basic
- : public virtual POA_Test::Basic
-{
-public:
- /// Constructor
- Basic (CORBA::Object_ptr object_group,
- CosLoadBalancing::LoadManager_ptr lm,
- CORBA::ORB_ptr orb,
- const char *loc);
-
- virtual char * get_string (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual void shutdown (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual void remove_member (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
-private:
- /// Use an ORB reference to convert strings to objects and shutdown
- /// the application.
- CORBA::ORB_var orb_;
-
- /// Load Manager Reference used to delete the servant reference from the
- /// object group.
- CosLoadBalancing::LoadManager_var lm_;
-
- /// location of the servant
- const char *location_ ;
-
- /// Object Group reference.
- CORBA::Object_var object_group_;
-};
-
-#if defined(_MSC_VER)
-# pragma warning(pop)
-#endif /* _MSC_VER */
-
-#endif /* BASIC_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.cpp
deleted file mode 100644
index f112c8a0af6..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.cpp
+++ /dev/null
@@ -1,212 +0,0 @@
-#include "LB_server.h"
-#include "Basic.h"
-
-#include "TestC.h"
-#include "ace/OS_NS_stdio.h"
-
-ACE_RCSID (Application_Controlled,
- LB_server,
- "$Id$")
-
-LB_server::LB_server (int argc, char **argv)
- : argc_ (argc)
- , argv_ (argv)
-{
-}
-
-int
-LB_server::destroy (void)
-{
- ACE_TRY_NEW_ENV
- {
- this->lm_->delete_object (this->fcid_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->root_poa_->destroy (1, 1 ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->orb_->destroy (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while destroying LB_server\n");
- return -1;
- }
- ACE_ENDTRY;
- return 1;
-
-}
-
-CORBA::ORB_ptr
-LB_server::orb (void)
-{
- return this->orb_.in ();
-}
-
-CORBA::Object_ptr
-LB_server::object_group (void)
-{
- return this->object_group_.in ();
-}
-
-CosLoadBalancing::LoadManager_ptr
-LB_server::load_manager (void)
-{
- return this->lm_.in ();
-}
-
-int
-LB_server::write_ior_to_file (const char *ior)
-{
- FILE *output_file =
- ACE_OS::fopen ("obj.ior", "w");
-
- if (output_file == 0)
- {
- ACE_ERROR ((LM_ERROR,
- "Cannot open output file for writing IOR:"));
- return -1;
- }
-
- ACE_OS::fprintf (output_file, "%s", ior);
- ACE_OS::fclose (output_file);
- return 0;
-}
-
-int
-LB_server::start_orb_and_poa (void)
-{
- ACE_DECLARE_NEW_CORBA_ENV;
- ACE_TRY
- {
- // Initialise the ORB.
- this->orb_ = CORBA::ORB_init (this->argc_,
- this->argv_,
- "" ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Object_var poa_object =
- this->orb_->resolve_initial_references("RootPOA"
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (poa_object.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to initialize the POA.\n"),
- 1);
-
- this->root_poa_ = PortableServer::POA::_narrow (poa_object.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableServer::POAManager_var poa_manager =
- this->root_poa_->the_POAManager (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- poa_manager->activate (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Object_var obj =
- this->orb_->resolve_initial_references ("LoadManager" ACE_ENV_ARG_PARAMETER);
-
- this->lm_ =
- CosLoadBalancing::LoadManager::_narrow (obj.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (this->lm_.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to get Load Manager Reference\n"),
- 1);
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised initialising ORB or POA");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
-
-int
-LB_server::create_object_group (void)
-{
- ACE_TRY_NEW_ENV
- {
- const char *repository_id = "IDL:Test/Basic:1.0";
-
- PortableGroup::Criteria criteria (1);
- criteria.length (1);
-
- PortableGroup::Property &property = criteria[0];
- property.nam.length (1);
-
- property.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.MembershipStyle");
-
- PortableGroup::MembershipStyleValue msv =
- PortableGroup::MEMB_APP_CTRL;
- property.val <<= msv;
-
- this->object_group_ = this->lm_->create_object (repository_id,
- criteria,
- this->fcid_.out ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::String_var ior =
- this->orb_->object_to_string (this->object_group_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->write_ior_to_file (ior.in ());
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while creating object group");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
-
-int
-LB_server::register_servant (Basic *servant, const char *loc)
-{
- ACE_TRY_NEW_ENV
- {
- Test::Basic_var basic =
- servant->_this (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableGroup::Location location (1);
- location.length (1);
-
- location[0].id = CORBA::string_dup (loc);
-
- this->lm_->add_member (this->object_group_.in (),
- location,
- basic.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while registering servant");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.h
deleted file mode 100644
index c82ed1c073b..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/LB_server.h
+++ /dev/null
@@ -1,86 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file LB_server.h
- *
- * $Id$
- *
- * @author Jaiganesh Balasubramanian <jai@doc.ece.uci.edu>
- * @author Ossama Othman <ossama@uci.edu>
- */
-//=============================================================================
-
-
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroupC.h"
-#include "tao/PortableServer/PortableServer.h"
-
-// Forward Declaration of the kind of servant we would like to handle
-// by the server.
-class Basic;
-
-/**
- * @class LB_server
- *
- * @brief Encapsulate the test in class.
- *
- * This is a class used to retrieve the LoadManager reference and
- * create the Object Group. Servants add themselves to the object
- * group and the object group reference is published to the clients.
- * Clients then invoke the "servant operations" on the LoadManager
- * itself. At this point the Load Balancing cycle starts.
- */
-class LB_server
-{
-public:
-
- /// Constructor
- LB_server (int argc, char **argv);
-
- /// destroys LoadManager, ORB and POA.
- int destroy (void);
-
- /// start the ORB.
- int start_orb_and_poa (void);
-
- /// Get the LoadManager Interface.
- int init (int argc, char **argv);
-
- /// Create the Object Group using the Load Manager Reference.
- int create_object_group (void);
-
- /// register the servants with the object group.
- int register_servant (Basic *servant, const char *loc);
-
- /// for servants to register to the initialised ORB.
- CORBA::ORB_ptr orb (void);
-
- /// for servants to get the reference for object_group.
- CORBA::Object_ptr object_group (void);
-
- /// for servants to get the reference for object_group.
- CosLoadBalancing::LoadManager_ptr load_manager (void);
-
-private:
-
- /// Load Manager
- CosLoadBalancing::LoadManager_var lm_;
-
- /// Object Group.
- CORBA::Object_var object_group_;
-
- /// factory id for the object group.
- PortableGroup::GenericFactory::FactoryCreationId_var fcid_;
-
- /// Used to force the creation of the object group only once.
- static int called_once_;
-
- /// write the IOR to a file so that it can be read later.
- int write_ior_to_file (const char *);
-
- CORBA::ORB_var orb_;
- int argc_;
- char **argv_;
- PortableServer::POA_var root_poa_;
-};
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Makefile.am
deleted file mode 100644
index 17331079c93..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Makefile.am
+++ /dev/null
@@ -1,147 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-ACE_BUILDDIR = $(top_builddir)/..
-ACE_ROOT = $(top_srcdir)/..
-TAO_BUILDDIR = $(top_builddir)
-TAO_IDL = ACE_ROOT=$(ACE_ROOT) TAO_ROOT=$(TAO_ROOT) $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDL_DEP = $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDLFLAGS = -Ge 1 -Wb,pre_include=ace/pre.h -Wb,post_include=ace/post.h -I$(TAO_ROOT) -I$(srcdir) -g $(ACE_BUILDDIR)/apps/gperf/src/gperf
-TAO_ROOT = $(top_srcdir)
-
-noinst_PROGRAMS =
-
-## Makefile.Application_Controlled_Idl.am
-
-BUILT_SOURCES = \
- TestC.cpp \
- TestC.h \
- TestC.inl \
- TestS.cpp \
- TestS.h \
- TestS.inl
-
-CLEANFILES = \
- Test-stamp \
- TestC.cpp \
- TestC.h \
- TestC.inl \
- TestS.cpp \
- TestS.h \
- TestS.inl
-
-TestC.cpp TestC.h TestC.inl TestS.cpp TestS.h TestS.inl: Test-stamp
-
-Test-stamp: $(srcdir)/Test.idl $(TAO_IDL_DEP)
- $(TAO_IDL) $(TAO_IDLFLAGS) -Sa -St $(srcdir)/Test.idl
- @touch $@
-
-
-noinst_HEADERS = \
- Test.idl
-
-## Makefile.Application_Controlled_Client.am
-
-if BUILD_AMI
-if BUILD_CORBA_MESSAGING
-if !BUILD_MINIMUM_CORBA
-
-noinst_PROGRAMS += client
-
-client_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I$(TAO_ROOT)/orbsvcs \
- -I$(TAO_BUILDDIR)/orbsvcs
-
-client_SOURCES = \
- TestC.cpp \
- client.cpp \
- Basic.h \
- LB_server.h
-
-client_LDADD = \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_Svc_Utils.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosLoadBalancing.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORInterceptor.la \
- $(TAO_BUILDDIR)/tao/libTAO_ObjRefTemplate.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI_Server.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_PortableGroup.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORManip.la \
- $(TAO_BUILDDIR)/tao/libTAO_Messaging.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI.la \
- $(TAO_BUILDDIR)/tao/libTAO_CodecFactory.la \
- $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \
- $(TAO_BUILDDIR)/tao/libTAO_Valuetype.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \
- $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \
- $(TAO_BUILDDIR)/tao/libTAO.la \
- $(ACE_BUILDDIR)/ace/libACE.la
-
-endif !BUILD_MINIMUM_CORBA
-endif BUILD_CORBA_MESSAGING
-endif BUILD_AMI
-
-## Makefile.Application_Controlled_Server.am
-
-if BUILD_AMI
-if BUILD_CORBA_MESSAGING
-if !BUILD_MINIMUM_CORBA
-
-noinst_PROGRAMS += server
-
-server_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I$(TAO_ROOT)/orbsvcs \
- -I$(TAO_BUILDDIR)/orbsvcs
-
-server_SOURCES = \
- Basic.cpp \
- LB_server.cpp \
- TestC.cpp \
- TestS.cpp \
- server.cpp \
- Basic.h \
- LB_server.h
-
-server_LDADD = \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_Svc_Utils.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosLoadBalancing.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORInterceptor.la \
- $(TAO_BUILDDIR)/tao/libTAO_ObjRefTemplate.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI_Server.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_PortableGroup.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORManip.la \
- $(TAO_BUILDDIR)/tao/libTAO_Messaging.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI.la \
- $(TAO_BUILDDIR)/tao/libTAO_CodecFactory.la \
- $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \
- $(TAO_BUILDDIR)/tao/libTAO_Valuetype.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \
- $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \
- $(TAO_BUILDDIR)/tao/libTAO.la \
- $(ACE_BUILDDIR)/ace/libACE.la
-
-endif !BUILD_MINIMUM_CORBA
-endif BUILD_CORBA_MESSAGING
-endif BUILD_AMI
-
-## Clean up template repositories, etc.
-clean-local:
- -rm -f *~ *.bak *.rpo *.sym lib*.*_pure_* core core.*
- -rm -f gcctemp.c gcctemp so_locations *.ics
- -rm -rf cxx_repository ptrepository ti_files
- -rm -rf templateregistry ir.out
- -rm -rf ptrepository SunWS_cache Templates.DB
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/README b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/README
deleted file mode 100644
index 107953609c2..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/README
+++ /dev/null
@@ -1,11 +0,0 @@
-This program tests the application controlled membership support
-of the Cygnus load balancer. The aim is to allow the application
-to create the replicas and then forcefully add them as the members
-of the object group maintained by the Cygnus load balancer. When
-the clients make a request on the IOR exported by the load
-balancer, the load balancer makes use of the round robin algorithm
-to make a call on any of the object group members registered with
-the load balancer.
-
-Please see $TAO_ROOT/orbsvcs/orbsvcs/Loadbalancing for the implementations
-of the Cygnus load balancer.
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Test.idl b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Test.idl
deleted file mode 100644
index 0c9a380b07c..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/Test.idl
+++ /dev/null
@@ -1,23 +0,0 @@
-//
-// $Id$
-
-/// Put the interfaces in a module, to avoid global namespace pollution
-module Test
-{
- /// A very simple interface
- interface Basic
- {
- /// Return a simple string
- string get_string ();
-
- /// A method to shutdown the ORB
- /**
- * This method is used to simplify the test shutdown process
- */
- oneway void shutdown ();
-
- /// A method to remove the servant from the LoadManager Object Group.
- oneway void remove_member ();
- };
-};
-
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/client.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/client.cpp
deleted file mode 100644
index 3a588d90066..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/client.cpp
+++ /dev/null
@@ -1,92 +0,0 @@
-#include "TestC.h"
-#include "ace/Get_Opt.h"
-
-ACE_RCSID (Application_Controlled,
- client,
- "$Id$")
-
-const char *ior = "file://obj.ior";
-
-int
-parse_args (int argc, char *argv[])
-{
- ACE_Get_Opt get_opts (argc, argv, "k:");
- int c;
-
- while ((c = get_opts ()) != -1)
- switch (c)
- {
- case 'k':
- ior = get_opts.opt_arg ();
- break;
-
- case '?':
- default:
- ACE_ERROR_RETURN ((LM_ERROR,
- "usage: %s "
- "-k <ior> "
- "\n",
- argv [0]),
- -1);
- }
- // Indicates sucessful parsing of the command line
- return 0;
-}
-
-int
-main (int argc, char *argv[])
-{
- ACE_TRY_NEW_ENV
- {
- CORBA::ORB_var orb =
- CORBA::ORB_init (argc, argv, "" ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (parse_args (argc, argv) != 0)
- return 1;
-
- CORBA::Object_var tmp =
- orb->string_to_object (ior ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- Test::Basic_var basic =
- Test::Basic::_narrow (tmp.in () ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (basic.in ()))
- {
- ACE_ERROR_RETURN ((LM_DEBUG,
- "Nil Test::Basic reference <%s>\n",
- ior),
- 1);
- }
-
- for (int i = 0; i < 5; i++)
- {
- CORBA::String_var the_string =
- basic->get_string (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) - Client request handled by object at <%s>\n",
- the_string.in ()));
- }
-
- basic->remove_member (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- basic->shutdown (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- orb->destroy (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught in client.cpp:");
- return 1;
- }
- ACE_ENDTRY;
-
- return 0;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/run_test.pl b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/run_test.pl
deleted file mode 100755
index 80b2f8e1838..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/run_test.pl
+++ /dev/null
@@ -1,86 +0,0 @@
-eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
- & eval 'exec perl -S $0 $argv:q'
- if 0;
-
-# $Id$
-# -*- perl -*-
-
-use lib "../../../../../../bin";
-use PerlACE::Run_Test;
-
-$iorfile = PerlACE::LocalFile ("obj.ior");
-unlink $iorfile;
-
-$lm_ior = "lm.ior";
-unlink $lm_ior;
-
-$status = 0;
-
-## The LoadManager needs to register signals with the ORB's reactor (on
-## Windows only) and thus can not use the TP Reactor since it doesn't
-## support that kind of thing. So, we swith to the Select MT Reactor.
-$lm_conf = PerlACE::LocalFile ("windows$PerlACE::svcconf_ext");
-
-$init_ref = "-ORBInitRef LoadManager=file://lm.ior";
-
-$LM = new PerlACE::Process ("../../../../LoadBalancer/LoadManager",
- "-o lm.ior" . ($^O eq 'MSWin32' ?
- " -ORBSvcConf $lm_conf" : ''));
-$SV = new PerlACE::Process ("server", $init_ref);
-$CL = new PerlACE::Process ("client", " -k file://$iorfile");
-
-print STDERR "\n\n======== Running Application Controlled Membership Test================\n";
-print STDERR "\n";
-
-print STDERR "This test uses the Random Load Balancing strategy in the Cygnus Load Balancer\n";
-
-print STDERR "6 servers are created and added into a Object Group\n";
-
-print STDERR "When the client makes an invocation, Random load balancing strategy\n";
-print STDERR "selects one of the servers and then the client makes 5 invocations on\n";
-print STDERR "the server. When done, the application has to delete the object from the\n";
-print STDERR "object group. This is called the application controlled membership of\n";
-print STDERR "object group.\n";
-print STDERR "\n";
-
-$LM->Spawn ();
-
-if (PerlACE::waitforfile_timed ("lm.ior", 5) == -1) {
- print STDERR "ERROR: cannot find file LoadManager IOR: lm.ior\n";
- $SV->Kill (); $SV->TimedWait (1);
- exit 1;
-}
-
-$SV->Spawn ();
-
-if (PerlACE::waitforfile_timed ($iorfile, 10) == -1) {
- print STDERR "ERROR: cannot find server file <$iorfile>\n";
- $SV->Kill (); $SV->TimedWait (1);
- exit 1;
-}
-
-$client = $CL->SpawnWaitKill (100);
-
-if ($client != 0) {
- print STDERR "ERROR: client returned $client\n";
- $status = 1;
-}
-
-$server = $SV->WaitKill (10);
-
-if ($server != 0) {
- print STDERR "ERROR: server returned $server\n";
- $status = 1;
-}
-
-$load_manager = $LM->TerminateWaitKill (10);
-
-if ($load_manager != 0) {
- print STDERR "ERROR: LoadManager returned $load_manager\n";
- $status = 1;
-}
-
-unlink $iorfile;
-unlink $lm_ior;
-
-exit $status;
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/server.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/server.cpp
deleted file mode 100644
index 68236f62685..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/server.cpp
+++ /dev/null
@@ -1,112 +0,0 @@
-#include "LB_server.h"
-#include "Basic.h"
-
-ACE_RCSID (Application_Controlled,
- server,
- "$Id$")
-
-int
-main (int argc, char *argv[])
-{
- ACE_TRY_NEW_ENV
- {
- const char *location1 = "MyLocation 1";
- const char *location2 = "MyLocation 2";
- const char *location3 = "MyLocation 3";
- const char *location4 = "MyLocation 4";
- const char *location5 = "MyLocation 5";
- const char *location6 = "MyLocation 6";
-
- LB_server lb_server (argc, argv);
-
- if (lb_server.start_orb_and_poa () == -1)
- return 1;
-
- if (lb_server.create_object_group () == -1)
- return 1;
-
- Basic *basic_servant1;
- Basic *basic_servant2;
- Basic *basic_servant3;
- Basic *basic_servant4;
- Basic *basic_servant5;
- Basic *basic_servant6;
-
- ACE_NEW_RETURN (basic_servant1,
- Basic (lb_server.object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- location1),
- 1);
- PortableServer::ServantBase_var owner_transfer1(basic_servant1);
-
- ACE_NEW_RETURN (basic_servant2,
- Basic (lb_server.object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- location2),
- 1);
- PortableServer::ServantBase_var owner_transfer2(basic_servant2);
-
- ACE_NEW_RETURN (basic_servant3,
- Basic (lb_server.object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- location3),
- 1);
- PortableServer::ServantBase_var owner_transfer3(basic_servant3);
-
- ACE_NEW_RETURN (basic_servant4,
- Basic (lb_server.object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- location4),
- 1);
- PortableServer::ServantBase_var owner_transfer4(basic_servant4);
-
- ACE_NEW_RETURN (basic_servant5,
- Basic (lb_server.object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- location5),
- 1);
- PortableServer::ServantBase_var owner_transfer5(basic_servant5);
-
- ACE_NEW_RETURN (basic_servant6,
- Basic (lb_server.object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- location6),
- 1);
- PortableServer::ServantBase_var owner_transfer6(basic_servant6);
-
- if (lb_server.register_servant (basic_servant1, location1) == -1
- || lb_server.register_servant (basic_servant2, location2) == -1
- || lb_server.register_servant (basic_servant3, location3) == -1
- || lb_server.register_servant (basic_servant4, location4) == -1
- || lb_server.register_servant (basic_servant5, location5) == -1
- || lb_server.register_servant (basic_servant6, location6) == -1)
- {
- (void) lb_server.destroy ();
- return 1;
- }
-
- lb_server.orb ()->run (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) server - event loop finished\n"));
-
- if (lb_server.destroy () == -1)
- return 1;
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "lb_server exception");
- return 1;
- }
- ACE_ENDTRY;
-
- return 0;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/svc.conf b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/svc.conf
deleted file mode 100644
index ea66c67064d..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/svc.conf
+++ /dev/null
@@ -1,2 +0,0 @@
-# $Id$
-static Resource_Factory "-ORBDropRepliesDuringShutdown 0"
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf
deleted file mode 100644
index 06c425e3ecf..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf
+++ /dev/null
@@ -1,3 +0,0 @@
-# $Id $
-
-dynamic Advanced_Resource_Factory Service_Object* TAO_Strategies:_make_TAO_Advanced_Resource_Factory () "-ORBReactorType select_mt"
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf.xml b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf.xml
deleted file mode 100644
index 289810f7d22..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Application_Controlled/windows.conf.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version='1.0'?>
-<!-- Converted from windows.conf by svcconf-convert.pl -->
-<ACE_Svc_Conf>
- <!-- $Id $ -->
- <dynamic id="Advanced_Resource_Factory" type="Service_Object">
- <initializer path="TAO_Strategies" init="_make_TAO_Advanced_Resource_Factory" params="-ORBReactorType select_mt"/>
- </dynamic>
-</ACE_Svc_Conf>
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.cpp
deleted file mode 100644
index 1c0798efa7e..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.cpp
+++ /dev/null
@@ -1,107 +0,0 @@
-#include "Factory.h"
-#include "Simple.h"
-
-#include "TestC.h"
-
-ACE_RCSID (Infrastructure_Controlled,
- Factory,
- "$Id$")
-
-Factory::Factory (void)
-{
- this->fcid_ = 0;
-}
-
-CORBA::Object_ptr
-Factory::create_object (
- const char * /*type_id*/,
- const PortableGroup::Criteria & /*the_criteria*/,
- PortableGroup::GenericFactory::FactoryCreationId_out fcid
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException,
- PortableGroup::NoFactory,
- PortableGroup::ObjectNotCreated,
- PortableGroup::InvalidCriteria,
- PortableGroup::InvalidProperty,
- PortableGroup::CannotMeetCriteria))
-{
- Simple *servant;
-
- ACE_NEW_THROW_EX (servant,
- Simple,
- CORBA::NO_MEMORY ());
-
- ACE_CHECK_RETURN (CORBA::Object::_nil ());
-
- PortableServer::ServantBase_var safe_servant = servant;
-
- CORBA::ULong tmp_fcid = 0;
- tmp_fcid = this->fcid_;
-
- while (this->factory_map_.find (this->fcid_) == 0)
- {
- this->fcid_++;
- if (this->fcid_ == tmp_fcid)
- ACE_THROW_RETURN (PortableGroup::ObjectNotCreated (),
- CORBA::Object::_nil ());
- }
-
- tmp_fcid = this->fcid_;
-
- PortableGroup::GenericFactory::FactoryCreationId *my_fcid = 0;
-
- ACE_NEW_THROW_EX (my_fcid,
- PortableGroup::GenericFactory::FactoryCreationId,
- CORBA::NO_MEMORY ());
- ACE_CHECK_RETURN (CORBA::Object::_nil ());
-
- fcid = my_fcid;
-
- *my_fcid <<= tmp_fcid;
-
- this->poa_ =
- servant->_default_POA (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_CHECK_RETURN (CORBA::Object::_nil ());
-
- this->oid_ = this->poa_->servant_to_id (servant
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (CORBA::Object::_nil ());
-
- return servant->_this (ACE_ENV_SINGLE_ARG_PARAMETER);
-
-}
-
-void
-Factory::delete_object (
- const PortableGroup::GenericFactory::FactoryCreationId &
- fcid
- ACE_ENV_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException,
- PortableGroup::ObjectNotFound))
-{
- CORBA::ULong my_fcid = 0;
-
- if (fcid >>= my_fcid)
- {
- ACE_GUARD (TAO_SYNCH_MUTEX, guard, this->lock_);
- Factory_Map::ENTRY *entry = 0;
- if (this->factory_map_.find (my_fcid, entry) == 0)
- {
- if (this->factory_map_.unbind (my_fcid) != 0)
- ACE_THROW (CORBA::INTERNAL ());
- }
- }
- else
- ACE_THROW (PortableGroup::ObjectNotFound ());
-
- if (my_fcid == this->fcid_)
- {
- this->poa_->deactivate_object (this->oid_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_CHECK;
- }
- else
- {
- ACE_THROW (PortableGroup::ObjectNotFound ());
- }
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.h
deleted file mode 100644
index 68473814908..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory.h
+++ /dev/null
@@ -1,75 +0,0 @@
-// -*- C++ -*-
-//
-// $Id$
-
-#ifndef FACTORY_H
-#define FACTORY_H
-
-#include "Factory_Map.h"
-#include "orbsvcs/PortableGroupS.h"
-#include "ace/Null_Mutex.h"
-
-#if defined (_MSC_VER)
-# pragma warning(push)
-#endif /* _MSC_VER */
-
-/// Implement the PortableGroup::GenericFactory Interface.
-class Factory
- : public virtual POA_PortableGroup::GenericFactory
-{
-public:
-
- /// Constructor
- Factory (void);
- /// creates a Test::Simple servant reference.
- /// This reference is then passed as a FactoryInfos property
- /// when the LoadManager creates the object group.
- /// In this way, LoadManager can decide when to create the object group
- /// members.
-
- virtual CORBA::Object_ptr create_object (
- const char * type_id,
- const PortableGroup::Criteria & the_criteria,
- PortableGroup::GenericFactory::FactoryCreationId_out
- factory_creation_id
- ACE_ENV_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException,
- PortableGroup::NoFactory,
- PortableGroup::ObjectNotCreated,
- PortableGroup::InvalidCriteria,
- PortableGroup::InvalidProperty,
- PortableGroup::CannotMeetCriteria));
-
- /// The LoadManager is passed the FactoryCreationId, it received
- /// from the create_object () call.
- /// The LoadManager destroys the factory object created.
-
- virtual void delete_object (
- const PortableGroup::GenericFactory::FactoryCreationId &
- factory_creation_id
- ACE_ENV_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException,
- PortableGroup::ObjectNotFound));
-private:
- /// The factory creation id.
- CORBA::ULong fcid_;
-
- /// Table that maps FactoryCreationId to Factory_Node
- Factory_Map factory_map_;
-
- /// The object id of the servant we are creating.
- PortableServer::ObjectId_var oid_;
-
- /// The POA with which we register the servant.
- PortableServer::POA_var poa_;
-
- /// Lock used to synchronize access to the factory creation id
- TAO_SYNCH_MUTEX lock_;
-
-};
-
-#if defined(_MSC_VER)
-# pragma warning(pop)
-#endif /* _MSC_VER */
-
-#endif /* FACTORY_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.cpp
deleted file mode 100644
index 375784f2fd3..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.cpp
+++ /dev/null
@@ -1,9 +0,0 @@
-// -*- C++ -*-
-
-#include "Factory_Map.h"
-
-
-ACE_RCSID (Infrastructure_Controlled,
- Factory_Map,
- "$Id$")
-
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.h
deleted file mode 100644
index 87df1062797..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Map.h
+++ /dev/null
@@ -1,27 +0,0 @@
-// -*- C++ -*-
-//
-// $Id$
-
-#ifndef FACTORY_MAP_H
-#define FACTORY_MAP_H
-
-#include /**/ "ace/pre.h"
-#include "ace/config-all.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "Factory_Struct.h"
-#include "ace/Hash_Map_Manager_T.h"
-
-typedef ACE_Hash_Map_Manager_Ex<
- ACE_UINT32,
- Factory_Struct,
- ACE_Hash<ACE_UINT32>,
- ACE_Equal_To<ACE_UINT32>,
- ACE_Null_Mutex> Factory_Map;
-
-
-#include /**/ "ace/post.h"
-#endif /* FACTORY_MAP_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.cpp
deleted file mode 100644
index 4459fe3e227..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.cpp
+++ /dev/null
@@ -1,5 +0,0 @@
-#include "Factory_Struct.h"
-
-ACE_RCSID (Infrastructure_Controlled,
- Factory_Struct,
- "$Id$")
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.h
deleted file mode 100644
index 1e949a91aa5..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Factory_Struct.h
+++ /dev/null
@@ -1,34 +0,0 @@
-//$Id$
-// -*- C++ -*-
-
-
-#ifndef FACTORY_STRUCT_H
-#define FACTORY_STRUCT_H
-
-#include /**/ "ace/pre.h"
-
-#include "ace/config-all.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "orbsvcs/PortableGroupC.h"
-
-#include "ace/Array_Base.h"
-
-
-struct Factory_Node
-{
-
- /// FactoryCreationId assigned to the member.
- PortableGroup::GenericFactory::FactoryCreationId_var factory_creation_id;
-
-};
-
-typedef ACE_Array_Base<Factory_Node> Factory_Struct;
-
-
-#include /**/ "ace/post.h"
-
-#endif /* FACTORY_STRUCT_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Infrastructure_Controlled.mpc b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Infrastructure_Controlled.mpc
deleted file mode 100644
index af901a174ec..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Infrastructure_Controlled.mpc
+++ /dev/null
@@ -1,34 +0,0 @@
-// $Id$
-project(*idl): taoidldefaults {
- IDL_Files {
- Test.idl
- }
- custom_only = 1
-}
-
-project(*Server): loadbalancing {
- after += *idl
- Source_Files {
- server.cpp
- LB_server.cpp
- Simple.cpp
- Factory.cpp
- Factory_Map.cpp
- Factory_Struct.cpp
- TestS.cpp
- TestC.cpp
- }
- IDL_Files {
- }
-}
-
-project(*Client): loadbalancing {
- after += *idl
- Source_Files {
- TestC.cpp
- client.cpp
- }
- IDL_Files {
- }
-}
-
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.cpp
deleted file mode 100644
index fef78510c70..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.cpp
+++ /dev/null
@@ -1,249 +0,0 @@
-#include "LB_server.h"
-#include "Simple.h"
-#include "Factory.h"
-
-#include "TestC.h"
-#include "ace/OS_NS_stdio.h"
-
-ACE_RCSID (Infrastructure_Controlled,
- LB_server,
- "$Id$")
-
-LB_server::LB_server (int argc, char **argv)
- : argc_ (argc)
- , argv_ (argv)
-{
-}
-
-CORBA::ORB_ptr
-LB_server::orb (void)
-{
- return this->orb_.in ();
-}
-
-int
-LB_server::run (void)
-{
- ACE_TRY_NEW_ENV
- {
- ACE_Time_Value period (0, 10);
- while (1)
- {
- this->orb_->perform_work (&period);
- ACE_TRY_CHECK;
- }
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while running LB_server\n");
- return -1;
- }
- ACE_ENDTRY;
- return 1;
-
-}
-
-
-int
-LB_server::destroy (void)
-{
- ACE_TRY_NEW_ENV
- {
- this->lm_->delete_object (this->fcid_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->root_poa_->destroy (1, 1 ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->orb_->destroy (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while destroying LB_server\n");
- return -1;
- }
- ACE_ENDTRY;
- return 1;
-
-}
-
-int
-LB_server::write_ior_to_file (const char *ior)
-{
- FILE *output_file =
- ACE_OS::fopen ("obj.ior", "w");
-
- if (output_file == 0)
- {
- ACE_ERROR ((LM_ERROR,
- "Cannot open output file for writing IOR:"));
- return -1;
- }
-
- ACE_OS::fprintf (output_file, "%s", ior);
- ACE_OS::fclose (output_file);
- return 0;
-}
-
-int
-LB_server::start_orb_and_poa (void)
-{
- ACE_DECLARE_NEW_CORBA_ENV;
- ACE_TRY
- {
- // Initialise the ORB.
- this->orb_ = CORBA::ORB_init (this->argc_,
- this->argv_,
- "" ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Object_var poa_object =
- this->orb_->resolve_initial_references("RootPOA"
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (poa_object.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to initialize the POA.\n"),
- 1);
-
- this->root_poa_ = PortableServer::POA::_narrow (poa_object.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableServer::POAManager_var poa_manager =
- this->root_poa_->the_POAManager (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- poa_manager->activate (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Object_var obj =
- this->orb_->resolve_initial_references ("LoadManager" ACE_ENV_ARG_PARAMETER);
-
- this->lm_ =
- CosLoadBalancing::LoadManager::_narrow (obj.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (this->lm_.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to get Load Manager Reference\n"),
- 1);
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised initialising ORB or POA");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
-
-int
-LB_server::create_object_group (const char *loc_1, const char *loc_2)
-{
- ACE_TRY_NEW_ENV
- {
- const char *repository_id = "IDL:Test/Simple:1.0";
-
- Factory factory_object1;
- Factory factory_object2;
-
- PortableGroup::GenericFactory_var factory_obj1 =
- factory_object1._this (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableGroup::GenericFactory_var factory_obj2 =
- factory_object2._this (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableGroup::FactoriesValue factory_infos;
- factory_infos.length (2);
-
- PortableGroup::Criteria criteria ;
- criteria.length (4);
-
- PortableGroup::Criteria factory_criteria ;
- factory_criteria.length (1);
-
- PortableGroup::Property &property_one = criteria[0];
- property_one.nam.length (1);
- PortableGroup::Property &property_two = criteria[1];
- property_two.nam.length (1);
- PortableGroup::Property &property_three = criteria[2];
- property_three.nam.length (1);
- PortableGroup::Property &property_four = criteria[3];
- property_four.nam.length (1);
-
- PortableGroup::Property &factory_property_one = factory_criteria[0];
- factory_property_one.nam.length (1);
-
- property_one.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.MembershipStyle");
-
- PortableGroup::MembershipStyleValue msv =
- PortableGroup::MEMB_INF_CTRL;
- property_one.val <<= msv;
-
- factory_infos[0].the_factory = factory_obj1._retn ();
- factory_infos[0].the_criteria = factory_criteria;
-
- factory_infos[1].the_factory = factory_obj2._retn ();
- factory_infos[1].the_criteria = factory_criteria;
-
- PortableGroup::Location & location1 = factory_infos[0].the_location;
- location1.length (1);
- PortableGroup::Location & location2 = factory_infos[1].the_location;
- location2.length (1);
-
- location1[0].id = CORBA::string_dup (loc_1);
- location2[0].id = CORBA::string_dup (loc_2);
-
- property_two.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.Factories");
- property_two.val <<= factory_infos;
-
- property_three.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.InitialNumberMembers");
- PortableGroup::InitialNumberMembersValue init_value = 2;
- property_three.val <<= init_value;
-
- property_four.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.MinimumNumberMembers");
- PortableGroup::MinimumNumberMembersValue min_value = 2;
- property_four.val <<= min_value;
-
- this->object_group_ = this->lm_->create_object (repository_id,
- criteria,
- this->fcid_.out ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::String_var ior =
- this->orb_->object_to_string (this->object_group_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->write_ior_to_file (ior.in ());
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while creating object group");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.h
deleted file mode 100644
index 9b0513431dc..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/LB_server.h
+++ /dev/null
@@ -1,71 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file LB_server.h
- *
- * $Id$
- *
- * @author Jaiganesh Balasubramanian <jai@doc.ece.uci.edu>
- * @author Ossama Othman <ossama@uci.edu>
- */
-//=============================================================================
-
-
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroupC.h"
-#include "tao/PortableServer/PortableServer.h"
-
-/**
- * @class LB_server
- *
- * @brief Encapsulate the test in class.
- *
- * This is a class used to retrieve the LoadManager reference and
- * create the Object Group. Servants add themselves to the object
- * group and the object group reference is published to the clients.
- * Clients then invoke the "servant operations" on the LoadManager
- * itself. At this point the Load Balancing cycle starts.
- */
-class LB_server
-{
-public:
-
- /// Constructor
- LB_server (int argc, char **argv);
-
- /// destroys LoadManager, ORB and POA.
- int destroy (void);
-
- /// start the ORB.
- int start_orb_and_poa (void);
-
- /// Create the Object Group using the Load Manager Reference.
- int create_object_group (const char *loc_1, const char *loc_2);
-
- /// Run the ORB.
- int run (void);
-
- /// for servants to register to the initialised ORB.
- CORBA::ORB_ptr orb (void);
-
-private:
-
- int write_ior_to_file (const char *);
-
-private:
-
- /// Load Manager
- CosLoadBalancing::LoadManager_var lm_;
-
- /// Object Group.
- CORBA::Object_var object_group_;
-
- /// factory id for the object group.
- PortableGroup::GenericFactory::FactoryCreationId_var fcid_;
-
- CORBA::ORB_var orb_;
- int argc_;
- char **argv_;
- PortableServer::POA_var root_poa_;
-};
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Makefile.am
deleted file mode 100644
index c5dee68b8be..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Makefile.am
+++ /dev/null
@@ -1,154 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-ACE_BUILDDIR = $(top_builddir)/..
-ACE_ROOT = $(top_srcdir)/..
-TAO_BUILDDIR = $(top_builddir)
-TAO_IDL = ACE_ROOT=$(ACE_ROOT) TAO_ROOT=$(TAO_ROOT) $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDL_DEP = $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDLFLAGS = -Ge 1 -Wb,pre_include=ace/pre.h -Wb,post_include=ace/post.h -I$(TAO_ROOT) -I$(srcdir) -g $(ACE_BUILDDIR)/apps/gperf/src/gperf
-TAO_ROOT = $(top_srcdir)
-
-noinst_PROGRAMS =
-
-## Makefile.Infrastructure_Controlled_Idl.am
-
-BUILT_SOURCES = \
- TestC.cpp \
- TestC.h \
- TestC.inl \
- TestS.cpp \
- TestS.h \
- TestS.inl
-
-CLEANFILES = \
- Test-stamp \
- TestC.cpp \
- TestC.h \
- TestC.inl \
- TestS.cpp \
- TestS.h \
- TestS.inl
-
-TestC.cpp TestC.h TestC.inl TestS.cpp TestS.h TestS.inl: Test-stamp
-
-Test-stamp: $(srcdir)/Test.idl $(TAO_IDL_DEP)
- $(TAO_IDL) $(TAO_IDLFLAGS) -Sa -St $(srcdir)/Test.idl
- @touch $@
-
-
-noinst_HEADERS = \
- Test.idl
-
-## Makefile.Infrastructure_Controlled_Client.am
-
-if BUILD_AMI
-if BUILD_CORBA_MESSAGING
-if !BUILD_MINIMUM_CORBA
-
-noinst_PROGRAMS += client
-
-client_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I$(TAO_ROOT)/orbsvcs \
- -I$(TAO_BUILDDIR)/orbsvcs
-
-client_SOURCES = \
- TestC.cpp \
- client.cpp \
- Factory.h \
- Factory_Map.h \
- Factory_Struct.h \
- LB_server.h \
- Simple.h
-
-client_LDADD = \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosLoadBalancing.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORInterceptor.la \
- $(TAO_BUILDDIR)/tao/libTAO_ObjRefTemplate.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI_Server.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_PortableGroup.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORManip.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \
- $(TAO_BUILDDIR)/tao/libTAO_Messaging.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI.la \
- $(TAO_BUILDDIR)/tao/libTAO_CodecFactory.la \
- $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \
- $(TAO_BUILDDIR)/tao/libTAO_Valuetype.la \
- $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \
- $(TAO_BUILDDIR)/tao/libTAO.la \
- $(ACE_BUILDDIR)/ace/libACE.la
-
-endif !BUILD_MINIMUM_CORBA
-endif BUILD_CORBA_MESSAGING
-endif BUILD_AMI
-
-## Makefile.Infrastructure_Controlled_Server.am
-
-if BUILD_AMI
-if BUILD_CORBA_MESSAGING
-if !BUILD_MINIMUM_CORBA
-
-noinst_PROGRAMS += server
-
-server_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I$(TAO_ROOT)/orbsvcs \
- -I$(TAO_BUILDDIR)/orbsvcs
-
-server_SOURCES = \
- Factory.cpp \
- Factory_Map.cpp \
- Factory_Struct.cpp \
- LB_server.cpp \
- Simple.cpp \
- TestC.cpp \
- TestS.cpp \
- server.cpp \
- Factory.h \
- Factory_Map.h \
- Factory_Struct.h \
- LB_server.h \
- Simple.h
-
-server_LDADD = \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosLoadBalancing.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORInterceptor.la \
- $(TAO_BUILDDIR)/tao/libTAO_ObjRefTemplate.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI_Server.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_PortableGroup.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORManip.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \
- $(TAO_BUILDDIR)/tao/libTAO_Messaging.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI.la \
- $(TAO_BUILDDIR)/tao/libTAO_CodecFactory.la \
- $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \
- $(TAO_BUILDDIR)/tao/libTAO_Valuetype.la \
- $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \
- $(TAO_BUILDDIR)/tao/libTAO.la \
- $(ACE_BUILDDIR)/ace/libACE.la
-
-endif !BUILD_MINIMUM_CORBA
-endif BUILD_CORBA_MESSAGING
-endif BUILD_AMI
-
-## Clean up template repositories, etc.
-clean-local:
- -rm -f *~ *.bak *.rpo *.sym lib*.*_pure_* core core.*
- -rm -f gcctemp.c gcctemp so_locations *.ics
- -rm -rf cxx_repository ptrepository ti_files
- -rm -rf templateregistry ir.out
- -rm -rf ptrepository SunWS_cache Templates.DB
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/README b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/README
deleted file mode 100644
index 679b3d67b4b..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/README
+++ /dev/null
@@ -1,8 +0,0 @@
-This program tests the infrastructure controlled membership support
-of the Cygnus Load Balancer. The aim is to allow Cygnus to set the
-factories needed to create the "replicas", when the object group
-is created. This way, the load balancer can decide when to create
-the object group members.
-
-Please see $TAO_ROOT/orbsvcs/orbsvcs/Loadbalancing for the implementations
-of the Cygnus load balancer.
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.cpp
deleted file mode 100644
index a4de93fd1b0..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.cpp
+++ /dev/null
@@ -1,18 +0,0 @@
-#include "Simple.h"
-
-
-ACE_RCSID (Infrastructure_Controlled,
- Simple,
- "$Id$")
-
-
-Simple::Simple (void)
-{
-}
-
-char *
-Simple::get_string (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- return CORBA::string_dup ("TAO Load Balancing Works!");
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.h
deleted file mode 100644
index 7eb93b15f5c..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Simple.h
+++ /dev/null
@@ -1,32 +0,0 @@
-// -*- C++ -*-
-//
-// $Id$
-
-#ifndef SIMPLE_H
-#define SIMPLE_H
-
-#include "TestS.h"
-
-#if defined (_MSC_VER)
-# pragma warning(push)
-#endif /* _MSC_VER */
-
-/// Implement the Test::Simple interface
-class Simple
- : public virtual POA_Test::Simple
-{
-public:
-
- Simple (void);
- /// Constructor
-
- virtual char * get_string (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
-};
-
-#if defined(_MSC_VER)
-# pragma warning(pop)
-#endif /* _MSC_VER */
-
-#endif /* SIMPLE_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Test.idl b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Test.idl
deleted file mode 100644
index 4c0f00b66a1..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/Test.idl
+++ /dev/null
@@ -1,15 +0,0 @@
-//
-// $Id$
-
-/// Put the interfaces in a module, to avoid global namespace pollution
-module Test
-{
- /// A very simple interface
- interface Simple
- {
- /// Return a simple string
- string get_string ();
-
- };
-};
-
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/client.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/client.cpp
deleted file mode 100644
index 8a85b412846..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/client.cpp
+++ /dev/null
@@ -1,86 +0,0 @@
-#include "TestC.h"
-#include "ace/Get_Opt.h"
-
-
-ACE_RCSID (Infrastructure_Controlled,
- client,
- "$Id$")
-
-
-const char *ior = "file://obj.ior";
-
-int
-parse_args (int argc, char *argv[])
-{
- ACE_Get_Opt get_opts (argc, argv, "k:");
- int c;
-
- while ((c = get_opts ()) != -1)
- switch (c)
- {
- case 'k':
- ior = get_opts.opt_arg ();
- break;
-
- case '?':
- default:
- ACE_ERROR_RETURN ((LM_ERROR,
- "usage: %s "
- "-k <ior> "
- "\n",
- argv [0]),
- -1);
- }
- // Indicates sucessful parsing of the command line
- return 0;
-}
-
-int
-main (int argc, char *argv[])
-{
- ACE_TRY_NEW_ENV
- {
- CORBA::ORB_var orb =
- CORBA::ORB_init (argc, argv, "" ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (parse_args (argc, argv) != 0)
- return 1;
-
- CORBA::Object_var tmp =
- orb->string_to_object (ior ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- Test::Simple_var simple =
- Test::Simple::_narrow (tmp.in () ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (simple.in ()))
- {
- ACE_ERROR_RETURN ((LM_DEBUG,
- "Nil Test::Simple reference <%s>\n",
- ior),
- 1);
- }
-
- CORBA::String_var the_string =
- simple->get_string (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) - string returned <%s>\n",
- the_string.in ()));
-
- orb->destroy (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught in client.cpp:");
- return 1;
- }
- ACE_ENDTRY;
-
- return 0;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/run_test.pl b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/run_test.pl
deleted file mode 100755
index b5fa6ef52da..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/run_test.pl
+++ /dev/null
@@ -1,72 +0,0 @@
-eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
- & eval 'exec perl -S $0 $argv:q'
- if 0;
-
-# $Id$
-# -*- perl -*-
-
-use lib "../../../../../../bin";
-use PerlACE::Run_Test;
-
-$iorfile = PerlACE::LocalFile ("obj.ior");
-unlink $iorfile;
-
-$lm_ior = "lm.ior";
-unlink $lm_ior;
-
-$status = 0;
-
-## The LoadManager needs to register signals with the ORB's reactor (on
-## Windows only) and thus can not use the TP Reactor since it doesn't
-## support that kind of thing. So, we swith to the Select MT Reactor.
-$lm_conf = PerlACE::LocalFile ("windows$PerlACE::svcconf_ext");
-
-$init_ref = "-ORBInitRef LoadManager=file://lm.ior";
-
-$LM = new PerlACE::Process ("../../../../LoadBalancer/LoadManager",
- "-o lm.ior" . ($^O eq 'MSWin32' ?
- " -ORBSvcConf $lm_conf" : ''));
-$SV = new PerlACE::Process ("server", $init_ref);
-$CL = new PerlACE::Process ("client", " -k file://$iorfile");
-
-$LM->Spawn ();
-
-if (PerlACE::waitforfile_timed ("lm.ior", 5) == -1) {
- print STDERR "ERROR: cannot find file LoadManager IOR: lm.ior\n";
- $SV->Kill (); $SV->TimedWait (1);
- exit 1;
-}
-
-$SV->Spawn ();
-
-if (PerlACE::waitforfile_timed ($iorfile, 10) == -1) {
- print STDERR "ERROR: cannot find server file <$iorfile>\n";
- $SV->Kill (); $SV->TimedWait (1);
- exit 1;
-}
-
-$client = $CL->SpawnWaitKill (100);
-
-if ($client != 0) {
- print STDERR "ERROR: client returned $client\n";
- $status = 1;
-}
-
-$server = $SV->TerminateWaitKill (10);
-
-if ($server != 0) {
- print STDERR "ERROR: server returned $server\n";
- $status = 1;
-}
-
-$load_manager = $LM->TerminateWaitKill (10);
-
-if ($load_manager != 0) {
- print STDERR "ERROR: LoadManager returned $load_manager\n";
- $status = 1;
-}
-
-unlink $iorfile;
-unlink $lm_ior;
-
-exit $status;
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/server.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/server.cpp
deleted file mode 100644
index 735da982dc4..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/server.cpp
+++ /dev/null
@@ -1,31 +0,0 @@
-#include "LB_server.h"
-#include "Factory.h"
-#include "Simple.h"
-
-ACE_RCSID (Infrastructure_Controlled,
- server,
- "$Id$")
-
-int
-main (int argc, char *argv[])
-{
- const char *location1 = "MyLocation 1";
- const char *location2 = "MyLocation 2";
-
- LB_server lb_server (argc, argv);
-
- if (lb_server.start_orb_and_poa () == -1)
- return 1;
-
- if (lb_server.create_object_group (location1, location2) == -1)
- return 1;
-
- lb_server.run ();
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) server - event loop finished\n"));
-
- if (lb_server.destroy () == -1)
- return 1;
-
- return 0;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf
deleted file mode 100644
index 06c425e3ecf..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf
+++ /dev/null
@@ -1,3 +0,0 @@
-# $Id $
-
-dynamic Advanced_Resource_Factory Service_Object* TAO_Strategies:_make_TAO_Advanced_Resource_Factory () "-ORBReactorType select_mt"
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf.xml b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf.xml
deleted file mode 100644
index 289810f7d22..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Infrastructure_Controlled/windows.conf.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version='1.0'?>
-<!-- Converted from windows.conf by svcconf-convert.pl -->
-<ACE_Svc_Conf>
- <!-- $Id $ -->
- <dynamic id="Advanced_Resource_Factory" type="Service_Object">
- <initializer path="TAO_Strategies" init="_make_TAO_Advanced_Resource_Factory" params="-ORBReactorType select_mt"/>
- </dynamic>
-</ACE_Svc_Conf>
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Makefile.am
deleted file mode 100644
index 94ee8bc71d4..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Makefile.am
+++ /dev/null
@@ -1,15 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-SUBDIRS = \
- Application_Controlled \
- Infrastructure_Controlled \
- Manage_Object_Group
-
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.cpp
deleted file mode 100644
index b858c9947a5..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.cpp
+++ /dev/null
@@ -1,81 +0,0 @@
-#include "Basic.h"
-#include "LB_server.h"
-
-
-ACE_RCSID (Application_Controlled,
- Basic,
- "$Id$")
-
-
-Basic::Basic (CORBA::Object_ptr object_group,
- CosLoadBalancing::LoadManager_ptr lm,
- CORBA::ORB_ptr orb,
- CORBA::Short num,
- const char *loc)
- : orb_ (CORBA::ORB::_duplicate (orb)),
- number_ (num)
-{
- this->object_group_ = CORBA::Object::_duplicate (object_group);
- this->lm_ = CosLoadBalancing::LoadManager::_duplicate (lm);
- this->location_ = CORBA::string_dup (loc);
-}
-
-CORBA::Short
-Basic::number (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- return this->number_;
-}
-
-char *
-Basic::get_string (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- return CORBA::string_dup (this->location_);
-}
-
-void
-Basic::remove_member (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- ACE_TRY
- {
- PortableGroup::Location location (1);
- location.length (1);
- location[0].id = CORBA::string_dup (this->location_);
- this->lm_->remove_member (this->object_group_.in (),
- location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) - Removed Member at Location <%s>\n",
- this->location_));
-
- }
- ACE_CATCH (PortableGroup::ObjectNotFound, ex)
- {
- ACE_PRINT_EXCEPTION (ex,
- "Caught exception in remove_member");
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
- ACE_CATCH (PortableGroup::MemberNotFound, ex)
- {
- ACE_PRINT_EXCEPTION (ex,
- "Caught exception in remove_member");
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while destroying member\n");
- }
- ACE_ENDTRY;
-
-}
-
-void
-Basic::shutdown (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- this->orb_->shutdown (0 ACE_ENV_ARG_PARAMETER);
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.h
deleted file mode 100644
index ad2bb53be84..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Basic.h
+++ /dev/null
@@ -1,64 +0,0 @@
-// -*- C++ -*-
-//
-// $Id$
-
-#ifndef BASIC_H
-#define BASIC_H
-
-#include "TestS.h"
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroupC.h"
-
-#if defined (_MSC_VER)
-# pragma warning(push)
-# pragma warning (disable:4250)
-#endif /* _MSC_VER */
-
-/// Implement the Test::Basic interface
-class Basic
- : public virtual POA_Test::Basic
-{
-public:
- /// Constructor
- Basic (CORBA::Object_ptr object_group,
- CosLoadBalancing::LoadManager_ptr lm,
- CORBA::ORB_ptr orb,
- CORBA::Short num,
- const char *loc);
-
- virtual char * get_string (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual void shutdown (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual void remove_member (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual CORBA::Short number (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
-private:
- /// Use an ORB reference to convert strings to objects and shutdown
- /// the application.
- CORBA::ORB_var orb_;
-
- /// Load Manager Reference used to delete the servant reference from the
- /// object group.
- CosLoadBalancing::LoadManager_var lm_;
-
- /// location of the servant
- const char *location_ ;
-
- /// Object Group reference.
- CORBA::Object_var object_group_;
-
- /// ID of the servant
- CORBA::Short number_;
-};
-
-#if defined(_MSC_VER)
-# pragma warning(pop)
-#endif /* _MSC_VER */
-
-#endif /* BASIC_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.cpp
deleted file mode 100644
index 14c3fdcf727..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.cpp
+++ /dev/null
@@ -1,349 +0,0 @@
-#include "LB_server.h"
-#include "Basic.h"
-#include "Simple.h"
-
-#include "TestC.h"
-#include "ace/OS_NS_stdio.h"
-
-ACE_RCSID (Application_Controlled,
- LB_server,
- "$Id$")
-
-LB_server::LB_server (int argc, char **argv)
- : argc_ (argc)
- , argv_ (argv)
-{
-}
-
-int
-LB_server::destroy (void)
-{
- ACE_TRY_NEW_ENV
- {
- this->lm_->delete_object (this->basic_fcid_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->lm_->delete_object (this->simple_fcid_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->root_poa_->destroy (1, 1 ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- this->orb_->destroy (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while destroying LB_server\n");
- return -1;
- }
- ACE_ENDTRY;
- return 1;
-
-}
-
-CORBA::ORB_ptr
-LB_server::orb (void)
-{
- return this->orb_.in ();
-}
-
-CORBA::Object_ptr
-LB_server::get_basic_object_group (void)
-{
- return this->basic_object_group_.in ();
-}
-
-CORBA::Object_ptr
-LB_server::get_simple_object_group (void)
-{
- return this->simple_object_group_.in ();
-}
-
-CosLoadBalancing::LoadManager_ptr
-LB_server::load_manager (void)
-{
- return this->lm_.in ();
-}
-
-int
-LB_server::start_orb_and_poa (void)
-{
- ACE_DECLARE_NEW_CORBA_ENV;
- ACE_TRY
- {
- // Initialise the ORB.
- this->orb_ = CORBA::ORB_init (this->argc_,
- this->argv_,
- "" ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Object_var poa_object =
- this->orb_->resolve_initial_references("RootPOA"
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (poa_object.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to initialize the POA.\n"),
- 1);
-
- this->root_poa_ = PortableServer::POA::_narrow (poa_object.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableServer::POAManager_var poa_manager =
- this->root_poa_->the_POAManager (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- poa_manager->activate (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Object_var obj =
- this->orb_->resolve_initial_references ("LoadManager" ACE_ENV_ARG_PARAMETER);
-
- this->lm_ =
- CosLoadBalancing::LoadManager::_narrow (obj.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (CORBA::is_nil (this->lm_.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to get Load Manager Reference\n"),
- 1);
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised initialising ORB or POA");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
-
-int
-LB_server::create_basic_object_group (void)
-{
- ACE_TRY_NEW_ENV
- {
- const char *repository_id = "IDL:Test/Basic:1.0";
-
- PortableGroup::Criteria criteria (1);
- criteria.length (1);
-
- PortableGroup::Property &property = criteria[0];
- property.nam.length (1);
-
- property.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.MembershipStyle");
-
- PortableGroup::MembershipStyleValue msv =
- PortableGroup::MEMB_APP_CTRL;
- property.val <<= msv;
-
- this->basic_object_group_ = this->lm_->create_object (repository_id,
- criteria,
- this->basic_fcid_.out ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::String_var ior =
- this->orb_->object_to_string (this->basic_object_group_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while creating object group");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
-
-int
-LB_server::create_simple_object_group (void)
-{
- ACE_TRY_NEW_ENV
- {
- const char *repository_id = "IDL:Test/Simple:1.0";
-
- PortableGroup::Criteria criteria (1);
- criteria.length (1);
-
- PortableGroup::Property &property = criteria[0];
- property.nam.length (1);
-
- property.nam[0].id =
- CORBA::string_dup ("org.omg.PortableGroup.MembershipStyle");
-
- PortableGroup::MembershipStyleValue msv =
- PortableGroup::MEMB_APP_CTRL;
- property.val <<= msv;
-
- this->simple_object_group_ = this->lm_->create_object (repository_id,
- criteria,
- this->simple_fcid_.out ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::String_var ior =
- this->orb_->object_to_string (this->simple_object_group_.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while creating object group");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-
-}
-
-int
-LB_server::remove_basic_member (void)
-{
- ACE_TRY_NEW_ENV
- {
- PortableGroup::Location location (1);
- location.length (1);
-
- location[0].id = CORBA::string_dup ("MyLocation 1");
-
- const char *loc = "MyLocation 1";
-
- this->lm_->remove_member (this->basic_object_group_.in (),
- location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- printf("Removed Basic Member at location %s\n\n", loc);
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while deleting servant");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-}
-
-int
-LB_server::remove_simple_member (void)
-{
- ACE_TRY_NEW_ENV
- {
- PortableGroup::Location location (1);
- location.length (1);
-
- location[0].id = CORBA::string_dup ("MyLocation 1");
-
- const char *loc = "MyLocation 1";
-
- this->lm_->remove_member (this->simple_object_group_.in (),
- location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- printf("Removed Simple Member at location %s\n\n", loc);
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while deleting servant");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-}
-
-int
-LB_server::register_basic_servant (Basic *servant, const char *loc)
-{
- ACE_TRY_NEW_ENV
- {
- Test::Basic_var basic =
- servant->_this (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableGroup::Location location (1);
- location.length (1);
-
- location[0].id = CORBA::string_dup (loc);
-
- this->lm_->add_member (this->basic_object_group_.in (),
- location,
- basic.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Short number = 0;
- number = servant->number (ACE_ENV_SINGLE_ARG_PARAMETER);
-
- printf("Added Basic member %d at location %s\n", number, loc);
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while registering servant");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-}
-
-int
-LB_server::register_simple_servant (Simple *servant, const char *loc)
-{
- ACE_TRY_NEW_ENV
- {
- Test::Simple_var simple =
- servant->_this (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- PortableGroup::Location location (1);
- location.length (1);
-
- location[0].id = CORBA::string_dup (loc);
-
- this->lm_->add_member (this->simple_object_group_.in (),
- location,
- simple.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CORBA::Short number = 0;
- number = servant->number (ACE_ENV_SINGLE_ARG_PARAMETER);
-
- printf("Added Simple member %d at location %s\n", number, loc);
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception raised while registering servant");
- return -1;
- }
- ACE_ENDTRY;
-
- return 1;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.h
deleted file mode 100644
index dd8366cf547..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/LB_server.h
+++ /dev/null
@@ -1,107 +0,0 @@
-// -*- C++ -*-
-
-//=============================================================================
-/**
- * @file LB_server.h
- *
- * $Id$
- *
- * @author Jaiganesh Balasubramanian <jai@doc.ece.uci.edu>
- * @author Ossama Othman <ossama@uci.edu>
- */
-//=============================================================================
-
-
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroupC.h"
-#include "tao/PortableServer/PortableServer.h"
-
-// Forward Declaration of the kind of servant we would like to handle
-// by the server.
-class Basic;
-class Simple;
-
-/**
- * @class LB_server
- *
- * @brief Encapsulate the test in class.
- *
- * This is a class used to retrieve the LoadManager reference and
- * create the Object Group. Servants add themselves to the object
- * group and the object group reference is published to the clients.
- * Clients then invoke the "servant operations" on the LoadManager
- * itself. At this point the Load Balancing cycle starts.
- */
-class LB_server
-{
-public:
-
- /// Constructor
- LB_server (int argc, char **argv);
-
- /// destroys LoadManager, ORB and POA.
- int destroy (void);
-
- /// start the ORB.
- int start_orb_and_poa (void);
-
- /// Get the LoadManager Interface.
- int init (int argc, char **argv);
-
- /// Create the basic Object Group using the Load Manager Reference.
- int create_basic_object_group (void);
-
- /// Create the simple Object Group using the Load Manager Reference.
- int create_simple_object_group (void);
-
- /// remove the basic member from the object group
- int remove_basic_member (void);
-
- /// remove the simple member from the object group
- int remove_simple_member (void);
-
- /// register the basic servants with the object group.
- int register_basic_servant (Basic *servant, const char *loc);
-
- /// register the simple servants with the object group.
- int register_simple_servant (Simple *servant, const char *loc);
-
- /// for servants to register to the initialised ORB.
- CORBA::ORB_ptr orb (void);
-
- /// for servants to get the reference for object_group.
- CORBA::Object_ptr get_basic_object_group (void);
-
- /// for servants to get the reference for object_group.
- CORBA::Object_ptr get_simple_object_group (void);
-
- /// for servants to get the reference for object_group.
- CosLoadBalancing::LoadManager_ptr load_manager (void);
-
-private:
-
- /// Load Manager
- CosLoadBalancing::LoadManager_var lm_;
-
- /// Basic Object Group.
- CORBA::Object_var basic_object_group_;
-
- /// Simple Object Group.
- CORBA::Object_var simple_object_group_;
-
- /// factory id for the basic object group.
- PortableGroup::GenericFactory::FactoryCreationId_var basic_fcid_;
-
- /// factory id for the simple object group.
- PortableGroup::GenericFactory::FactoryCreationId_var simple_fcid_;
-
- /// ORB pointer
- CORBA::ORB_var orb_;
-
- /// command line arguments
- int argc_;
- char **argv_;
-
- /// root poa pointer
- PortableServer::POA_var root_poa_;
-};
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Makefile.am
deleted file mode 100644
index 8f8d87249e8..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Makefile.am
+++ /dev/null
@@ -1,110 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-ACE_BUILDDIR = $(top_builddir)/..
-ACE_ROOT = $(top_srcdir)/..
-TAO_BUILDDIR = $(top_builddir)
-TAO_IDL = ACE_ROOT=$(ACE_ROOT) TAO_ROOT=$(TAO_ROOT) $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDL_DEP = $(TAO_BUILDDIR)/TAO_IDL/tao_idl
-TAO_IDLFLAGS = -Ge 1 -Wb,pre_include=ace/pre.h -Wb,post_include=ace/post.h -I$(TAO_ROOT) -I$(srcdir) -g $(ACE_BUILDDIR)/apps/gperf/src/gperf
-TAO_ROOT = $(top_srcdir)
-
-
-## Makefile.Manage_Object_Group_Server.am
-
-if BUILD_AMI
-if BUILD_CORBA_MESSAGING
-if !BUILD_MINIMUM_CORBA
-
-BUILT_SOURCES = \
- TestC.cpp \
- TestC.h \
- TestC.inl \
- TestS.cpp \
- TestS.h \
- TestS.inl \
- TestS_T.cpp \
- TestS_T.h \
- TestS_T.inl
-
-CLEANFILES = \
- Test-stamp \
- TestC.cpp \
- TestC.h \
- TestC.inl \
- TestS.cpp \
- TestS.h \
- TestS.inl \
- TestS_T.cpp \
- TestS_T.h \
- TestS_T.inl
-
-TestC.cpp TestC.h TestC.inl TestS.cpp TestS.h TestS.inl TestS_T.cpp TestS_T.h TestS_T.inl: Test-stamp
-
-Test-stamp: $(srcdir)/Test.idl $(TAO_IDL_DEP)
- $(TAO_IDL) $(TAO_IDLFLAGS) -I$(TAO_ROOT)/orbsvcs -GT $(srcdir)/Test.idl
- @touch $@
-
-noinst_PROGRAMS = server
-
-server_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I$(TAO_ROOT)/orbsvcs \
- -I$(TAO_BUILDDIR)/orbsvcs
-
-server_SOURCES = \
- Basic.cpp \
- LB_server.cpp \
- Simple.cpp \
- TestC.cpp \
- TestS.cpp \
- server.cpp \
- Basic.h \
- LB_server.h \
- Simple.h \
- TestC.h \
- TestC.inl \
- TestS.h \
- TestS.inl \
- TestS_T.h \
- TestS_T.inl
-
-server_LDADD = \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_Svc_Utils.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosLoadBalancing.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORInterceptor.la \
- $(TAO_BUILDDIR)/tao/libTAO_ObjRefTemplate.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI_Server.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_PortableGroup.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORManip.la \
- $(TAO_BUILDDIR)/tao/libTAO_Messaging.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI.la \
- $(TAO_BUILDDIR)/tao/libTAO_CodecFactory.la \
- $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \
- $(TAO_BUILDDIR)/tao/libTAO_Valuetype.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \
- $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \
- $(TAO_BUILDDIR)/tao/libTAO.la \
- $(ACE_BUILDDIR)/ace/libACE.la
-
-endif !BUILD_MINIMUM_CORBA
-endif BUILD_CORBA_MESSAGING
-endif BUILD_AMI
-
-## Clean up template repositories, etc.
-clean-local:
- -rm -f *~ *.bak *.rpo *.sym lib*.*_pure_* core core.*
- -rm -f gcctemp.c gcctemp so_locations *.ics
- -rm -rf cxx_repository ptrepository ti_files
- -rm -rf templateregistry ir.out
- -rm -rf ptrepository SunWS_cache Templates.DB
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Manage_Object_Group.mpc b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Manage_Object_Group.mpc
deleted file mode 100644
index 118d41248d2..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Manage_Object_Group.mpc
+++ /dev/null
@@ -1,11 +0,0 @@
-// -*- MPC -*-
-// $Id$
-
-project(*server): orbsvcsexe, portablegroup, loadbalancing, naming, svc_utils {
- Source_Files {
- server.cpp
- LB_server.cpp
- Basic.cpp
- Simple.cpp
- }
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.cpp
deleted file mode 100644
index 7949918ee73..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.cpp
+++ /dev/null
@@ -1,81 +0,0 @@
-#include "Simple.h"
-#include "LB_server.h"
-
-
-ACE_RCSID (Application_Controlled,
- Simple,
- "$Id$")
-
-
-Simple::Simple (CORBA::Object_ptr object_group,
- CosLoadBalancing::LoadManager_ptr lm,
- CORBA::ORB_ptr orb,
- CORBA::Short num,
- const char *loc)
- : orb_ (CORBA::ORB::_duplicate (orb)),
- number_ (num)
-{
- this->object_group_ = CORBA::Object::_duplicate (object_group);
- this->lm_ = CosLoadBalancing::LoadManager::_duplicate (lm);
- this->location_ = CORBA::string_dup (loc);
-}
-
-CORBA::Short
-Simple::number (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- return this->number_;
-}
-
-char *
-Simple::get_string (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- return CORBA::string_dup (this->location_);
-}
-
-void
-Simple::remove_member (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- ACE_TRY
- {
- PortableGroup::Location location (1);
- location.length (1);
- location[0].id = CORBA::string_dup (this->location_);
- this->lm_->remove_member (this->object_group_.in (),
- location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) - Removed Member at Location <%s>\n",
- this->location_));
-
- }
- ACE_CATCH (PortableGroup::ObjectNotFound, ex)
- {
- ACE_PRINT_EXCEPTION (ex,
- "Caught exception in remove_member");
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
- ACE_CATCH (PortableGroup::MemberNotFound, ex)
- {
- ACE_PRINT_EXCEPTION (ex,
- "Caught exception in remove_member");
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught while destroying member\n");
- }
- ACE_ENDTRY;
-
-}
-
-void
-Simple::shutdown (ACE_ENV_SINGLE_ARG_DECL)
- ACE_THROW_SPEC ((CORBA::SystemException))
-{
- this->orb_->shutdown (0 ACE_ENV_ARG_PARAMETER);
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.h b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.h
deleted file mode 100644
index 0a3d63efa23..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Simple.h
+++ /dev/null
@@ -1,66 +0,0 @@
-// -*- C++ -*-
-//
-// $Id$
-
-#ifndef SIMPLE_H
-#define SIMPLE_H
-
-#include "TestS.h"
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroupC.h"
-
-#if defined (_MSC_VER)
-# pragma warning(push)
-# pragma warning (disable:4250)
-#endif /* _MSC_VER */
-
-class LB_Basic_Test;
-
-/// Implement the Test::Simple interface
-class Simple
- : public virtual POA_Test::Simple
-{
-public:
- /// Constructor
- Simple (CORBA::Object_ptr object_group,
- CosLoadBalancing::LoadManager_ptr lm,
- CORBA::ORB_ptr orb,
- CORBA::Short num,
- const char *loc);
-
- virtual char * get_string (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual void shutdown (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual void remove_member (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
- virtual CORBA::Short number (ACE_ENV_SINGLE_ARG_DECL_WITH_DEFAULTS)
- ACE_THROW_SPEC ((CORBA::SystemException));
-
-private:
- /// Use an ORB reference to convert strings to objects and shutdown
- /// the application.
- CORBA::ORB_var orb_;
-
- /// Load Manager Reference used to delete the servant reference from the
- /// object group.
- CosLoadBalancing::LoadManager_var lm_;
-
- /// location of the servant
- const char *location_ ;
-
- /// Object Group reference.
- CORBA::Object_var object_group_;
-
- /// ID of the servant
- CORBA::Short number_;
-};
-
-#if defined(_MSC_VER)
-# pragma warning(pop)
-#endif /* _MSC_VER */
-
-#endif /* SIMPLE_H */
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Test.idl b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Test.idl
deleted file mode 100644
index 25e2829b394..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/Test.idl
+++ /dev/null
@@ -1,38 +0,0 @@
-//
-// $Id$
-
-/// Put the interfaces in a module, to avoid global namespace pollution
-module Test
-{
- /// A very simple interface
- interface Basic
- {
- /// Return a simple string
- string get_string ();
-
- /// A method to shutdown the ORB
- /**
- * This method is used to simplify the test shutdown process
- */
- oneway void shutdown ();
-
- /// A method to remove the servant from the LoadManager Object Group.
- oneway void remove_member ();
- };
-
- /// A very simple interface
- interface Simple
- {
- /// Return a simple string
- string get_string ();
-
- /// A method to shutdown the ORB
- /**
- * This method is used to simplify the test shutdown process
- */
- oneway void shutdown ();
-
- /// A method to remove the servant from the LoadManager Object Group.
- oneway void remove_member ();
- };
-};
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/run_test.pl b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/run_test.pl
deleted file mode 100755
index 4795e26e74d..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/run_test.pl
+++ /dev/null
@@ -1,61 +0,0 @@
-eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
- & eval 'exec perl -S $0 $argv:q'
- if 0;
-
-# $Id$
-# -*- perl -*-
-
-use lib "../../../../../../bin";
-use PerlACE::Run_Test;
-
-$lm_ior = "lm.ior";
-unlink $lm_ior;
-
-$status = 0;
-
-## The LoadManager needs to register signals with the ORB's reactor (on
-## Windows only) and thus can not use the TP Reactor since it doesn't
-## support that kind of thing. So, we swith to the Select MT Reactor.
-$lm_conf = PerlACE::LocalFile ("windows$PerlACE::svcconf_ext");
-
-$init_ref = "-ORBInitRef LoadManager=file://lm.ior";
-
-$LM = new PerlACE::Process ("../../../../LoadBalancer/LoadManager",
- "-o lm.ior" . ($^O eq 'MSWin32' ?
- " -ORBSvcConf $lm_conf" : ''));
-$SV = new PerlACE::Process ("server", $init_ref);
-
-print STDERR "\n\n======== Running Manage ObjectGroup Membership Test================\n";
-print STDERR "\n";
-
-print STDERR "This test will check the add_member () and remove_member () methods of the\n";
-print STDERR "ObjectGroupManager\n";
-print STDERR "\n";
-
-$LM->Spawn ();
-
-if (PerlACE::waitforfile_timed ("lm.ior", 5) == -1) {
- print STDERR "ERROR: cannot find file LoadManager IOR: lm.ior\n";
- $SV->Kill (); $SV->TimedWait (1);
- exit 1;
-}
-
-$SV->Spawn ();
-
-$server = $SV->WaitKill (10);
-
-if ($server != 0) {
- print STDERR "ERROR: server returned $server\n";
- $status = 1;
-}
-
-$load_manager = $LM->TerminateWaitKill (10);
-
-if ($load_manager != 0) {
- print STDERR "ERROR: LoadManager returned $load_manager\n";
- $status = 1;
-}
-
-unlink $lm_ior;
-
-exit $status;
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/server.cpp b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/server.cpp
deleted file mode 100644
index 4f4724ab6c6..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/server.cpp
+++ /dev/null
@@ -1,132 +0,0 @@
-#include "LB_server.h"
-#include "Basic.h"
-#include "Simple.h"
-
-ACE_RCSID (Manage_object_group,
- server,
- "$Id$")
-
-int
-main (int argc, char *argv[])
-{
- ACE_TRY_NEW_ENV
- {
- const char *location1 = "MyLocation 1";
-
- LB_server lb_server (argc, argv);
-
- if (lb_server.start_orb_and_poa () == -1)
- return 1;
-
- if (lb_server.create_basic_object_group () == -1)
- return 1;
-
- if (lb_server.create_simple_object_group () == -1)
- return 1;
-
- Basic *basic_servant1;
- Basic *basic_servant2;
-
- Simple *simple_servant1;
- Simple *simple_servant2;
-
-
- ACE_NEW_RETURN (basic_servant1,
- Basic (lb_server.get_basic_object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- 1,
- location1),
- 1);
- PortableServer::ServantBase_var basic_owner_transfer1(basic_servant1);
-
- ACE_NEW_RETURN (simple_servant1,
- Simple (lb_server.get_simple_object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- 1,
- location1),
- 1);
- PortableServer::ServantBase_var simple_owner_transfer1(simple_servant1);
-
- if (lb_server.register_basic_servant (basic_servant1, location1) == -1)
- {
- (void) lb_server.destroy();
- return 1;
- }
-
- if (lb_server.register_simple_servant (simple_servant1, location1) == -1)
- {
- (void) lb_server.destroy();
- return 1;
- }
-
- if (lb_server.remove_basic_member() == -1)
- {
- return 1;
- }
-
- if (lb_server.remove_simple_member() == -1)
- {
- return 1;
- }
-
- ACE_NEW_RETURN (basic_servant2,
- Basic (lb_server.get_basic_object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- 2,
- location1),
- 1);
- PortableServer::ServantBase_var basic_owner_transfer2(basic_servant2);
-
- ACE_NEW_RETURN (simple_servant2,
- Simple (lb_server.get_simple_object_group (),
- lb_server.load_manager (),
- lb_server.orb (),
- 2,
- location1),
- 1);
- PortableServer::ServantBase_var simple_owner_transfer2(simple_servant2);
-
- if (lb_server.register_basic_servant (basic_servant2, location1) == -1)
- {
- (void) lb_server.destroy();
- return 1;
- }
-
- if (lb_server.register_simple_servant (simple_servant2, location1) == -1)
- {
- (void) lb_server.destroy();
- return 1;
- }
-
- if (lb_server.remove_basic_member() == -1)
- {
- return 1;
- }
-
- if (lb_server.remove_simple_member() == -1)
- {
- return 1;
- }
-
- lb_server.orb ()->shutdown (0 ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_DEBUG, "(%P|%t) server - event loop finished\n"));
-
- if (lb_server.destroy () == -1)
- return 1;
-
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "lb_server exception");
- return 1;
- }
- ACE_ENDTRY;
-
- return 0;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf
deleted file mode 100644
index 06c425e3ecf..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf
+++ /dev/null
@@ -1,3 +0,0 @@
-# $Id $
-
-dynamic Advanced_Resource_Factory Service_Object* TAO_Strategies:_make_TAO_Advanced_Resource_Factory () "-ORBReactorType select_mt"
diff --git a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf.xml b/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf.xml
deleted file mode 100644
index 289810f7d22..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/GenericFactory/Manage_Object_Group/windows.conf.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version='1.0'?>
-<!-- Converted from windows.conf by svcconf-convert.pl -->
-<ACE_Svc_Conf>
- <!-- $Id $ -->
- <dynamic id="Advanced_Resource_Factory" type="Service_Object">
- <initializer path="TAO_Strategies" init="_make_TAO_Advanced_Resource_Factory" params="-ORBReactorType select_mt"/>
- </dynamic>
-</ACE_Svc_Conf>
diff --git a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/LoadMonitorCPU.mpc b/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/LoadMonitorCPU.mpc
deleted file mode 100644
index 55c91a8d3df..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/LoadMonitorCPU.mpc
+++ /dev/null
@@ -1,4 +0,0 @@
-// $Id$
-
-project(*Client): loadbalancing {
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/Makefile.am
deleted file mode 100644
index f9c6fe2837e..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/Makefile.am
+++ /dev/null
@@ -1,63 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-ACE_BUILDDIR = $(top_builddir)/..
-ACE_ROOT = $(top_srcdir)/..
-TAO_BUILDDIR = $(top_builddir)
-TAO_ROOT = $(top_srcdir)
-
-
-## Makefile.LoadMonitorCPU_Client.am
-
-if BUILD_AMI
-if BUILD_CORBA_MESSAGING
-if !BUILD_MINIMUM_CORBA
-
-noinst_PROGRAMS = client
-
-client_CPPFLAGS = \
- -I$(ACE_ROOT) \
- -I$(ACE_BUILDDIR) \
- -I$(TAO_ROOT) \
- -I$(TAO_BUILDDIR) \
- -I$(TAO_ROOT)/orbsvcs \
- -I$(TAO_BUILDDIR)/orbsvcs
-
-client_SOURCES = \
- client.cpp
-
-client_LDADD = \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosLoadBalancing.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORInterceptor.la \
- $(TAO_BUILDDIR)/tao/libTAO_ObjRefTemplate.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI_Server.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_PortableGroup.la \
- $(TAO_BUILDDIR)/tao/libTAO_IORManip.la \
- $(TAO_BUILDDIR)/orbsvcs/orbsvcs/libTAO_CosNaming.la \
- $(TAO_BUILDDIR)/tao/libTAO_Messaging.la \
- $(TAO_BUILDDIR)/tao/libTAO_PI.la \
- $(TAO_BUILDDIR)/tao/libTAO_CodecFactory.la \
- $(TAO_BUILDDIR)/tao/libTAO_PortableServer.la \
- $(TAO_BUILDDIR)/tao/libTAO_Valuetype.la \
- $(TAO_BUILDDIR)/tao/libTAO_AnyTypeCode.la \
- $(TAO_BUILDDIR)/tao/libTAO.la \
- $(ACE_BUILDDIR)/ace/libACE.la
-
-endif !BUILD_MINIMUM_CORBA
-endif BUILD_CORBA_MESSAGING
-endif BUILD_AMI
-
-## Clean up template repositories, etc.
-clean-local:
- -rm -f *~ *.bak *.rpo *.sym lib*.*_pure_* core core.*
- -rm -f gcctemp.c gcctemp so_locations *.ics
- -rm -rf cxx_repository ptrepository ti_files
- -rm -rf templateregistry ir.out
- -rm -rf ptrepository SunWS_cache Templates.DB
diff --git a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/README b/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/README
deleted file mode 100644
index ee845ff6081..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/README
+++ /dev/null
@@ -1,11 +0,0 @@
-# $Id$
-
-This test verifies that Cygnus' CPU load monitor is working correctly.
-Run the test using the `run_test.pl' Perl script. The expected test
-output is the following:
-
-==== Running CPU Load Monitor test
-
-Retrieving loads from LoadManager ...... DONE
-Retrieving loads directly from LoadMonitor ... DONE
-CPU Load Monitor test passed.
diff --git a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/client.cpp b/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/client.cpp
deleted file mode 100644
index ccae399abb8..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/client.cpp
+++ /dev/null
@@ -1,180 +0,0 @@
-// $Id$
-
-#include "orbsvcs/CosLoadBalancingC.h"
-#include "orbsvcs/PortableGroup/PG_Operators.h"
-#include "ace/Get_Opt.h"
-#include "ace/OS_NS_unistd.h"
-
-ACE_RCSID (CPU,
- client,
- "$Id$")
-
-
-const char * location = "MyLocation";
-
-const int MAX_RETRIES = 10;
-const CosLoadBalancing::LoadId LOAD_ID = CosLoadBalancing::LoadAverage;
-
-int
-parse_args (int argc, char *argv[])
-{
- ACE_Get_Opt get_opts (argc, argv, "l:");
-
- int c;
-
- while ((c = get_opts ()) != -1)
- switch (c)
- {
- case 'l':
- location = get_opts.opt_arg ();
- break;
-
- default:
- ACE_ERROR_RETURN ((LM_ERROR,
- "Usage: %s -l <ior>\n",
- argv[0]),
- -1);
- }
-
- return 0;
-}
-
-void
-check_loads (const CosLoadBalancing::LoadList & loads
- ACE_ENV_ARG_DECL)
-{
- if (loads.length () != 1)
- {
- ACE_ERROR ((LM_ERROR,
- "ERROR: Load list length is not equal to one.\n"));
-
- ACE_THROW (CORBA::INTERNAL ());
- }
-
- if (loads[0].id != LOAD_ID
- || loads[0].value < 0)
- {
- ACE_ERROR ((LM_ERROR,
- "ERROR: Returned load is not a CPU load.\n"));
-
- ACE_THROW (CORBA::INTERNAL ());
- }
-}
-
-int
-main (int argc, char *argv[])
-{
- ACE_DECLARE_NEW_CORBA_ENV;
- ACE_TRY
- {
- CORBA::ORB_var orb =
- CORBA::ORB_init (argc,
- argv,
- ""
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- // Obtain a reference to the LoadManager.
- CORBA::Object_var obj =
- orb->resolve_initial_references ("LoadManager"
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CosLoadBalancing::LoadManager_var lm =
- CosLoadBalancing::LoadManager::_narrow (obj.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CosLoadBalancing::Location the_location (1);
- the_location.length (1);
-
- the_location[0].id = CORBA::string_dup (location);
-
- // Attempt to get loads from the LoadManager.
- ACE_DEBUG ((LM_INFO,
- "\n"
- "Retrieving loads from LoadManager ..."));
-
- CosLoadBalancing::LoadList_var loads;
-
- CORBA::Boolean retrieved_load = 0;
-
- // Try a few times until a load is capable of being retrieved.
- for (int i = 0; i < MAX_RETRIES && retrieved_load == 0; ++i)
- {
- ACE_TRY_EX (foo)
- {
- loads = lm->get_loads (the_location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK_EX (foo);
-
- retrieved_load = 1;
- }
- ACE_CATCHANY
- {
- ACE_DEBUG ((LM_DEBUG, ".")); // Show some progress.
-
- // Give some time for loads to be reported to the
- // LoadManager.
- ACE_OS::sleep (2);
- }
- ACE_ENDTRY;
- ACE_TRY_CHECK;
- }
-
- if (retrieved_load == 0)
- ACE_ERROR_RETURN ((LM_ERROR,
- "\nERROR: Unable to retrieve loads "
- "from LoadManager.\n"),
- -1);
- else
- ACE_DEBUG ((LM_INFO,
- " DONE\n"));
-
- ::check_loads (loads.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- // Attempt to get loads directly from the LoadMonitor.
- CosLoadBalancing::LoadMonitor_var monitor =
- lm->get_load_monitor (the_location
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- CosLoadBalancing::Location_var cpu_mon_location =
- monitor->the_location (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- if (cpu_mon_location.in () != the_location)
- {
- ACE_ERROR ((LM_ERROR,
- "ERROR: Mismatched CPU load monitor location\n"));
-
- ACE_TRY_THROW (CORBA::INTERNAL ());
- }
-
- ACE_DEBUG ((LM_INFO,
- "Retrieving loads directly from LoadMonitor ..."));
-
- loads = monitor->loads (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
-
- ACE_DEBUG ((LM_INFO,
- " DONE\n"));
-
- ::check_loads (loads.in ()
- ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
- }
- ACE_CATCHANY
- {
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "CPU Load Monitor test:");
- return -1;
- }
- ACE_ENDTRY;
-
- ACE_DEBUG ((LM_INFO, "CPU Load Monitor test passed.\n\n"));
-
- return 0;
-}
diff --git a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/run_test.pl b/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/run_test.pl
deleted file mode 100755
index 7b7ed466ffc..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/CPU/run_test.pl
+++ /dev/null
@@ -1,61 +0,0 @@
-eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
- & eval 'exec perl -S $0 $argv:q'
- if 0;
-
-# -*- perl -*-
-# $Id$
-
-use lib "../../../../../../bin";
-use PerlACE::Run_Test;
-
-print STDERR "\n\n==== Running CPU Load Monitor test\n";
-
-
-$lm_ior = "lm.ior";
-unlink $lm_ior;
-
-$status = 0;
-
-$init_ref = "-ORBInitRef LoadManager=file://" . $lm_ior;
-
-$location = "MyLocation";
-
-$LM = new PerlACE::Process ("../../../../LoadBalancer/LoadManager",
- "-o " . $lm_ior);
-
-$MON = new PerlACE::Process ("../../../../LoadBalancer/LoadMonitor",
- "-l " . $location
- . " -t CPU -s PULL "
- . $init_ref);
-
-$CL = new PerlACE::Process ("client",
- $init_ref
- . " -l " . $location);
-
-$LM->Spawn ();
-
-if (PerlACE::waitforfile_timed ($lm_ior, 8) == -1) {
- print STDERR "ERROR: cannot find file LoadManager IOR: " . $lm_ior ."\n";
- exit 1;
-}
-
-$MON->Spawn ();
-
-$client = $CL->SpawnWaitKill (100);
-
-if ($client != 0) {
- print STDERR "ERROR: client returned $client\n";
- $status = 1;
-}
-
-$load_monitor = $MON->TerminateWaitKill (10);
-$load_manager = $LM->TerminateWaitKill (10);
-
-if ($load_manager != 0 || $load_monitor != 0) {
- print STDERR "Error terminating LoadManager or LoadMonitor.\n";
- $status = 1;
-}
-
-unlink $lm_ior;
-
-exit $status;
diff --git a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/Makefile.am
deleted file mode 100644
index cc16d67d6f5..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/LoadMonitor/Makefile.am
+++ /dev/null
@@ -1,13 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-SUBDIRS = \
- CPU
-
diff --git a/TAO/orbsvcs/tests/LoadBalancing/Makefile.am b/TAO/orbsvcs/tests/LoadBalancing/Makefile.am
deleted file mode 100644
index aa65f76e141..00000000000
--- a/TAO/orbsvcs/tests/LoadBalancing/Makefile.am
+++ /dev/null
@@ -1,14 +0,0 @@
-## Process this file with automake to create Makefile.in
-##
-## $Id$
-##
-## This file was generated by MPC. Any changes made directly to
-## this file will be lost the next time it is generated.
-##
-## MPC Command:
-## ../bin/mwc.pl -type automake -noreldefs TAO.mwc
-
-SUBDIRS = \
- GenericFactory \
- LoadMonitor
-