5.2.2 Registering a Factory
For a client application to be able to obtain a reference to a factory, an application server must register a reference to any factory object for which it provides an implementation with the FactoryFinder. Using the Oracle Tuxedo CORBA TP Framework, the registration of the reference for the factory object can be accomplished using the TP::register_factory
operation, once a reference to a factory object has been created. The reference to the factory object, along with a value that identifies the factory, is passed to this operation. The registration of references to factory objects is typically done as part of initialization of the application (normally as part of the implementation of the operation Server::initialize)
.
Figure 5-1 Registering a Factory Object

When the server application is shutting down, it must unregister any references to factory objects that it has previously registered in the application server. This is done by passing the same reference to the factory object, along with the corresponding value used to identify the factory, to the TP::unregister_factory
operation. Once unregistered, the reference to the factory object can then be destroyed. The process of unregistering a factory with the FactoryFinder is typically done as part of the implementation of the Server::release
operation. For more information about these operations, see the section Server Interface.
Parent topic: Functional Description