diff options
Diffstat (limited to 'TAO/docs/releasenotes')
-rw-r--r-- | TAO/docs/releasenotes/TODO.html | 627 | ||||
-rw-r--r-- | TAO/docs/releasenotes/ec.html | 234 | ||||
-rw-r--r-- | TAO/docs/releasenotes/index.html | 786 | ||||
-rw-r--r-- | TAO/docs/releasenotes/orbcore.html | 503 | ||||
-rw-r--r-- | TAO/docs/releasenotes/trader.html | 1069 |
5 files changed, 0 insertions, 3219 deletions
diff --git a/TAO/docs/releasenotes/TODO.html b/TAO/docs/releasenotes/TODO.html deleted file mode 100644 index 786f173a0df..00000000000 --- a/TAO/docs/releasenotes/TODO.html +++ /dev/null @@ -1,627 +0,0 @@ -<HTML> -<HEAD> - <TITLE>TAO TODO List</TITLE> -</HEAD> - <BODY TEXT="#000000" BGCOLOR="#FFFFFF"> - <!-- $Id$ --> - <CENTER><HR></CENTER> - - <CENTER> - <H3>General TODO list for TAO</H3> - </CENTER> - - <P> - This document presents a general TODO list for TAO, - the list is not very well organized or prioritized; - it started as a personal TODO list for Carlos so it is biased - towards the Event Service and related components. - Hopefully as more people gets involved it will become more - organized. - </P> - <P> - Last Updated: $Date$ $Revision$ - </P> - - <CENTER><HR></CENTER> - - <CENTER> - <H4>Pending Tasks</H4> - </CENTER> - - <UL> - <LI>Add suspend and resume operations to the PushConsumerProxy - and PushSupplierProxy interfaces, following the Notification - Service spec. - </LI> - - <LI>The current implementation of octet sequences based on - message blocks has a few problems, it cannot marshall - chains of message blocks properly. - Notice that complete support for chains of message blocks will - complicate the sequence of octets implementation (like - operator[]) and will make others either hard or expensive - (like get_buffer ()). - </LI> - - <LI>The IDL compiler gets confused with paths in NT, this may be - due to my changes to report errors correctly. - </LI> - - <LI>The do_static_call() and do_dynamic_call() methods should - use an array of void* (in the first case static and generated - by the IDL compiler); - this will remove the problems with g++ and probably work - faster. - </LI> - - <LI>Object references inside structures or sequences are not - decoded properly, the problem starts because the interpreter - expects a CORBA::Object_ptr, but the real type is a T_var; - virtual inheritance adds the last ingredient to the poison. - <BR>[STATUS] A possible solution is to use a T_manager_var that - has two fields a Object_ptr and a T_ptr.... - </LI> - - <LI>Optimize twoways by delaying memory allocation for the - incoming data buffer, thus improving interleaving between the - client and server (the client does something useful before - starting to wait for the server). - </LI> - - <LI>Further optimize memory allocation by using a memory pool - for the incoming CDR stream. - </LI> - - <LI>Further optimize the outgoing memory allocation by adding - support for message blocks allocated from a pool (the - Message_Block class itself not the Data_Block or the buffer it - contains). - </LI> - - <LI>Add compiled marshalling - <BR>[STATUS] Andy is working on this. - </LI> - - <LI>Use active demuxing in the POA - </LI> - - <LI>The data blocks and their buffers could be allocated in a - single operation, using the beginning of a buffer to contain - the data block and the rest of it to contain the actual buffer - </LI> - - <LI>The size of pre-allocated buffer for the outgoing CDR - streams is defined at compilation time; but if we use an - efficient enough allocator we could make its size configurable - via the svc.conf file. In any case the *second* (and - subsequent) buffers come out of the allocator, so their sizes - could be configured in the already mentioned file - </LI> - - <LI>We need some TAO_TRY_* macro to encapsulate a common use of - the CORBA::Environment argument: checking if it contains an - exception and then returning. - </LI> - - <LI>The TypeCode internal (private) state needs locking, double - checked locking is needed to avoid excessive overhead, there - is potential for memory leaks if this locking is not used. - </LI> - - <LI>IDL compiler front-end should be case insensitive (actually - it should flag identifiers that only differ by case as a - conflict). - </LI> - - <LI>Support for 64bit longs in the IDL compiler - </LI> - - <LI>The operation tables do not need to be statics, they could - be created on creation of the first servant of that type. - </LI> - - <LI>Are nested upcalls in different concurrency models, like - thread-per-connection working? - </LI> - - <LI>Add an option to the IDL-compiler (e.g. -rp) meaning - "generate relative include paths". - </LI> - - <LI>The IDL compiler should generate the files locally (maybe - with an option). - </LI> - - <LI>Add options to the IDL compiler to set the suffixes. - </LI> - - <LI>The IDL compiler should generate the code locally (not in - the directory where the .idl resides) or at least give an - option to do so - </LI> - - <LI>Support for unions with default cases (implicit or explicit) - in the IDL compiler is incomplete. - </LI> - - <LI>It seems that some memory is leaked from the ORB cached - connector. - </LI> - - <LI>Support for fixed in the IDL compiler - </LI> - - <LI>CDR stream support for wchar is flaky. - </LI> - - <LI>Add a corbafwd.h header file to eliminate the deep (and - recursive) header dependencies in TAO. - </LI> - - <LI>Prepare the 1.0 release: - <UL> - <LI>Integrate the compiled marshalling approach. - </LI> - <LI>Verify the GPERF is working in all the relevant - platforms. - </LI> - <LI>Integrate active demux of operations? - </LI> - </UL> - </LI> - - <LI>Support the Sun bootstrapping mechanism for the Naming - Service - </LI> - - <LI>Add a -ORBlogfile flag so we can set the ACE_ERROR and - ACE_DEBUG output destination in all TAO applications - </LI> - - <LI>Add the _raise() method to the exceptions... - </LI> - - <LI>Add support for multiple Profiles in the ORB (completing the - IIOP 1.0 support) - </LI> - - <LI>Purify, purify, purify the EC - </LI> - - <LI>Quantify the EC. - </LI> - - <LI>Support several calls to ORB_init() on the same thread. - </LI> - - <LI>Support IIOP 1.1 in the ORB - </LI> - - <LI>Use the IIOP 1.1 profile info to pass QoS info and use it to - preserve end-to-end QoS. - </LI> - - <LI>Debug Memory Pools in the EC there seem to be a problem when - sending multiple events in a row (a memory leak, limit or - corruption). - </LI> - - <LI>Call ORB_init() in the EC threads? - [The dispatching threads for Boeing] - </LI> - - <LI>Build an EC example that uses all the cool features - (multiple ORBs on each process, collocated EC and Scheduling - service, Naming, etc.) - </LI> - - <LI>Extend the Concurrency Service (or create a new one) that - allow us to have global "barriers" to synchronize EC - startup/shutdown. - </LI> - - <LI>Correlation in the EC has a bug [?] - Build regression tests for the EC features (filtering, - correlation, timers, etc). - </LI> - - <LI>Build a COS Event Channel on top of the RTEC Event Service. - </LI> - - <LI>Check what is failing in $TAO_ROOT/tests/CDR/tc. - </LI> - - <LI>Debug interval computation in Linux (and NT?) - </LI> - - <LI>Remove the uneeded methods from CORBA::Object - </LI> - - <LI>Implement operation demuxing for clients. - </LI> - - <LI>Study the CORBAlite spec and see how we could implement it - with TAO, considering dynamic and static configurations for - the full CORBA support - </LI> - - <LI><P>The CORBAlite RFP is very interesting IMHO we just need to - remove features from TAO to make it a CORBAlite - implementation. The problem is how to keep the full blown - CORBA implementation also, this is an idea: - Write the TAOlite version of a class (example TypeCode):</P> - - <PRE> - class TAO_CORBAlite_TypeCode { - // Just the CORBAlite methods are implemented. - }; - </PRE> - - <P>Derive the full blown implementation:</P> - - <PRE> - class TAO_CORBA_TypeCode : public TAO_CORBAlite_TypeCode { - // Declare all the other methods. - }; - </PRE> - - <P>create two namespaces:</P> - - <PRE> - // in tao/CORBAlite.h - class CORBA { - tyedef TAO_CORBAlite_TypeCode TypeCode; - }; - - // in tao/CORBAfull.h - class CORBA { - typedef TAO_CORBAfull_TypeCode TypeCode; - }; - </PRE> - - <P>then (at compile time) the users chooses between the CORBAlite - or CORBAfull implementations:</P> - - <PRE> - // In $TAO_ROOT/tao/corba.h - #if USERS_WANTS_FAT_FREE_CORBA - #include "tao/CORBAlite.h" - #else - #include "tao/CORBAfull.h" - #endif - </PRE> - - <P>We need to consider how to support even smaller profiles that - the CORBAlite RFP, like removing <any> or <fixed> support. - We also need to come out with a scheme to support - interpretive marshalling in the CORBAlite framework (where - TypeCodes don't have enough methods as to traverse them). - </P> - </LI> - - <LI>Consider decompositions of the ORB that would allow - dynamically linked plug-ins, examples of things that would be - easy to implement as plugins: - <UL> - <LI>SSL support - </LI> - <LI>UNIX socket support - </LI> - </UL> - Things that would be really hard: - <UL> - <LI>Dynamically load the support for costly features, as the - ImplRepo or Location Forwarding. - </LI> - <LI>Dynamically configure POA with or without support for - holding state. - </LI> - </UL> - </LI> - - <LI>Currently the IDL compiler creates an operation table that - includes all the base classes operations; this permits the - generation of efficient code that does not rely in - dynamic_cast or the _downcast() method for Servanst (which - compare strings, hence it is slow). - It could be interesting to implement the alternative approach - were the class only looks its own operations and then tries - the parent. This will reduce code size, but will probably - decrease performance. - </LI> - - <LI>Cleanup memory managment in some of the servers, for - instance: Naming still believes that controlling the memory - for a stub will control the servants, this is not true - anymore. - </LI> - - <LI>The current scheme for the orbsvcs leaves the user without - control collocation of servants, we need to move to a scheme - similar to the one in $ACE_ROOT/netsvcs. - <BR>[STATUS] The user can control collocation, but we need a - dynamic way to do it (or an example) that exploits the Service - Configurator. We also may need to split the library. - </LI> - - <LI>Cleanup the IDL structures for subscriptions, publications, - etc. (in the EC). - </LI> - - <LI>Resolve the Typecode::equal dilemma: is it structural or - type equivalence? Or a mixin? - </LI> - - <LI>Automate EC multicast group usage. This probably requires - some kind of server that mantains the realtion between event - type/source and the mcast groups. - </LI> - - <LI>Improve configuration support in the EC, give an example of - a single threaded EC, support different dispatching - strategies, etc. - </LI> - - <LI>Use the Service_Configurator to dynamically load the EC - Module_Factory thus making it really configurable. - </LI> - - <LI>The current scheme for Typecode (keeping a CDR buffer with - their representation) is broken. - </LI> - - <LI>We must support DynAny. - </LI> - - <LI>We must support a IFR. - </LI> - - <LI>Server_Request objects in TAO are magical, the _duplicate() - method returns 0 and release() does nothing. - The problem starts because Server_Request is allocated from the - stack (to speed up things), hence reference counting would be - useless. Adding a clone() method will work better, but the - Server_Request holds pointers to several positions in the CDR - stream, we could clone the CDR stream, but a normal - Server_Request does not own it.... In our opinion (Carlos and - Irfan) we need not worry about this until we find a use case for - it. - </LI> - - <LI> - The current implementation is optimal for hard-real-time - applications, but in some cases it may be desirable to follow - the normal execution path yet minize costs for collocated - calls. - An example would include an application that activates the - objects on demand. - It would be interesting to have a half-collocated stub - implementation, that will marshall the request and then - invokes the normal path on the "server" side, but without - crossing the kernel boundary. Ideally even the serialization - could be minimized or avoided. - </LI> - </UL> - - <CENTER> - <H4>Completed Tasks</H4> - </CENTER> - - <UL> - <LI>Optimize connection lookup in the client side, using "hints" - from the previous lookup, or keeping smaller sets on each IIOP - profile or a combination of both. - <BR>[STATUS] Irfan is working on - this. - <BR>[DONE] - </LI> - - <LI>Optimize the outgoing CDR streams by using TSS memory pools - for both the data blocks and the buffers. - <BR>[DONE] But we may consider strategizing the kind of allocator - we use (like using a free list instead of a generic - ACE_Malloc). - </LI> - - <LI>Optimize Octet Sequences. - <BR>[DONE] - </LI> - - <LI>Obtain results for the EC_Multiple test. - <UL> - <LI>Latency seems OK. - </LI> - <LI> Overhead: need lower priority for scavenger thread. - </LI> - </UL> - </LI> - - <LI>Debug EC_Multiple. - </LI> - - <LI>Your next assignment: Regenerate all methods in - _tao_collocated to avoid "inherit via dominance" warnings. - <BR>[STATUS] The IDL compiler was modified to generate a - suitable - <CODE>#pragma</CODE> that removes the warning, it reenables - the warning when leaving the file - </LI> - - <LI>Remove the SOLARIS2 macro from the TAO_IDL compilation. - <BR>[DONE] - </LI> - - <LI>Remove the preemption_prio message from Scheduling_Service. - </LI> - - <LI>The ORB core should be able to choose the right port for us - (in other words -ORBport 0) should work. - <BR>[DONE] - </LI> - - <LI>Client side optimization for Octet Sequences. - <BR>[DONE] - </LI> - - <LI>Minimize memory allocation in TAO - <BR>[STATUS] Down to 3 on the client side and 4 on the server - side. - <BR>[STATUS] For oneways it is down to 0 (for the common case) - on the client side and 2 on the server side. For twoways it is - 2 on both sides. - </LI> - - <LI>Automate subscription and publication list generation in the - EC_Gateway. - [VERY important for Boeing] - <BR>[STATUS] Completed and debugged, but the EC is still - buggy. - </LI> - - <LI>Debug EC shutdown and startup.... - [Specially startup for Boeign, but shutdown is important for - Purify and Quantify] - <BR>[STATUS] Shutdown is clean and startup of threads can be - controlled by the user. - </LI> - - <LI>Support a chain of Message Blocks in Output CDRs and use - writev() to write them. - <BR>[DONE] - </LI> - - <LI>Memory managment in the demarshalling engine, it is not - clear that the current scheme works in all cases (like - sequences of unions of anys). - We also need to fix sequences of object references: how does - the demarshalling engine learn about the dynamic type of the - objects? - Closely related to this is the problem of memory alignment for - different architectures, we need to develop strategies for each - one (they should only be a few) and choose the right one. - <BR>[STATUS] This seems to be working for most of the cases, the - main idea is to delay demarshalling until enough information - is available, for instance, when decoding an Any just a - reference to the CDR stream is stored, decoding actually - happens when the user invokes >>= on the any (at that point - all the info is there). - </LI> - - <LI>Add a new Profile type that includes the QoS info and using - for end-to-end QoS preservation. - [DEPRECATED] The IIOP 1.1 Profiles can handle that. - </LI> - - <LI>Show an example of the sequence<octet> and CDR streams. - <BR>[DONE] But the example could also include the marshalling of - plain C++ types. - <BR>[DONE too] - </LI> - - <LI>Test anys in the EC. - <BR>[DONE] Michael reported that they work OK on NT. - </LI> - - <LI>UDP for event channel and Multicast support in the EC. - <BR>[STATUS] Manual configuration using Suppliers and Consumers is - possible, automation is under research. - </LI> - - <LI>Unbind the EC and scheduling service from the Naming - Service. - <BR>[DONE] For the Event_Service and the examples. - </LI> - - <LI>Optimize oneways by not allocating the memory for the return - buffers. - <BR>[DONE] Added different Invocation classes for each case. - </LI> - - <LI>Fix the _non_existent call. - <BR>[DONE] The client side semantics match the new clarifications - of the C++ RTF, the server side is implemented by the IDL - compiler, though t could be a good idea to put that in the - POA. - </LI> - - <LI>Simplify EC configuration, a Factory class must provide the - Dispatching, Supplier, Correlation and any other Modules that - are required. - This is the right spot to add trivial Dispatching or - Correlation Modules and to dynamically load and configure the - EC. - <BR>[DONE] A Factory class is used to create the modules, only the - default factory is implemented so far. - </LI> - - <LI>Fix the ACE_Thread_Condition madness. - <BR>[DONE] We changed ACE so ACE_SYNCH_CONDITION expands to - ACE_Condition_Thread_Mutex - </LI> - - <LI>Reference counting should have locks, but we should remove - all the QueryInterface madness to make that work. The policy - for references in multiple threads is: the reference count - must be >2 if that happens. - <BR>[STATUS] The QueryInterface method (all the COM stuff for that - matter) was removed... - <BR>[DONE] - </LI> - - <LI>Reference counting for Typecodes is completely broken. - <BR>[DONE] - </LI> - - <LI>Under g++(2.7.2) the use of multiple inheritance in IDL - triggers some compiler bug, if the IDL explictly generated the - copy constructor for the skeletons (the POA_ classes) the - problem would go away. - <BR>[DONE] Fixed, Seth is testing the fixes and will commit them - soon (Tue Jul 21 14:24:56 CDT 1998) - </LI> - - <LI>The octet sequence optimization causes problems when Anys - get into the game. - <BR>[DONE] Seth reported that the problem was not real. - </LI> - - <LI>The DEEP_FREE method is also broken, sometimes we need to - release the top-level memory, sometimes not. - <BR>[DONE] We always release the memory in the Any, it was failing - due to weird interactions between the Environment containing - an exception and the Any that also did. - </LI> - - <LI>Improve error messages in the IDL compiler. - <BR>[DONE] At least the filename is correct now. - </LI> - - <LI>Support for arrays in the IDL compiler is incomplete, - specially anonymous arrays. - <BR>[DONE] According to Andy this is properly supported by the IDL - compiler now. - </LI> - - <LI>Prepare the 0.2 release: - <UL> - <LI>Execute all the tests in $TAO_ROOT/tests - </LI> - <LI>Run Param_Test (SII) and record what fails and what works. - </LI> - <LI>Run Param_test (DII) and record what fails and what works. - </LI> - <LI>Run Param_Test across Endian Borders. - </LI> - </UL> - <BR>[DONE] At last! - </LI> - - <LI>Move this list to the release notes. - </LI> - </UL> - -<HR> - -<P>Back to the TAO <A HREF="../index.html">documentation index</A>. <!--#include virtual="/~schmidt/cgi-sig.html" --> -</BODY> -</HTML> diff --git a/TAO/docs/releasenotes/ec.html b/TAO/docs/releasenotes/ec.html deleted file mode 100644 index 6f84f2ec177..00000000000 --- a/TAO/docs/releasenotes/ec.html +++ /dev/null @@ -1,234 +0,0 @@ -<!-- $Id$ --> - -<HTML> - <HEAD> - <TITLE>Event Service Status</TITLE> - </HEAD> - -<BODY TEXT="#000000" BGCOLOR="#FFFFFF"> - <BODY> - <H3>Event Service Status</H3> - Point of contact: <A HREF="mailto:coryan@cs.wustl.edu">Carlos O'Ryan</A> - - <H4>Last Updated: $Date$ </H4> - - <H3>New on this release</H3> - - <UL> - <LI> - Added a prototype Consumer and Supplier that can send events - though multicast groups (or regular UDP sockets). - </LI> - <LI> - The Event Channel can be configured using a Factory that - constructs the right modules (like changing the dispatching - module), - in the current release only the default Factory is - implemented. - </LI> - </UL> - - <H3>Known issues:</H3> - <DL> - <DT><EM>The schedule cannot be downloaded</EM></DT> - <DD> - The Scheduling Service seems to compute proper schedules, - but it is not possible to download them, - apparently there is a marshalling problem for sequences of - complex structures. - - <P>Due to this problem we have been unable to test the - run-time scheduler and performance it is impossible to - complete performance measurements and optimizations: - the (global) scheduling service latency and overhead is at - least as large as the EC itself.</P> - </DD> - - <DT><EM>Run-time scheduler requires re-link</EM></DT> - <DD> - During a normal execution of the system - there is no - need to use the a global Real-time Scheduling Service, - a faster, - collocated implementation for the service is available. - Obviously the scheduling information is precomputed in some - config run. - - <P>Unfortunately the current scheme requires a relink of all the - involved applications against the generated tables for the - run-time scheduling service.</P> - - <P>We should be able to download the schedule to the interested - parties, - without need for a separate link phase. - This will simplify and speed up the developing cycle, - but requires a (small and fixed) amount of dynamic memory - allocation. - It could be interesting to "save" the schedule computation in - some persistent form, - so startup cost are lower too.</P> - - <P>The current design contemplates a config run were a global - consumer accumulates the QoS requirements of all the objects, - next an external utility is used to force a computation and - save of the schedule. - In future executions - the global scheduler pre-loads this schedule and - the clients simply download the precomputed schedule, - and all scheduling queries are to a local scheduling service, - without any further contact to the global instance.</P> - </DD> - - <DT><EM>Users have no control over service - collocations</EM></DT> - <DD> - The user should have complete control of services collocation, - using ACE Service Configurator; - currently the services must be explicitly instantiated by the - user. - </DD> - - </DL> - - <H3>Examples</H3> - - <P>For general documentation on the Event Service please read - <A HREF="http://www.cs.wustl.edu/~schmidt/oopsla.ps.gz"> - The Design and Performance of a Real-time CORBA Event - Service</A>. - - <P>The simplest test for the Event Channel is - <CODE>Event_Latency</CODE>, - below are the basic instructions to run it:</P> - - <OL> - <LI> Compile everything under <CODE>$TAO_ROOT/orbsvcs</CODE>, this - needs, obviously, <CODE>$TAO_ROOT/tao</CODE> and - the IDL compiler in <CODE>$TAO_ROOT/TAO_IDL</CODE>.</LI> - - <LI><P>Run the naming service, the scheduling service, the event service - and the test in - <CODE>$TAO_ROOT/TAO/orbsvcs/tests/Event_Latency</CODE>; - remember to give a different port to each one, - using the <CODE>-ORBport</CODE> option. As in:</P> - - <CODE> - <P> - $ cd $TAO_ROOT/orbsvcs - </P> - <P> -$ cd Naming_Service ; ./Naming_Service -ORBport 10000 & - </P> - <P> -$ cd Event_Service ; ./Event_Service -ORBport 0 & - </P> - <P> -$ cd tests/Event_Latency ; ./Event_Latency -ORBport 0 -m 20 -j & - </P> - </CODE> - - <P> - You may want to run each program in a separate window. - Try using a fixed port number for the <CODE>Naming - Service</CODE> so you can use the <CODE>NameService</CODE> - environment variable. - </P> - - <P> - The script <CODE>start_services</CODE> - in <CODE>$TAO_ROOT/orbsvcs/tests</CODE> can help with - this. - </P> - - </LI> - - <LI> If you want real-time behavior on Solaris you may need to run - these programs as root; on the other hand, this particular - example really has no priority inversion, since only one - thread runs at a time.</LI> - </OL> - - <P>Another example is <CODE>EC_Multiple</CODE>, - numerous examples on how to run this test can be found in the - scripts located in - <CODE>$TAO_ROOT/orbsvcs/tests/EC_Multiple</CODE>.</P> - - <H3>Features in previous releases</H3> - - <UL> - <LI> - <P> - When several suppliers are consumers are distributed over the - network it could be nice to exploit locality and have a - separate Event Channel on each process (or host). - Only when an event is required by some remote consumer we need - to send it through the network. </P> - - <P> - The basic architecture to achieve this seems very simple, - each Event Channel has a proxy that connects to the EC peers, - providing a "merge" of its (local) consumer subscriptions as - its own subscription list. </P> - - <P> - Locally the proxy connects as a supplier, - publishing all the events it has register for. </P> - - <P> - To avoid event looping the events carry a time-to-live field - that is decremented each time the event goes through a proxy, - when the TTL gets to zero the event is not propagated by the - proxy. </P> - - <P> - In the current release an experimental implementation is - provided, - it basically hardcodes all the subscriptions and publications, - we are researching on how to automatically build the - publication list.</P> - </LI> - - <LI> <P> - We use the COS Time Service types (not the services) to - specify time for the Event Service and Scheduling Service.</P> - </LI> - - <LI>The <CODE>Gateway</CODE> to connect two event channels was - moved from a test to the library. - The corresponding test (<CODE>EC_Multiple</CODE>) has been - expanded and improved.</LI> - - <LI> - The user can register a set of <CODE>EC_Gateways</CODE> with - the <CODE>EventChannel</CODE> implementation, the event - channel will automatically update the subscription list as - consumers subscribe to the EC. - </LI> - <LI> - The code for consumer and supplier disconnection was - improved and seems to work without problems now - </LI> - <LI> - The <CODE>Event_Service</CODE> program creates a collocated - <CODE>Scheduling Service</CODE> this works around a problem - in the ORB when running on multiprocessor. - </LI> - <LI> - Startup and shutdown were revised, the event channel - shutdown cleanly now. - </LI> - <LI> - Added yet another example - (<CODE>$TAO_ROOT/orbsvcs/tests/EC_Throughput</CODE>), this - one ilustrate how to use the - TAO extensions to create octet sequences based on CDR - streams, without incurring in extra copies. - This is useful to implement custom marshalling or late - dermashalling of the event payload. - Future versions of the test will help measuring the EC - throughput, hence the name. - </LI> - </UL> - - </BODY> -</HTML> diff --git a/TAO/docs/releasenotes/index.html b/TAO/docs/releasenotes/index.html deleted file mode 100644 index e103be67a88..00000000000 --- a/TAO/docs/releasenotes/index.html +++ /dev/null @@ -1,786 +0,0 @@ -<HTML> -<HEAD> - <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"> - <META NAME="GENERATOR" CONTENT="Mozilla/4.04 [en] (X11; I; SunOS 5.5.1 sun4u) [Netscape]"> - <TITLE>TAO Release Information and TODO List</TITLE> -</HEAD> -<BODY TEXT="#000000" BGCOLOR="#FFFFFF"> -<!-- $Id$ --> -<CENTER> -<HR></CENTER> - -<CENTER> -<H3> -Release Information for The ACE ORB (TAO)</H3></CENTER> -Information is available on the following topics related to the <A HREF="http://www.cs.wustl.edu/~schmidt/ACE_wrappers/TAO/VERSION">current -release</A> of <A HREF="http://www.cs.wustl.edu/~schmidt/TAO.html">TAO</A>: -<UL> -<LI> -<A HREF="orbcore.html">ORB Core</A></LI> - -<LI> -<A HREF="#idl">IDL Compiler</A></LI> - -<LI> -<A HREF="#poa">Portable Object Adapter</A></LI> - -<LI> -<A HREF="#nservices">CORBA Naming Service</A></LI> - -<LI> -<A HREF="ec.html">CORBA Event Service</A></LI> - -<LI> -<A HREF="#tservices">CORBA Trading Service</A></LI> - -<LI> -<A HREF="#pservices">CORBA Property Service</A></LI> - -<LI> -<A HREF="#cservices">CORBA Concurrency Control Service</A></LI> - -<LI> -<A HREF="#logging">CORBA Logging Service</A></LI> - -<LI> -<A HREF="#implrepo">Implementation Repository</A></LI> - -<LI> -<A HREF="#av">CORBA Audio/Video Control Service</A></LI> - -<LI> -<A HREF="#apps">Test & Example Applications</A></LI> - -<LI> -<A HREF="#ace">ORB-related ACE Changes</A></LI> - -<LI> -<A HREF="#dove">The DOVE Demo</A></LI> - -<LI> -<A HREF="#forwarding">Location forwarding</A></LI> - -<LI> -<A HREF="#leader">Global resources and leader-follower model</A></LI> - -<LI> -<A HREF="#locate">Locate requests</A></LI> -<LI> - -<A HREF="TODO.html">Our TODO list</A></LI> -</UL> - -A complete list of all modifications to TAO is available in the <A HREF="http://www.cs.wustl.edu/~schmidt/ACE_wrappers/TAO/ChangeLog">ChangeLog</A>. - -<P> -<HR><!--#include virtual="orbcore.html" --> -<HR> -<H3> -<A NAME="idl"></A>IDL Compiler</H3> -Point of contact: <A HREF="mailto:gokhale@cs.wustl.edu">Aniruddha Gokhale</A> - -<P>Current status: (As of July 31st, 1998.) -<UL> -<LI> -Anonymous arrays inside structs are supported. However, they are not yet -supported inside unions.</LI> - -<LI> -Perfect Hashed Operation Lookup Strategy has been added to the IDL Compiler. --P flag to the <tao_idl>enables the perfect hased lookup strategy. -This strategy uses <A HREF="http://www.cs.wustl.edu/~schmidt/gperf.ps.gz">GPERF</A>, -the GNU's Perfect Hash Function Generator written by Dr.Douglas C. Schmidt. -Right now, GPERF works only on Solaris. Any work on porting GPERF to other -platforms will be highly appreciated. </L1></LI> - -<LI> -Support for Arrays is refined in terms of the code generated for parameters -inside stubs and skeletons.</LI> - -<LI> -Significantly improved the support for unions. The default case is yet -to be handled.</LI> - -<LI> -Added support for Arrays. Right now, support for typedefed arrays is in. -Still needs testing.</LI> - -<LI> -Added support for TIE classes. If the interfaces are defined inside modules, -then the TIE class and its code gets generated inside a conditional macro. -For platforms that support namespaces, this macro will allow these TIE -classes else they get commented out. The reason to do this is because nested -templates have problems on most compilers.</LI> - -<LI> -The <<= and >>= operators for user-defined types are now generated.</LI> - -<LI> -Completely redesigned the IDL compiler using the Visitor patterns. Many -incomplete issues have been resolved. These include support for "sequence -of typecodes", passing object references as in, inout, and out parameters. -Code generation for sequences is also properly handled i.e., for a named -sequence such as "typedef sequence <char>CharSeq;", we now generate -a new class (and hence a type) called "class CharSeq". Arrays are still -being worked out and will be done soon. An important difference in the -generated code is that the skeletons now use a table driven approach very -similar to the stubs.</LI> - -<LI> -Support for the "native" keyword added.</LI> - -<LI> -Introduced tests for object references to TAO. Still incomplete.</LI> - -<LI> -Param_Test example is able to test string sequences, fixed structs, variable -sized structs and nested structs</LI> - -<LI> -Param_Test test suite can now test fixed structs and string sequences.This -needed bug fixes to TAO ORB core.</LI> - -<LI> -A new test to test all the parameter passing modes for a number of data -types has been added. At this point in time, it tests primitive types and -strings. Other tests will be added. Bugs discovered thru these tests have -been fixed.</LI> - -<LI> -Very preliminary support for arrays. Not working yet.</LI> - -<LI> -Many bugs associated with stub generation fixed. This included support -for return values that are variable sized IDL types. Unions improved.</LI> - -<LI> -Support for sequences of strings and object references added. However, -it is not tested yet so there may be some bugs. We should have these fixed -in a day or so.</LI> - -<LI> -Support for handling exceptions added. TAO does not use direct C++ exceptions. -Instead it uses the CORBA::Environment based approach.</LI> - -<LI> -Sequences as out parameters have been tested in the IDL_Cubit example. -A test suite is currently being built to test all the parameter passing -modes on a variety of IDL data types.</LI> - -<LI> -Support for attributes completed. Not tested yet.</LI> - -<LI> -The problem of incorrect code generation for typedefs defined in an imported -file is resolved.</LI> - -<LI> -Problems when interfaces use single or multiple inheritance solved. The -problem was with the demultiplexing code, the generated operation tables, -and the dispatching mechanism. We are currently testing this with the Event -Channel code.</LI> - -<LI> -The problems arising due to public virtual inheritance when casting from -an interface class to CORBA::Object_ptr has been solved. We do this casting -inside the stubs/skeletons rather than first converting an interface class -pointer to a void*, storing it in an Any, and casting it to CORBA::Object_ptr -in the encode/decode methods. The casting inside the stubs/skeletons work -because the compiler has knowledge of both types.</LI> - -<LI> -The compiler generates correct code for COSS Naming service and it runs -properly. Correct code also gets generated for the Event Channel program</LI> - -<LI> -Include files are handled properly. So are the definitions used inside -the include files that are used in the currently parsed files.</LI> - -<LI> -IN, INOUT, and OUT object reference parameters are now supported properly. -We think the same approach should work for sequences, structs, and unions.</LI> - -<LI> -Many IDL constructs supported including primitive types, typedefs, sequences, -structures, and unions.</LI> - -<LI> -Generates C++ stubs and skeletons that use TAO's <A HREF="http://www.cs.wustl.edu/~schmidt/HICSS-97.ps.gz">interpretive -IIOP protocol engine</A>.</LI> - -<LI> -Generated code closely follows the C++ Mapping specified in the POA Specification -(ORBOS/97-05-15).</LI> - -<LI> -Support dynamic libraries on NT, i.e., marking classes for DLL export was -added. Two backend options control the name of the export macro, and the -name of an extra include file were the macro is defined; the options are -<TT>-Wp,export_macro=MACRO_NAME</TT> <TT>-Wp,export_include=INCLUDE_NAME</TT>.</LI> - -<LI> -The IDL compiler generates now source code for sequences. The user has -now the option to use these generated sequence classes or to use, as up -to now, the template instatiation. If TAO_LACKS_TEMPLATE_SPECIALIZATION -is defined, then template instantiation will be used, else not. The reason -for this was, that some C++ compilers did not support template instantiation -properly and sequences were based on templates. The generated source code -is mainly contained in the generated header file directly in the class -declaration.</LI> -</UL> -Known bugs/unimplemented constructs: -<UL> -<LI> -Generation of Managed types must somehow be moved to the ORB Core</LI> - -<LI> -We need support for ``TIEs'' (i.e., the object form of the Adapter pattern).</LI> - -<LI> -TypeCode generation for multidimensional arrays and indirected typecodes -is still a problem.</LI> - -<LI> -Unions with default cases yet to be handled</LI> - -<LI> -Deal with names in the IDL definition that are C++ keywords.</LI> - -<LI> -IDL is case-insensitive. However, it looks like our front-end is case-sensitive. -Thanks to Anil Gopinath (anil@ittc.ukans.edu) for pointing this out.</LI> - -<LI> -tao_idl generates code for a *.idl file only inside the directory where -the *.idl resides. However, it may be required to generate code elsewhere -i.e., in the directory where the compiler was invoked. Thanks to Tom Richards -(tomr@MCMEnterprise.com) for this suggestion.</LI> -</UL> -Future work: -<UL> -<LI> -Need to relocate the various libraries used by the IDL compiler out of -the ACE directory. Having them here can cause problems when working with -multiple versions of TAO and a single version of ACE.</LI> - -<LI> -Improve IDL compiler to generate compiled form of stubs/skeletons.</LI> - -<LI> -Fix bugs in the SunSoft IDL front-end we've uncovered. These primarily -include support for Unions.</LI> - -<LI> -Add command line options to TAO IDL. These options will decide what strategy -to use for operation name demultiplexing. Another option may decide whether -to use the interpretive IIOP engine or generate compiled stubs/skeletons.</LI> - -<LI> -Use <A HREF="http://www.cs.utah.edu/projects/flux/flick/">Flick</A> (from -the University of Utah) to generate compiled stubs.</LI> - - -<P>Goal is to measure the code size of the interpretive stubs generated -by TAO IDL compiler <I>vs</I> code size of compiled stubs. Then compare -the performance of each. We want to prove the thesis that TAO IDL compiler -generated interpretive stubs have a small code size, yet are comparable -in performance (or slightly less) than compiled stubs. Hence, it will be -useful for small distributed equipment such as handsets, PDAs, etc. - -<P>In doing the above, improvements to the IIOP protocol engine in terms -of size/performance/determinism will be made. -<LI> -Tweak the IDL compiler to generate code that's more easily integrated back -into the ORB Core, e.g., POA, etc. This will depend largely on our ability -to generalize the changes necessary to generated code.</LI> -</UL> - -<LI> -The generated sequence classes should not be generated per sequence, but -per type and parent scope. Which means, that the overhead of having the -source code generated serveral times should be reduced. To do this, an -extra pass over the internal representation of the IDL file has to be done. -<HR></LI> - -<H3> -<A NAME="poa"></A>Portable Object Adapter</H3> -Point of contact: <A HREF="mailto:irfan@cs.wustl.edu">Irfan Pyarali</A> - -<P>Current Status: -<UL> -<LI> -TAO fully supports the POA spec. This section will carry updates as available.</LI> -</UL> -Known issues: -<DL> -<DT> -<I>Support for collocation is not complete.</I></DT> - -<DD> -If an object which should be collocated is created via <TT>string_to_object</TT>, -it is created as a remote object rather than collocated.</DD> -</DL> -Critical work: -<UL> -<LI> -None.</LI> -</UL> -Future work: -<UL> -<LI> -Determine the degree to which we will support the full semantics of remote -objects on a collocated object. The spec mandates that collocated object -should behave <I>exactly</I> like remote objects, but that means that request -will have to be queued rather than calling a method directly, and this -could be hazardous to our quest for real-time ORB status.</LI> - -<LI> -Provide extensions of the specification to ensure real-time delivery of -messages.</LI> -</UL> - -<HR><!--#include virtual="ec.html" --> -<HR> -<H3> -<A NAME="nservices"></A>CORBA Naming Service</H3> -Point of contact: <A HREF="mailto:sergio@cs.wustl.edu">Sergio Flores-Gaitan</A> -and <A HREF="mailto:marina@cs.wustl.edu">Marina Spivak</A> - -<P>Current status (as of Feb 27th): -<UL> -<LI> -The Naming Service implementation is complete.</LI> -</UL> -Future work: -<UL> -<LI> -Currently the bindings are stored as a table in memory. Future work will -include a persistent database to store the bindings.</LI> - -<LI> -Replication of the bindings to other Naming Service's currently running. -It will probably be modeled after the LDAP Multi-Master Replication Protocol. -For more information on this replication protocol please read <A HREF="ftp://ds.internic.net/internet-drafts/draft-ietf-asid-ldap-mult-mast-rep-02.txt">LDAP -Multi-Master Replication Protocol</A></LI> -</UL> -For general documentation on the Naming Service please read <A HREF="ftp://www.omg.org/pub/docs/formal/97-07-12.pdf">The -Naming Service Specification</A>. - -<P> -<HR> -<H3> -<A NAME="tservices"></A>CORBA Trading Service</H3> -Point of contact: <A HREF="mailto:sbw1@cs.wustl.edu">Seth Widoff</A> - -<P>The TAO Trading Service is a transient implementation of the COS Trading -Service speficiation that meets the Linked Trader conformance criteria ---- it implements the <TT>Lookup</TT>, <TT>Register</TT>, <TT>Admin</TT>, -and <TT>Link</TT> interfaces, but not the <TT>Proxy</TT> interface. Notably, -the TAO trader supports the following features: -<UL> -<LI> -Multithreaded operation;</LI> - -<LI> -Trader federations and distributed queries;</LI> - -<LI> -Dynamic properties;</LI> - -<LI> -Modifiable properties;</LI> - -<LI> -All policies described in the specification;</LI> - -<LI> -Preference sorting;</LI> - -<LI> -Service type inheritance hierarchies and subtype searching.</LI> -</UL> -<A HREF="trader.html">Trading Service documentation</A> is also available. - -<P>Future Work: -<UL> -<LI> -The Proxy Interface.</LI> - -<LI> -Persistent storage of service types and offers.</LI> -</UL> -For general documentation of the Trading Service, please read <A HREF="http://www.omg.org/corba/sectrans.htm#trader">The -Trading Service Specification.</A> - -<P> -<HR> -<H3> -<A NAME="pservices"></A>CORBA Property Service</H3> -Point of contact: <A HREF="mailto:alex@cs.wustl.edu">Alexander Babu Arulanthu</A> - -<P>Current status (as of May 02, 1998) -<BR> -<BR>All the interfaces of this service have been implemented. Please -go through the test examples at $TAO/orbsvcs/tests/CosPropertyService. -Property Service is now used by the AVStreams that is currently being -developed for TAO. More testing is being done. - -<P>For general documentation of the Property Service, please read <A HREF="http://www.omg.org/corba/sectrans.htm#prop">The -Property Service Specification.</A> - -<P> -<HR> -<H3> -<A NAME="implrepo"></A>Implementation Repository</H3> -Point of contact: <A HREF="mailto:brunsch@cs.wustl.edu">Darrell Brunsch</A> - -<P>Current status (as of July 23, 1998) - -<P>Here is a brief list of my goals (and the dates completed). For more -information, please see the <A HREF="../implrepo.html">Implementation Repository -documentation</A>. -<UL> -<LI> -Create the base test client and server programs [7/17]</LI> - -<LI> -Add an IR that forwards server requests [7/23]</LI> - -<LI> -Have the server register its IOR with the IR</LI> - -<LI> -Have the server exit after every call, so it is restarted each time</LI> - -<LI> -Add the ping object to the server</LI> - -<LI> -Add in shutdown calls to test ping objects</LI> - -<LI> -Change IOR format</LI> - -<LI> -Add in support for server names</LI> - -<LI> -Make the IR forward any request</LI> - -<LI> -Add another server</LI> -</UL> -Other goals: -<UL> -<LI> -Implement the IDL Interface for the IR</LI> - -<LI> -Move this stuff into the POA</LI> - -<LI> -Multiple Profiles</LI> - -<LI> -POA extension</LI> - -<LI> -Persistence</LI> -</UL> -Future Goals: -<UL> -<LI> -TAO client-side optimization with restarted servers</LI> - -<LI> -Server security (checksums)</LI> - -<LI> -Helper Application</LI> - -<LI> -Federation of IRs</LI> - -<LI> -DLLs</LI> -</UL> - -<HR> -<H3> -<A NAME="cservices"></A>CORBA Concurrency Control Service</H3> -Point of contact: <A HREF="mailto:tworm@cs.wustl.edu">Torben Worm</A> - -<P>Current status (as of May 3rd): -<UL> -<LI> -A simple version of the concurrency service has been implemented, i.e. -a version without transactions. It is currently being tested.</LI> -</UL> -Future Work: -<UL> -<LI> -Implementation of the Concurrency Control Service with transactions</LI> -</UL> -For general documentation of the Concurrency Control Service, please read -<A HREF="http://www.omg.org/corba/sectrans.htm#concur">The Concurrency -Control Service Specification.</A> - -<P> -<HR> -<H3> -<A NAME="logging"></A>CORBA Logging Service</H3> -Point of contact: <A HREF="mailto:mjb2@cs.wustl.edu">Matt Braun</A> - -<P>Current status (as of August 4'th): -<UL> -<LI> -The basic logging service has been implemented. It can log basic messages -from multiple clients. It is currently in the testing stage.</LI> -</UL> -Future work: -<UL> -<LI> - Add increased functionality. Requests and suggestions are welcome.</LI> -</UL> - -<HR WIDTH="100%"> -<H3> -<A NAME="av"></A>CORBA Audio/Video Control Service</H3> -Point of contact: <A HREF="mailto:sumedh@cs.wustl.edu">Sumedh Mungee</A> -and <A HREF="mailto:naga@cs.wustl.edu">Nagarajan Surendran</A> - -<P>This is an implementation of the OMG spec addressing the <A HREF="http://www.cs.wustl.edu/~sumedh/research/corbaav.pdf">Control -and Management of Audio/Video Streams</A>. - -<P>The audio/video streaming service has been implemented in the light -profile. An MPEG-1 application which streams mpeg-1 video and mpeg-1 audio -separately has been developed using the service. This application currently -works only for Unix platforms. - -<P>Current Status: -<UL> -<LI> -Implemented the handshake mechanism between the consumer and supplier of -the stream.</LI> - -<LI> -Implemented a simple version of the stream controller (StreamCtrl).</LI> - -<LI> -Implemented the VDev and StreamEndPoint base class functionality.</LI> - -<LI> -Implemented the MMDevice interface, which is a factory for StreamEndPoint -and VDev objects.</LI> - -<LI> -Implemented a mpeg-1 streaming audio/video application using the a/v service.</LI> -</UL> -Work in progress: -<UL> -<LI> -Implementing the SFP protocol</LI> - -<LI> -Integrating the mpeg-1 streaming application with the trading service.</LI> -</UL> - -<HR> -<H3> -<A NAME="apps"></A>Test & Example Applications</H3> -Point of contact: <A HREF="mailto:naga@cs.wustl.edu">Nagarajan Surendran</A> - -<P>Current Status: - -<P>The TAO IDL_Cubit test application makes use of the Naming Service and -the server holds a TAO_Naming_Server component.Just running server and -client is enough to test the application. - -<P>The various tests in the tests/POA test the different features of the -Portable Object Adapter interface like Explicit Activation, On Demand Activation,etc.. - -<P>Future work: - -<P>Developing a one-buttoned test for all the different TAO tests similar -to the ACE-one buttoned test. - -<P>MT_Cubit: - -<P>Current status: - -<P>The TAO MT_Cubit test application is meant to serve as a starting point -for real-time tests on the TAO system. It comprises the following parts: -<UL> -<LI> -<I>Server.</I> The server creates multiple CORBA objects (servants), each -with different real-time priorities. This priority is implemented by using -real-time thread support provided by the operating system. Thus, requests -sent to a high-priority servant are handled by a high-priority real-time -thread, and those sent to a lower priority servant are handled by correspondingly -lower priority threads.</LI> - -<LI> -<I>Client.</I> The client component binds to the servants, and sends a -stream of CORBA requests to the servants. It measures the response time, -i.e. the time taken for the request to complete successfully. In particular, -it measures the time taken for requests sent to the high priority servant -to complete. The volume of lower priority requests is configurable. The -client is thus able to measure the performance of the high-priority servant -in the presence of competition from several lower-priority servants.</LI> -</UL> -Clearly, if the ORB endsystem handles the priorities of the various requests -correctly, increasing the volume of lower priority requests should not -affect the performance seen by the higher priority requests. The application -thus serves as a tool to measure and confirm this behavior. - -<P>Future work: -<UL> -<LI> -Study the impacts of scheduling & concurrency strategies on performance.</LI> - -<LI> -Evolve into a testbed for discovering sources of performance non-determinism -& priority inversion.</LI> -</UL> - -<HR> -<H3> -<A NAME="ace"></A>ORB-related ACE Changes</H3> -Points of contact: <A HREF="mailto:nanbor@cs.wustl.edu">Nanbor Wang</A> -and <A HREF="mailto:irfan@cs.wustl.edu">Irfan Pyrarli</A> - -<P>Recently Completed Work: -<UL> -<LI> -Added special declaration to OS.h for <TT>inet_ntoa</TT> and other functions -because VxWorks doesn't provide full argument prototypes for these library -functions.</LI> - -<LI> -The current caching connector behaves properly in the face of a non-blocking -connect request. The "fix" is simply to not support non-blocking connects -through the cache. When the <TT>connect()</TT> fails with <TT>EWOULDBLOCK</TT>, -morph the error to -1 and clean up the request.</LI> - -<LI> -Service handlers obtained from the caching connector are now cleaned up. -The application needs to be able to signal that it's not using it any longer, -and, when the application encounters an error, needs to effectively close -down that connection for good so that a new connection can be initiated.</LI> - -<BR>Added the ability for a Svc_Handler to recycle itself. idle() can be -called when the Svc_Handler is done serving a particular connection and -can how be recycled. The Svc_Handler now also has a pointer to a recycler -that is responsible for managing the connections. The recycler is usually -a Cached_Connector. -<BR>Added new class ACE_Recycling_Strategy. It defines the interface (and -default implementation) for specifying a recycling strategy for a Svc_Handler. -This strategy acts as a consular to the Svc_Handler, preparing it for the -tough times ahead when the Svc_Handler will be recycled. -<BR>Added new class ACE_NOOP_Concurrency_Strategy. It implements a no-op -activation strategy in order to avoid calling open on a recycled svc_handler -multiple times. -<BR>ACE_Cached_Connect_Strategy now implements the ACE_Connection_Recycling_Strategy -interface. This allows Svc_Handlers to cache themselves with ACE_Cached_Connect_Strategy -when they become idle. It also allows them to purge themselves from the -connection cache when the Svc_Handlers close down. -<BR>Also added ~ACE_Cached_Connect_Strategy that will cleanup up the connection -cache.</UL> -Future work: -<BLOCKQUOTE><I>None currently scheduled.</I></BLOCKQUOTE> - -<HR> -<H3> -<A NAME="dove"></A>The DOVE Demo</H3> -Point of contact: <A HREF="mailto:mk1@cec.wustl.edu">Michael Kircher</A>. - -<P><A HREF="http://www.cs.wustl.edu/~schmidt/dove.html">DOVE</A> is -documented in detail <A -HREF="http://www.cs.wustl.edu/~schmidt/DOVE_and_LifeCycleService.ps.gz">online</A>. -This discussion focuses on the following goals:<P> - -<UL> -<LI> -Have a DOVE Browser running using Java Beans as vizualization components.</LI> - -<LI> -Have the Event Channel as DOVE Agent running with an Event Consumer in -the DOVE Browser.</LI> - -<LI> -Having a DOVE Management Information Base (MIB), which dumps all events -transfered on the Event Channel into a file on persistent storage for later -reuse.</LI> -</UL> -The DOVE Browser uses independent visualization components (Java Beans) -and the Event Channel as DOVE Agent. Connections can be established between -monitored metrics and the visualization components. - -<P>We have three major components: Observables (monitored metrics), -Observers (a Java Bean for displaying the metric) and a DataHandler -(for demultiplexing the monitored metrics to the appropriate -Observables). Each component inherits from a base class, so that a -certain behavior of the components can be assured for each -component. Relationships between components are based on these base -classes. - -<P>The used Java Beans are required to conform to some standards, as -they have to support a function called "getProperty" which allows the -DOVE Browser to determine if the vizualization capabilities of a -specific Java Bean are sufficient to display the metric. A JavaBean is -for example a Java Panel which shows a Graph of the delivered -doubles. So all metrics can be displayed by this visualization -component which can be expressed by a single double. - -<P>The DataHandler is connected to the Event Push Consumer (PUSH, -because we use the push concept of the Event Service). The Event Push -Consumer does not know what kind of data is transported. The only -component knowing all the details about the dependencies of the -metrics is the DataHandler. This separation allows easy extension and -change of the demo. - -<P><A HREF="http://students.cec.wustl.edu/~mk1/dove.html">Object Diagrams</A> -are available about this new concept. - -<P>Event Service events are used as communication between DOVE -Applications and the DOVE Browser. The DOVE MIB analyses the event -data field of all events and stores this information into a file. The -event data filed is of type CORBA::Any and the DOVE MIB has no notion -of what is conveyed in this field. So the DOVE MIB has to discover the -content via the embedded type code information. Future work includes: - -<UL> -<LI> -Enhancing MIB functionality</LI> - -<LI> -Monitoring the AV Streaming Service</LI> -</UL> - -<HR> -<H3> -<A NAME="forwarding"></A>Location forwarding</H3> -Point of contact: <A HREF="mailto:irfan@cs.wustl.edu">Irfan Pyarali</A>, -<A HREF="mailto:mk1@mk1.wustl.edu">Michael Kircher</A>. - -<P>For more information see <A HREF="../forwarding.html">Location forwarding</A> -<HR> -<H3> -<A NAME="leader"></A>Global resources and leader-follower model</H3> -Point of contact: <A HREF="mailto:irfan@cs.wustl.edu">Irfan Pyarali</A>, -<A HREF="mailto:mk1@mk1.wustl.edu">Michael Kircher</A>. - -<P>For more information see <A HREF="../leader_follower.html">Leader-follower -model</A> -<HR> -<H3> -<A NAME="locate"></A>Implementation of locate request</H3> -Point of contact: <A HREF="mailto:irfan@cs.wustl.edu">Irfan Pyarali</A>, -<A HREF="mailto:mk1@mk1.wustl.edu">Michael Kircher</A>. - -<P>For more information see <A HREF="../locate_request.html">Locate request</A> -<HR> - -<P>Back to the TAO <A HREF="../index.html">documentation index</A>. <!--#include virtual="/~schmidt/cgi-sig.html" --> -</BODY> -</HTML> diff --git a/TAO/docs/releasenotes/orbcore.html b/TAO/docs/releasenotes/orbcore.html deleted file mode 100644 index 61220111426..00000000000 --- a/TAO/docs/releasenotes/orbcore.html +++ /dev/null @@ -1,503 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> - -<!-- $Id$ --> - -<html> - <head> - <title>ORB Core Status</title> - </head> - -<BODY TEXT="#000000" BGCOLOR="#FFFFFF"> - <H3><A NAME="orb"></A>ORB & ORB Core</H3> Point of - contact: <A HREF="mailto:nanbor@cs.wustl.edu">Nanbor Wang</A> - - <p>Last Update: $Date$ </P> - -<P> -<b>Current status:</b> - -<UL> - <LI>Provides dynamically linked wholesale assignment of ORB - strategies for communication, concurrency, demultiplexing, - scheduling, and dispatching using the ACE Service Configurator - framework.</LI> - - <LI>Supports several concurrency models out of the box: - Reactive, Thread-per-Connection, and ORB-per-thread. The - ORB-per-thread design is optimized for real-time I/O - subsystems. (See: <a href="../configurations.html">Configuration - Guide</a>.)</LI> - - <LI>Supports <TT>resolve_initial_references("NameService")</TT> - using ACE support for multicast.</LI> -</UL><p> - -<b>Known issues:</b> -<UL> - <li>Some CORBA objects need to have access to the ORB. We tend to - use TAO_ORB_Core_instance ()->orb () to fetch the right ORB the - object is using. This is most often true when implementing the - shutdown method which allow other process to shutdown a remote - ORB. Althought this may be the "right" thing to do in TAO, it - is not CORBA compliant and hurts the portability of object - implementation. - - A common way of getting around this problem is to cache the ORB - pointer in the object when it is created and simply use the - cached ORB when needed. However, remember that there could be - multiple ORBs in a process and a POA may be shared by several - ORBs. That means, we may not handling the object with the same - ORB it was created. Collocation optimization further complicated - the problem. - - At the moment, using TAO_ORB_Core_instance ()->orb () is the - only sane way to get arond the problem. Though there may be a - better way.<p> - - <li>The acceptor on the server side doesn't get opened until calling - CORBA_ORB::run (). And that's when we check whether the port - the server wants to listen on is available or not. (Unless we - specify ORBport to be 0, which implicitly ask the ORB to open - the connection in ORB_init so we know how to export object - IORs.) The problem of this approach is that the port the server - is listen on may not be available. Since we export object IORs - based on the port specified (or the default port,) without - checking the availability of the port, we may announce a bad IOR - end-point which the server will never be able to listen on. - - A possible solution might be opening the server acceptor - whenever it is trying to export an IOR.<p> - - <li>The ORB doesn't handle the nested upcalls correctly. This seems - to be stemmed from the incorrect suspension/resumption of file - descriptor in connection management. It appears to work fine - when two client and server calling each other from invoking an - object method. This, however, is broken when a third ORB - makes use of the object exported by the original client when the - nested upcalls are in progress.<p> - - <LI>The current demarshalling scheme may not work in cases of - complex types such as sequences of unions or anys or object - references. The engine has difficulty determining the dynamic - type of the objects.<p> - - <LI>Object references for objects dynamically created within - a server may not have proper host.</em> (See also <a - href="#hostfix">recent fix</a>.) - When an object is dynamically created and its object - reference returned, it simply has to "guess" at the host - information that is returned in the IIOP Profile. Currently, it - guesses using the host name, which is a reasonable guess in most - cases.<br> - - However, if there are multiple interfaces on a machine - <i>and</i> they have different host names, it is possible that - the desired effect will not be realized, i.e., the connection to - that new object may use a different interface from the original - object. Currently the only way to change this is to use the <a - href="../Options.html#-ORBhost"><b>-ORBhost</b> option</a> to - manually specify that dynamically-created objects bind to a - specific interface so that their IIOP Profile has the desired - hostname. A more desirable fix is being investigated.<p> -</Ul> - -<b>Recently Completed Work:</b> - -<UL> - <li>Making the collocation table configurable. We can either - use a global collocation table to share objects among ORBs, - or use the per-ORB collocation table. - - <li>Implement the inheritance mechanism in - Default_Server_Connection_Handler to access the parent's - POA. This is necessary when we are using - thread-per-connection concurrency model. - - <li>It is often desireable for a server to start up and not have - to specify the TCP port number on which the ORB will listen, - i.e., let the OS decide. While this works properly (by - providing an argument <code>-ORBport 0</code>), the actual - port number used by the server won't be available after the - server starts listening. TAO now tries to bind the address - when <code>-ORBport 0</code> is issued so it can get the - actual address to publish the IOR for clients' use. - - <li>Added optimization for collocated objects. This - optimization enables TAO to bypass communication layers and - talks to collocated objects directly.</li> - - <li>Broke the tight coupling between <code>CORBA_Object</code> - and <code>IIOP_Object</code> so that multiple - <code>CORBA_Object</code>s can share a single - <code>IIOP_Object</code>. This has a big win in - <code>_narrow</code> operations.</li> - - <li>Eliminated substantial memory leaks in servers.</li> - - <li>Added documentation for <a - href="../Options.html#-ORBpoa"><b>-ORBpoa</b></a>, which - allows individual tweaking of the POA's locality (global - vs. thread-specific) independent of the locality of other - ORB resources. Also, <a - href="../Options.html#-ORBpoalock"><b>-ORBpoalock</b></a> - and <a - href="../Options.html#-ORBpoamgrlock"><b>-ORBpoamgrlock</b></a> - control locking in the POA and POA manager, respectively, - according to application needs.</li> - - <li>Began the process of changing the internals of TAO to use - the "underbar" namespace mapping. This should be completed - soon.</li> - - <li>The ORBs manipulation of object keys and object ids is now - consistent. Canonically, everything is managed as an opaque - sequence of octets. Conversion to/from strings is permitted, - with non-printables turning into a trigraph <b>\hl</b> where - <b>h</b> is the high nibble digit in hex, and <b>l</b> is the - low nibble in hex.</li> - - <li><code>CORBA_ORB::run()</code> should be able to be called - multiply in the same execution path now.</li> - - <li>Fixed the <b>LOCATION_FORWARD</b> capabilities to work as - described in the CORBA 2.1 and the POA specification.</li> - - <li>Fixed problem in the IDL Cubit example which caused the - server to dump core when dealing with <code>_out</code> sequence - types <em>ONLY</em> when compiled with G++. It seems that G++ - decided to interpret the expression <code>output == 0</code> - (where <code>output</code> is of type <code>vector_out</code>) - differently from Sun's C++ compiler.</li> - - <li>Fixed a slight problem in <a href="#hostfix">other recent - work</a> where a servant listening on <code>INADDR_ANY</code> - reported an IOR with address <tt>0.0.0.0</tt>. It now reports - the default hostname instead.</li> - - <LI>Working version of TAO on VxWorks with VME transport.</li> - - <li>TAO now reacts gracefully in the face of a non-existent - <code>svc.conf</code> file or simply missing entries in the - file. It logs a warning message and uses default values - versions of items which it would normally obtain from the - Service Repository.</li> - - <li><a name="hostfix"></a>Fixed problem where object references - for objects dynamically created within a server do not have - proper host, at least if the desired host was specified using <a - href="../Options.html#-ORBhost"><b>-ORBhost</b></a> on the - command line.</li> - - <li>Added support for <a - href="../Options.html#-ORBsndsock"><b>-ORBsndsock</b></a> and <a - href="../Options.html#-ORBrcvsock"><b>-ORBrcvsock</b></a> ORB - options. See <a href="../Options.html">options - documentation</a> for details.</li> - - <li>Added support for pre-established connections using the <a - href="../Options.html#-ORBpreconnect"><b>-ORBpreconnect</b></a> - option. This allows connections to be esablished before any - CORBA requests are made. See <a href="../Options.html">options - documentation</a> for details.</li> - - <li>Eliminated deprecated <b>-OAxxx</b> options parsed by the - Object Adapter <code>init</code> method but no longer used by - part of the ORB.</li> - - <li>Made argument parsing within the ORB and POA consume the - arguments it parses.</li> - - <li>Placed an optimization in IIOP::Profile that should speed up - invocations on the client side rather substantially. This was - done by caching an instance of <code>ACE_INET_Addr</code> in - the private portion of <code>Profile</code> because the cost - of constructing one for every invocation (in - <code>TAO_GIOP_Invocation::start</code>) was simply - enormous--the construction was something like 100 cycles on - Solaris. This is all because deep down this ends up calling - <code>gethostbyname()</code>, which can be very costly. Of - course, this is platform-dependent, so the improvements may - not be as great on a different platform.</li> - - <li>Got rid of need to have compile in TSS ORB Core - (<code>-DTAO_HAS_TSS_ORBCORE</code>). This is accomplished by - having a Resource Factory (<code>TAO_Resource_Factory</code>) - singleton which the ORB Core consults in order to get pointers - to resources. The Resource Factory can be configured to - return pointers from thread-specific storage, or - process-global storage. By doing this, the ORB Core is - shielded from ever having to know whether or not its resources - are global or not.</li> - - <li>Made all command-line like options look like the - standard-professed options, i.e., <b>-ORBxxx</b> or - <b>-OAxxxx</b>.</li> - - <li>Moved ORB option parsing into - <code>TAO_ORB_Core::init()</code> rather than in - <code>ORB_init()</code>.</li> - - <li>Define <code>_FAR</code> for all cases as an interim fix - for LynxOS.</li> - - <li>Fixed TAO so that the default port of 5001 is defined in - <code>orb_core.h</code> config header somewhere rather than in - <code>orbobj.cpp</code>, and use <b>MAXHOSTNAMELEN</b> ACE - constant for the hostname buffer.</li> - - <li>Eliminated need for <code>CORBA::Object</code> to keep a - pointer to its orb sitting around anywhere.</li> - - <LI>Tested <code>CORBA_ORB::shutdown()</code> as a manner in - which a thread of control can request that - <code>CORBA_ORB::run()</code> should return and no longer - service requests. It only honors a - <em>wait_for_completion</em> argument of <b>FALSE</b> right - now because we haven't fully explored the issues which - surround doing all the completion.</li> - - <li>Created a brief section in <a - href="../../TAO-INSTALL.html"><code>$TAO_ROOT/TAO-INSTALL.html</code></a> - that <em>briefly</em> documents installation on Unix - platforms. There is also a brief section which documents - issues that apply across ALL platforms, such as the fact that - TAO and its application will likely not work well if your ACE - is linked through Orbix, VisiBroker, or another ORB. <a - href="../../ChangeLog">ChangeLog</a> discovery attribution for - this should go to <em>Steve Wohlever - <wohlever@mitre.org></em>.</li> - - <LI>Implemented <code>CORBA_ORB::shutdown()</code> as a manner - in which a thread of control can request that - <code>CORBA_ORB::run()</code> should return and no longer - service requests.</li> - - <LI>Validated movement of Strategy Connector into - ORB Core.</LI> - - <li>Tested and commited <code>Connector::connect_n</code> - changes to ACE</code>.</li> - - <li>ACE & TAO compiling cleanly using Sun's CC on Solaris and - G++ on Linux. Also, the ACE tests run properly.</li> - - <li>Use <code>truss</code> to verify for <a - href="mailto:PAUL.G.WEHLAGE@cdev.com">Paul Wehlage</a> that - TAO really uses <code>select</code> vs. <code>recv</code> for - <b>-R</b> vs. <b>-T</b>.</li> - - <li>Renamed <code>boa.*</code> to <code>poa.*</code>.</li> - - <LI>Renamed following files: Orb_Core.* ->orb_core.* - & orbobj.* -> corba_orb.*.</LI> - - <LI>The lock used in <code>giop.cpp:626</code> originally - appeared in the IIOP-1.4 code base. Its purpose was to - protect access to the <code>fwd_profile</code> data member. - The original features are available, but they are currently - not used because none of our concurrency models present a - thread-unsafe condition. The <a - href="../../ChangeLog">ChangeLog</a> presents more details - on the subject.</li> - - <li>Fixed problems seen by <a - href="mailto:brian.r.mendel@boeing.com">Brian Mendel</a> of - Boeing where the Cubit server application was crashing in - <code>TAO_OA_Connection_Handler::handle_message</code> when it - was trying to call <code>CORBA::POA::handle_request</code> - through a NULL <code>root_poa</code> pointer. The NULL - pointer resulted from the inadvertent use of the - Thread-per-Connection concurrency model, which is currently - incompatible with the ORB-per-thread model. It was not caught - because the change is normally done in configuration files - parsed by the Service Configurator, and VxWorks requires - special code in that area which was not tested until Boeing - got hold of the code.</li> - - <li>Clean up build under g++. All 'function used before - declared inline' warnings have been eliminated. Also, all - other warnings (except for one that is nearly unavoidable) - have been eliminated. - </li> - - <LI>Removed BOA and ROA names from the ORB.</LI> - - <LI>Changed <code>CORBA_ORB::open()</code> to return an error - status (first cut at this already there--needs to be checked - out).</LI> - - <LI>Added README file to multiCubit test.</li> -</UL><p> - -<b>Ongoing Work:</b> - -<UL> - <LI>Verify ACE & TAO on Linux using g++, Solaris using CC, and - Solaris using g++.</LI> - - <LI>Use Purify to eliminate straggling problems.</LI> - - <LI>Clean up the internals and analyze for performance - bottlenecks using Quantify.</LI> - - <li>Resolve <code>// @@</code> comment blocks. These are - questions or comments placed in the code by a reviewer - (typically Doug).</li> - - <li>Make more and better documentation on the internals of - TAO.</li> -</UL><p> - -<b>Current Work:</b> - -<UL> - <LI> - <p>Verify that, in the ORB-per-thread concurrency model, - it's possible to have a factory in each thread that creates - a client and returns an object reference to that client - within that thread. This is different from the model that - Sumedh originally had where the factory was trying to turn - out a client in a separate thread/ORB combination. - - <p>There is no application which attempts this at the moment, - so both a client and a server will need to be manufactured. - Using existing Cubit-like examples (that poor app is so - weary) should reduce development time to a couple of - hours. - - <p>The real strategy/solution is to make - <code>CORBA::Object</code> not keep a pointer to its orb - sitting around anywhere. It should only get it when it needs - it. This should not be difficult to change. - </LI> -</UL><p> - -<b>Critical Work:</b> - -<UL> - <li>Identify/fix the problems in multithreaded client with TSS - resources. This could be done using the leader-follower model - (thread-pool.) - <LI>Support new concurrency models, e.g., Thread-per-Request, - thread pool, etc..</LI> -</UL> - -<b>Future work:</b> -<UL> - <li>Performance optimizations, such as: - <ol> - <li>Strategize the connection management scheme so that we - don't always have to pay the price of a look up in the - connection cache. Basically, we want to be able to "hold" a - service handler for a string of requests. And, of course, - do this in a portable manner.</LI> - - <li>Replace all uses of <code>new</code> and - <code>delete</code> with allocators that can be put into - TSS. The main motivation for this is to eliminate lock - contention when multiple threads need to allocate/deallocate - memory, however it might also be possible to substitute an - allocator better-tuned to an application's specific - usage.</li> - </ol> - </li> - - <li>Robustness improvements: - <ol> - <li>Improve connection cache so that it won't crash when there - are no more slots or sockets.</li> - - <li>Add an option to the ORB core, e.g., - <b>-ORBnameservicetimeout</b>, to allow specification of an - upper bound on the itime-to-wait for a response from the - ORB's multicast "search" for a running name server.</li> - </ol> - </li> - - <li>New features: - <ol> - <li>Implement <code>ORB::perform_work</code> and - <code>ORB::work_pending</code> so that <code>ORB::run</code> - <em>could</em> be implemented in terms of them.</li> - - <li>Improve the <code>Service Configurator</code> service - entry faking on VxWorks.</li> - - <li>Integrate with realtime upcalls (RTUs).</li> - - </ol> - </li> - - <li>Internal restructuring: - <ol> - <li>Remove <code>_FAR</code> from all code.</li> - - <li>Rework underlayment to eliminate <code>IUnknown</code> class.</li> - - <li>Create some sort of internal "request" object which - carries enough context to suport deferred method invocation - such as one might find in the thread-pool approach or - wherever queuing might occur.</li> - - <li>Rethink the entire memory allocation model used by the - ORB. The current one from SSIIOP may no longer be suitable - for our purposes.</li> - </ol> - </li> - - <li>Documentation: - <ol> - <li>Update ORB Patterns paper to reflect the latest TAO has to - offer. Specifically - <ul> - <li>sections on the Abstract Factory and Concurrency - strategies need to be updated, and the entire paper needs to - be reviewed for accuracy w.r.t the current TAO.</li> - <li>Metrics must be re-computed.</li> - <li>Tighten existing discussions.</li> - <li>Add information on new patterns (such as TSS) which - have been used since initial work.</li> - </ul> - - <li>Make the section in <a - href="../../TAO-Install.html"><code>$TAO_ROOT/TAO-Install.html</code></a> - that documents installation on Unix platforms more complete.</li> - - </ol> </li> - - <li>Miscellany: - <ol> - <LI>Assist in porting higher level services (e.g., <A - HREF="#eventchannel">Event Channel</A>) to TAO.</LI> - - <li>Compile and verify ACE and TAO on Linux using the Kuck and - Associates, Inc. (KAI) compiler tools.</li> - <LI>CORBA::TypeCode is causing a memory leak. Since objects - of this type are rather static in nature, this is - currently not a big deal. However, it should be fixed - soon. </LI> - <LI>CORBA_Exception::Release is not working correctly as the - memory is never really freed. </LI> - </ol> - </li> - - - <li>Potential Optimizations: - <ol> - <LI>There is a certain amount of overhead introduced by the - use of TSS Singletons. TSS singletons are very - convenient as the variable does not have to be passed - from function to function. Even though sort of access is - generally acceptable, the overhead of this approach - maybe too high when used in code which is executed - frequently (e.g., during an upcall). This critical code - may have to be restructured not to use TSS Singletons - because of the high overhead associated with it. </LI> - </ol> - </li> - - -</UL> - -</body> -</html> diff --git a/TAO/docs/releasenotes/trader.html b/TAO/docs/releasenotes/trader.html deleted file mode 100644 index a0abc7017b5..00000000000 --- a/TAO/docs/releasenotes/trader.html +++ /dev/null @@ -1,1069 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> -<html> - -<head> -<title>TAO Trading Service Documentation</title> -</head> - -<body text="#000000" link="#0000FF" vlink="#CC0000" bgcolor="#FFFFFF"> - -<hr> - -<h1 align="center">TAO Trading Service Documentation</h1> - -<hr> - -<p>The TAO transient Trading Service implements the COS TradingObject Service -specification, and conforms to the Linked Trader conformance criteria. This document -details how to use the TAO Trading Service from the following perspectives: - -<ul> - <li>as an importer bootstrapping to the Trading Service;</li> - <li>as a service offer exporter;</li> - <li>as an administrator;</li> - <li>as an out-of-the-box server process; </li> - <li>as a collocated object. </li> -</ul> - -<p>In addition, it covers running the Trading Service tests and discusses known bugs and -workarounds.</p> - -<p>This document assumes you are familiar with Trading Service concepts, such as -"importer," "exporter", "service type", "service -offer," and "dynamic property", as well as the roles of each of the Trading -Service's interfaces --- <tt>Lookup</tt>, <tt>Register</tt>, <tt>Admin</tt>, and <tt>Link</tt> -(the TAO implementation doesn't currently support <tt>Proxy</tt>). I recommend reading the -first two sections of the <a href="ftp://www.omg.org/pub/docs/formal/97-12-23.pdf">Trading -Service specification</a>. This document has the following layout: - -<ol> - <li><a href="#TheClientRole">The Client Role</a> <ul> - <li><a href="#BootstrappingtotheTradingService">Bootstrapping to the Trading Service</a> </li> - <li><a href="#The ImporterRolePerformingaQuery">The Importer Role --- Performing a Query</a><ul> - <li><a href="#Constraints">Constraints</a></li> - <li><a href="#Preferences">Preferences</a></li> - <li><a href="#Policies">Policies</a></li> - <li><a href="#FilteringProperties">Filtering Properties</a> </li> - <li><a href="#OfferIterators">Offer Iterators</a></li> - <li><a href="#PropertyEvaluation">Property Evaluation</a></li> - </ul> - </li> - <li><a href="#TheExporterRole">The Exporter Role --- Registering a Service Type and Offer</a> - <ul> - <li><a href="#TheServiceTypeRepository">The Service Type Repository</a> </li> - <li><a href="#ExportingWithdrawingandModifying">Exporting, Withdrawing, and Modifying - Service Offers</a> </li> - <li><a href="#ImplementingDynamicProperties">Implementing Dynamic Properties</a></li> - </ul> - </li> - <li><a href="#TheAdministratorRole">The Administrator Role --- Tweaking Policies and - Adjusting Links</a></li> - </ul> - </li> - <li><a href="#TheServerRole">The Server Role</a><ul> - <li><a href="#TheTAOTradingServiceApplication">The TAO <tt>Trading_Service</tt> Application</a></li> - <li><a href="#ColocatingtheTradingServiceinaTAOApplication">Colocating the Trading Service - in a TAO Application</a></li> - </ul> - </li> - <li><a href="#RunningtheTradingServiceTests">Running the Trading Service Tests</a></li> - <li><a href="#KnownBugsandWorkarounds">Known Bugs and Workarounds</a></li> - <li><a href="#FutureWork">Future Work</a></li> -</ol> - -<hr> - -<h1><a name="TheClientRole">The Client Role</a></h1> - -<p align="left">There are three categories of operations that a client can perform on a -Trading Service instance: exporting a service offer to the Trading Service, importing a -list of Service Offers whose properties satisfy a constraint expression, and attending to -administrative duties --- tweaking policies or adjusting links. The first order of -business, of course, is obtaining a reference to a Trading Service instance, assuming that -instance is not colocated with the client. </p> - -<h2 align="left"><a name="BootstrappingtotheTradingService">Bootstrapping to the Trading -Service</a></h2> - -<p align="left">Like with the Naming Service, the ORB will obtain a reference to a Trading -Service instance's <tt>Lookup</tt> interface when a client invokes the <tt>CORBA::ORB::resolve_initial_references</tt> -method and passes to it the <tt>ObjectID</tt> "<tt>TradingService</tt>". The -following TAO code bootstraps to the Trading Service:</p> - -<table border="1" width="100%" cellpadding="6"> - <tr> - <td width="100%"><pre>TAO_TRY -{ - TAO_ORB_Manager orb_manager; - orb_manager.init (argc, argv, TAO_TRY_ENV); - TAO_CHECK_ENV; - CORBA::ORB_var orb = orb_manager.orb (); - CORBA::Object_var trading_obj = - orb->resolve_initial_references ("TradingService"); - CosTrading::Lookup_var lookup_if = - CosTrading::Lookup::_narrow (trading_obj.in (), TAO_TRY_ENV); - TAO_CHECK_ENV; -} -TAO_CATCHANY -{ - TAO_TRY_ENV.print_exception ("Failed to bootstrap to a trader"); -} -TAO_ENDTRY;</pre> - </td> - </tr> -</table> - -<p>The first time <tt>resolve_initial_references</tt> is called, the ORB uses a multicast -protocol to locate an existing trader. The ORB emits a multicast packet containing a field -identifying the desired service --- Naming or Trading --- and the port number that the -client is listening on for the response (the IP address can be inferred from the packet). -When the trader receives the packet and finds that the id contained within matches its -own, it opens a socket to the client on the designated port, and sends its IOR, which the -ORB converts to an object reference that it caches. </p> - -<p>If the trader IOR is known ahead of time, the string can be passed to the client in the -environment variable <tt>TradingService</tt>, or by the command line option <tt>-ORBtradingserviceior -<IOR></tt>. Likewise, if the multicast port is known ahead of time and differs from -the default port, the port number can be passed to the client in the environment variable <tt>TradingServicePort</tt>, -or by the command line option <tt>-ORBtradingserviceport <PORTNUM></tt>. </p> - -<h2><a name="The ImporterRolePerformingaQuery">The Importer Role --- Performing a Query</a></h2> - -<p>Once the importer has obtained a reference to a trader's <tt>Lookup</tt> interface, it -next needs to fire up a query. The query method takes nine parameters (aside from the <tt>CORBA::Environment</tt>):</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="39%"><tt>const CosTrading::ServiceTypeName</tt></td> - <td width="61%">The Trading Service will search Offers belonging to this subtype. If the <tt>exact_type_match</tt> - policy wasn't explicitly set to false, then offers belonging to subtypes of this type will - also be searched. </td> - </tr> - <tr> - <td width="39%"><tt>const CosTrading::Constraint</tt></td> - <td width="61%">An expression in the OMG standard constraint language, where each property - name is a property defined in the Service Type description of the type being searched.</td> - </tr> - <tr> - <td width="39%"><tt>const CosTrading::Preference</tt></td> - <td width="61%">An expression in the OMG standard constraint language dictating how offers - in the <tt>returned_offers</tt> sequence should be ordered.</td> - </tr> - <tr> - <td width="39%"><tt>const CosTrading::PolicySeq</tt></td> - <td width="61%">Policies governing the breadth of search and the type of permissible - offers. A policy is a name/value pair --- a string and an <tt>Any</tt> --- that affect the - search algorithm. </td> - </tr> - <tr> - <td width="39%"><tt>const CosTrading::Lookup::SpecifiedProps</tt></td> - <td width="61%">A union specifying which properties should be returned in each offer. If - the descriminator is <tt>CosTrading::Lookup::some</tt>, the union contains the list - of designated property names. Other options are <tt>all</tt>or <tt>none</tt>. </td> - </tr> - <tr> - <td width="39%"><tt>CORBA::ULong how_many</tt></td> - <td width="61%">The number of offers that should be placed in the returned sequence.</td> - </tr> - <tr> - <td width="39%"><tt>CosTrading::OfferSeq_out</tt></td> - <td width="61%">A list of ordered offers whose properties meet the constraints.</td> - </tr> - <tr> - <td width="39%"><tt>CosTrading::OfferIterator_out</tt></td> - <td width="61%">Iterator over returned offers in excess of how_many --- unordered.</td> - </tr> - <tr> - <td width="39%"><tt>CosTrading::PolicyNameSeq_out</tt></td> - <td width="61%">A sequence of policy names for policies that limited the search.</td> - </tr> -</table> - -<h3><a name="Constraints">Constraints</a></h3> - -<p>A constraint is a string in the OMG standard constraint language (the BNF can be found -at the end of the specification). The trader iterates over applicable offers, and for each -offer determines if its properties meet the constraints, replacing property names in the -string with their values and computing the result. If the constraint evaluates to true, -the offer is placed in the pool of matched offers. If the constraint string is -syntactically invalid, contains property names not found in the service type description -for the listed service type, or has operators with mismatched operand types, the query -method will throw an <tt>InvalidConstraint</tt> exception. </p> - -<p>Operands can be of two types: property names or literals. A property name is an -unquoted string of alphanumeric characters and underscores that begins with a letter. The -service type describes the type of a property. A literal is an signed or unsigned integer, -floating point number --- scientific notation acceptable ---, single-quoted string, or -boolean --- written TRUE or FALSE. </p> - -<p>The constraint language supports the following operations:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="25%">Arithmetic (+, -, *, /)</td> - <td width="34%"><tt>Disk_Space*1000 - Amount_Used/10</tt></td> - <td width="41%">Accepts two numeric operands.</td> - </tr> - <tr> - <td width="25%">Inequality (<,>,<=,>=)</td> - <td width="34%"><tt>Amount_Used < Disk_Space</tt></td> - <td width="41%">Accepts two numeric or two string operands.</td> - </tr> - <tr> - <td width="25%">Equality (==, !=)</td> - <td width="34%"><tt>Amount_Used == Disk_Space</tt></td> - <td width="41%">Accepts two numeric, two string, or two boolean operands.</td> - </tr> - <tr> - <td width="25%">Substring (~)</td> - <td width="34%"><tt>'.wustl.edu' ~ Domain_Name</tt></td> - <td width="41%">Accept two string operands. Returns true if the right string contains the - left.</td> - </tr> - <tr> - <td width="25%">Sequence inclusion (in)</td> - <td width="34%"><tt>'sbw1' in User_Queue</tt></td> - <td width="41%">Accepts an operand of a primitive CORBA type on the left, and a sequence - of the same type on the right. Returns true when the sequence contains the value in the - left operand, false otherwise.</td> - </tr> - <tr> - <td width="25%">Property existence (exist)</td> - <td width="34%"><tt>exist User_Queue</tt></td> - <td width="41%">Accepts a property name. Returns true if the property is defined in the - offer.</td> - </tr> -</table> - -<h3><a name="Preferences">Preferences</a></h3> - -<p>A preference is a constraint language string that determines the order of offers in the -returned offer sequence. There are five types of preferences:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="18%"><tt>min</tt> <expression></td> - <td width="82%">Offers are ordered by ascending expression value. The expression must - return a number.</td> - </tr> - <tr> - <td width="18%"><tt>max</tt> <expression> </td> - <td width="82%">Offers are ordered by descending expression value. The expression must - return a number. </td> - </tr> - <tr> - <td width="18%"><tt>with</tt> <expression></td> - <td width="82%">Offers are partitioned into two parts: those offers for which the - expression returns true are placed in the front, the rest in the back. The expression must - return a boolean value.</td> - </tr> - <tr> - <td width="18%"><tt>random</tt></td> - <td width="82%">Offers in the sequence are shuffled.</td> - </tr> - <tr> - <td width="18%"><tt>first</tt></td> - <td width="82%">Offers are placed in the sequence in the order they're evaluated.</td> - </tr> -</table> - -<h3><a name="Policies">Policies</a></h3> - -<p>The following import policies are descibed in the specification and supported by the -TAO Trading Service:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="22%"><tt>exact_type_match</tt></td> - <td width="18%"><tt>CORBA::Boolean</tt></td> - <td width="60%">True --- Search only considers offers belonging to the given type.<br> - False --- Search considers offers belonging to the given type or any of its subtypes.</td> - </tr> - <tr> - <td width="22%"><tt>search_card</tt></td> - <td width="18%"><tt>CORBA::ULong</tt></td> - <td width="60%">Search ceases after <tt>search_card</tt> number of offers have been - evaluated.</td> - </tr> - <tr> - <td width="22%"><tt>match_card</tt></td> - <td width="18%"><tt>CORBA::ULong</tt></td> - <td width="60%">Search ceases after <tt>search_card</tt> number of offers have been - matched.</td> - </tr> - <tr> - <td width="22%"><tt>return_card</tt></td> - <td width="18%"><tt>CORBA::ULong</tt></td> - <td width="60%">Query returns at most <tt>return_card</tt> number of offers.</td> - </tr> - <tr> - <td width="22%"><tt>support_dynamic_properties</tt></td> - <td width="18%"><tt>CORBA::Boolean</tt></td> - <td width="60%">Search considers offers with dynamic properties.</td> - </tr> - <tr> - <td width="22%"><tt>support_modifiable_properties</tt></td> - <td width="18%"><tt>CORBA::Boolean</tt></td> - <td width="60%">Search considers offers with not readonly properties.</td> - </tr> - <tr> - <td width="22%"><tt>starting_trader</tt></td> - <td width="18%"><tt>CosTrading::TraderName</tt></td> - <td width="60%">Query is forwarded across all links in the policy, and search begins at - the final trader.</td> - </tr> - <tr> - <td width="22%"><tt>hop_count</tt></td> - <td width="18%"><tt>CORBA::ULong</tt></td> - <td width="60%">Maximum depth a query should be propagated in the trader federation.</td> - </tr> - <tr> - <td width="22%"><tt>link_follow_rule</tt></td> - <td width="18%"><tt>CosTrading::FollowOption</tt></td> - <td width="60%">Query propagates to other traders if the <tt>link_follow_rule</tt> permits - it.</td> - </tr> -</table> - -<p>The TAO Trading Service comes with a handy utility --- <tt>TAO_Policy_Manager</tt> --- -for creating a policy sequence to pass to the query method that won't incur any -exceptions. Use the <tt>TAO_Policy_Manager</tt> in the following way:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>TAO_Policy_Manager policies; -policies.exact_type_match (CORBA::B_FALSE); -policies.search_card (16*NUM_OFFERS); -policies.match_card (16*NUM_OFFERS); -policies.return_card (16*NUM_OFFERS); -policies.link_follow_rule (CosTrading::local_only); -const CosTrading::PolicySeq& policy_seq = policies.policy_seq ();</pre> - </td> - </tr> -</table> - -<h3><a name="FilteringProperties">Filtering Properties</a></h3> - -<p>If the client wants only a subset of the properties defined for a service type returned -in matching offers, it can specify those property names in the <tt>desired_properties</tt> -parameter of the query method. Pass the <tt>prop_names</tt> method of <tt>CosTrading::Lookup::SpecifiedProperties</tt> -a <tt>CosTrading::PropNameSeq</tt>:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>char* props[] = {"Name", "Description", "Location", "Host_Name" }; -CosTrading::Lookup::SpecifiedProps desired_props; -CosTrading::PropertyNameSeq prop_name_seq (4, 4, props, CORBA::B_FALSE); -desired_props.prop_names (prop_name_seq);</pre> - </td> - </tr> -</table> - -<h3><a name="OfferIterators">Offer Iterators</a></h3> - -<p>Those offers returned from the query in excess of <tt>how_many</tt> are placed in an -offer iterator for deferred retrieval. The <tt>CosTrading::OfferIterator::next_n</tt> -method will allocate a sequence and fill it with either n offers, or if it has fewer than <tt>n</tt> -offers, the remaining offers. The <tt>next_n</tt> method returns true if the iterator -contains more offers, and false if it's been depleted. After finishing with the iterator, -invoke its <tt>destroy</tt> method to release any server-side resources.</p> - -<p>The following code is an example of obtaining offers from a <tt>CosTrading::OfferIterator</tt>:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>CORBA::Boolean any_left = CORBA::B_FALSE; -CORBA::Environment _env;</pre> - <pre>do - { - CosTrading::OfferSeq_ptr iter_offers_ptr; - CosTrading::OfferSeq_out iter_offers_out (iter_offers_ptr); - - any_left = offer_iterator->next_n (length, - iter_offers_out, - _env); - TAO_CHECK_ENV_RETURN (_env, 0); - - CosTrading::OfferSeq_var iter_offers (iter_offers_ptr); - // Process offers... - - } while (any_left);</pre> - </td> - </tr> -</table> - -<h3><a name="PropertyEvaluation">Property Evaluation</a></h3> - -<p>After the client completes a query that used dynamic properties, to review the property -values of the returned offers, it has to distinguish between <tt>Anys</tt> containing -static properties and <tt>Anys</tt> containing dynamic property structures. The <tt>TAO_Property_Evaluator</tt> -class is a handy utility to obtain property values that hides how it evalutes properties -for the client --- by simple <tt>Any</tt> value extraction for static properties, or by -calling back to a dynamic property interface. The <tt>TAO_Property_Evaluator</tt> caches -the value of a dynamic property, and frees the allocated <tt>Anys</tt> during its -destruction. </p> - -<p>The following code demonstrates how to use the <tt>TAO_Property_Evaluator</tt> to dump -the properties of an offer to the screen. </p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>TAO_Property_Evaluator prop_eval (prop_seq); -for (int length = prop_seq.length (), k = 0; k < length; k++) - { - ACE_DEBUG ((LM_DEBUG, "%-15s: ", prop_seq[k].name.in ())); - TAO_TRY - { - CORBA::Boolean is_dynamic = prop_eval.is_dynamic_property (k); - TAO_CHECK_ENV; - - value = prop_eval.property_value(k, env); - TAO_CHECK_ENV; - - if (value != 0) - CORBA::Any::dump (*value); - } - TAO_CATCHANY - { - ACE_DEBUG ((LM_DEBUG, "Error retrieving property value.\n")); - } - TAO_ENDTRY; - }</pre> - </td> - </tr> -</table> - -<h2><a name="TheExporterRole">The Exporter Role --- Registering a Service Type and Offer</a></h2> - -<p>Before an exporting client can register a new service offer with the Trading Service, -it needs to ensure first that its service type is present in the service type repository -of the target trader. The most efficient way to do this is to first invoke the <tt>export</tt> -method on the <tt>Register</tt> interface, and if it raises an <tt>UnknownServiceType</tt> -exception, obtain a reference to the Repository, add the Service Type, and attempt the <tt>export</tt> -a second time. Here's the boilerplate code:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>CORBA::Object_var trading_obj = - orb_ptr->resolve_initial_references ("TradingService"); -CosTrading::Lookup_var lookup_if = - CosTrading::Lookup::_narrow (trading_obj.in (), _env); -TAO_CHECK_ENV_RETURN (_env, -1); -CosTrading::Register_var register_if = lookup_if->register_if (_env); -TAO_CHECK_ENV_RETURN (_env, -1); -CosTrading::TypeRepository_ptr obj = this->trader_->type_repos (_env); -CosTradingRepos::ServiceTypeRepository_var str = - CosTradingRepos::ServiceTypeRepository::_narrow (obj, _env); -TAO_CHECK_ENV_RETURN (_env, -1); - -TAO_TRY - { - // Attempt to export the offer. - offer_id = - register_id->export (object_ref, type, props, TAO_TRY_ENV); - TAO_CHECK_ENV; - } -TAO_CATCH (CosTrading::UnknownServiceType, excp) - { - // If the ServiceTypeName wasn't found, we'll have to add the - // type to the Service Type repository ourselves. - str->add_type (type, - object_ref->_interface_repository_id (), - prop_struct_seq, - super_type_name_seq, - _env); - TAO_CHECK_ENV_RETURN (_env, 0); - - // Now we'll try again to register the offer. - offer_id = reg->export (object_ref, type, this->tprops_, _env); - TAO_CHECK_ENV_RETURN (_env, 0); - - TAO_TRY_ENV.clear (); - } -TAO_CATCHANY - { - // Sigh, all our efforts were for naught. - TAO_RETHROW_RETURN (0); - } -TAO_ENDTRY;</pre> - </td> - </tr> -</table> - -<h3><a name="TheServiceTypeRepository">The Service Type Repository</a></h3> - -<p>Creating a service type description is simply a matter of filling in two sequences: a <tt>CosTradingRepos::ServiceTypeRepository::PropStructSeq</tt> -and a <tt>CosTradingRepos::ServiceTypeRepository::ServiceTypeNameSeq</tt>. When filling in -the <tt>value_type</tt> field, remember to up the reference count of the <tt>TypeCode</tt>, -since otherwise the <tt>TypeCode_var</tt> will sieze control of the memory and free it. -Here's a code excerpt taken from <tt>export_test</tt> showing how to build the first -couple elements of such sequences:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>this->type_structs_[TT_Info::PLOTTER].props.length (2); -this->type_structs_[TT_Info::PLOTTER].super_types.length (1); -this->type_structs_[TT_Info::PLOTTER].super_types[0] = -TT_Info::INTERFACE_NAMES[TT_Info::REMOTE_IO]; -this->type_structs_[TT_Info::PLOTTER].props[0].name = -TT_Info::PLOTTER_PROPERTY_NAMES[TT_Info::PLOTTER_NUM_COLORS]; -this->type_structs_[TT_Info::PLOTTER].props[0].value_type = -CORBA::TypeCode::_duplicate (CORBA::_tc_long); -this->type_structs_[TT_Info::PLOTTER].props[0].mode = -CosTradingRepos::ServiceTypeRepository::PROP_NORMAL; -this->type_structs_[TT_Info::PLOTTER].props[1].name = -TT_Info::PLOTTER_PROPERTY_NAMES[TT_Info::PLOTTER_AUTO_LOADING]; -this->type_structs_[TT_Info::PLOTTER].props[1].value_type = -CORBA::TypeCode::_duplicate (CORBA::_tc_boolean); -this->type_structs_[TT_Info::PLOTTER].props[1].mode = -CosTradingRepos::ServiceTypeRepository::PROP_READONLY;</pre> - </td> - </tr> -</table> - -<h3><a name="ExportingWithdrawingandModifying">Exporting, Withdrawing, and Modifying -Service Offers</a></h3> - -<p>Like with adding a Service Type, exporting an offer is just filling in the sequences. -For offers, of course, property values are passed, so this involves employing the <tt>Any</tt> -insertion operators. Here's a code exerpt from <tt>export_test</tt>:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>CosTrading::PropertySeq prop_seq (2); -prop_seq[0].name = - TT_Info::PLOTTER_PROPERTY_NAMES[TT_Info::PLOTTER_NUM_COLORS]; -prop_seq[0].value <<= ACE_static_cast (CORBA::Long, 256); -prop_seq[1].name = - TT_Info::PLOTTER_PROPERTY_NAMES[TT_Info::PLOTTER_AUTO_LOADING]; -prop_seq[1].value <<= CORBA::Any::from_boolean (CORBA::B_TRUE);</pre> - </td> - </tr> -</table> - -<p>The <tt>export_test</tt> returns a <tt>CosTrading::OfferId</tt> string, which is -required to perform the <tt>withdraw</tt> and <tt>modify</tt> operations on the exported -offer. <tt>withdraw</tt> requires that you simply pass the <tt>OfferId</tt> of the offer -to be withdrawn, while <tt>modify</tt> takes two additional sequences: a <tt>CosTrading::PropertyNameSeq</tt> -of property names to be removed from the offer, and a <tt>CosTrading::PropertySeq</tt> of -offers to be added or changed in the offer. </p> - -<h3><a name="ImplementingDynamicProperties">Implementing Dynamic Properties</a></h3> - -<p>To export an offer with a dynamic property: - -<ul> - <li>inherit from the <tt>TAO_Dynamic_Property</tt> class and implement its <tt>DP_Eval</tt> - method; </li> - <li>create a <tt>CosTradingDynamic::DynamicProperty</tt> structure using the <tt>TAO_Dynamic_Property::construct_dynamic_prop</tt> - method; </li> - <li>insert the <tt>CosTradingDynamic::DynamicProperty</tt> in the value field of the - property. </li> -</ul> - -<p>The following code, taken from the <tt>export_test</tt> example, illustrates this:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>// Step 1: Write the Dynamic Property callback handler. -class Simple_DP : public TAO_Dynamic_Property -{ -public: - - virtual CORBA::Any* evalDP (const char* name, - CORBA::TypeCode_ptr returned_type, - const CORBA::Any& extra_info, - CORBA::Environment& _env) - TAO_THROW_SPEC ((CosTradingDynamic::DPEvalFailure)); -}; - -CORBA::Any* -Simple_DP::evalDP (const char* name, - CORBA::TypeCode_ptr returned_type, - const CORBA::Any& extra_info, - CORBA::Environment& _env) - TAO_THROW_SPEC ((CosTradingDynamic::DPEvalFailure)) -{ - CORBA::Any* return_value = 0; - ACE_NEW_RETURN (return_value, CORBA::Any, 0); - - (*return_value) <<= ACE_static_cast (CORBA::ULong, ACE_OS::rand ()); - return return_value; -}</pre> - <pre>// Step 2: Create the Dynamic Property -Simple_DP dp; -CORBA::Any extra_info; -CosTrading::PropertySeq prop_seq (1); -CosTrading::DynamicProp* dp_struct = - dp.construct_dynamic_prop ("prop_name", - CORBA::_tc_ulong, - extra_info);</pre> - <pre>// Step 3: Turn over the dynamic property to the propery value Any. -CORBA::Environment env; -prop_seq[0].name = "prop_name"; -prop_seq[0].value.replace (CosTrading::_tc_DynamicProp, - dp_struct, - CORBA::B_TRUE, - env); -TAO_CHECK_ENV_RETURN (env, -1);</pre> - </td> - </tr> -</table> - -<h2><a name="TheAdministratorRole">The Administrator Role --- Tweaking Policies and -Adjusting Links</a></h2> - -<p>The trader can be configured remotely through two interfaces: the <tt>Admin</tt> -interface, for tweaking global policies, enabling and disabling interfaces, and dumping -the trader contents; and the <tt>Link</tt> interface, for attaching to and detaching from -other traders. </p> - -<p>Adjusting policies is straightforward. Here's an example of setting the <tt>max_search_card</tt> -policy:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>// lookup_if returned from resolve_initial_references. -CosTrading::Admin_var admin_if = - lookup_if->admin_if (TAO_TRY_ENV); -TAO_CHECK_ENV;</pre> - <pre>admin_if->set_max_match_card (200);</pre> - </td> - </tr> -</table> - -<p>Here's an example of using the list_offers method on the Admin interface to remove all -offers from the Trader:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>TAO_TRY -{ -CosTrading::OfferIdIterator_ptr offer_id_iter; -CosTrading::OfferIdSeq_ptr offer_id_seq; - -// lookup_if returned from resolve_initial_references. -CosTrading::Admin_var admin_if = - lookup_if->admin_if (TAO_TRY_ENV); -TAO_CHECK_ENV; - -CosTrading::Register_var register_if = - lookup_if->register_if (TAO_TRY_ENV); -TAO_CHECK_ENV; - -admin_if->list_offers (10, - CosTrading::OfferIdSeq_out (offer_id_seq), - CosTrading::OfferIdIterator_out (offer_id_iter), - TAO_TRY_ENV); -TAO_CHECK_ENV; - -if (offer_id_seq != 0) - { - CosTrading::OfferIdSeq_var offer_id_seq_var (offer_id_seq); - for (CORBA::ULong i = 0; i < offer_id_seq_var.length (); i++) - { - register_if->withdraw (offer_id_seq_var[i], TAO_TRY_ENV); - TAO_CHECK_ENV; - } - } - -if (offer_id_iter != CosTrading::OfferIdIterator::_nil ()) - { - CORBA::Boolean any_left = CORBA::B_FALSE; - CosTrading::OfferIdSeq_ptr id_seq = 0; - CosTrading::OfferIdIterator_var offer_id_iter_var (offer_id_iter); - - do - { - any_left = - offer_id_iter->next_n (length, - CosTrading::OfferIdSeq_out (id_seq), - TAO_TRY_ENV); - TAO_CHECK_ENV; - - CORBA::ULong offers = id_seq->length (); - for (CORBA::ULong i = 0; i < offers; i++) - { - register_if->withdraw (id_seq[i], TAO_TRY_ENV); - TAO_CHECK_ENV; - } - - delete id_seq; - } - while (any_left); - - offer_id_iter->destroy (TAO_TRY_ENV); - TAO_CHECK_ENV; - } -} -TAO_CATCHANY -{ - // Handle Errors. -} -TAO_ENDTRY;</pre> - </td> - </tr> -</table> - -<p>Here's an example a trader linking itself to another trader (<tt>this->trader_</tt> -is a colocated trader --- see the next section for more information): </p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>TAO_TRY - { - CosTrading::Link_var link_if = lookup_if->link_if (TAO_TRY_ENV); - TAO_CHECK_ENV; - - TAO_Trading_Components_Impl& trd_comp = - this->trader_->trading_components (); - CosTrading::Lookup_ptr our_lookup = trd_comp.lookup_if (); - CosTrading::Link_ptr our_link = trd_comp.link_if (); - - link_if->add_link (this->name_.in (), - our_lookup, - CosTrading::always, - CosTrading::always, - TAO_TRY_ENV); - TAO_CHECK_ENV; - - our_link->add_link ("Bootstrap_Trader", - lookup_if.in (), - CosTrading::always, - CosTrading::always, - TAO_TRY_ENV); - } -TAO_CATCHANY -{ - // Handle Errors. -} -TAO_ENDTRY;</pre> - </td> - </tr> -</table> - -<hr> - -<h1><a name="TheServerRole">The Server Role</a></h1> - -<p>The TAO Trading Service comes with an out-of-the-box executable suitable for common -use. However, it can also easily be colocated with any other TAO server to add Trading -Service functionality to that server.</p> - -<h2><a name="TheTAOTradingServiceApplication">The TAO Trading Service Application</a></h2> - -<p>This out-of-the-box server takes a number of command line arguments:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="26%"><tt>-TSthreadsafe</tt></td> - <td width="74%">The Trader will use reader/writer locks to protect the offer database and - link collection, and normal thread mutexes for the rest of the shared state --- global - policies, support attributes, and interface accessors. (default is not thread safe; Null - Mutexes are used)</td> - </tr> - <tr> - <td width="26%"><tt>-TSconformance</tt></td> - <td width="74%">Determines which conformance category the Trading Service will meet:<br> - <table border="0" width="100%" cellpadding="3"> - <tr> - <td width="18%"><ul> - <li><em>query</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Instantiates the <tt>Lookup</tt> interface only</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>simple</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Instantiates the <tt>Lookup</tt> and <tt>Register</tt> - interfaces</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>standalone</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Instantiates the <tt>Lookup</tt>, <tt>Register</tt>, - and <tt>Admin</tt> interfaces</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>linked</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Instantiates the <tt>Lookup</tt>, <tt>Register</tt>, - <tt>Admin</tt>, and <tt>Link</tt> interfaces (default)</td> - </tr> - </table> - </td> - </tr> - <tr> - <td width="26%"><tt>-TSsupports_dynamic_properties</tt></td> - <td width="74%"><table border="0" width="100%" cellpadding="3"> - <tr> - <td width="18%"><ul> - <li><em>true</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Will consider offers with dynamic properties in - queries unless explicitly disabled by a policy passed to the query method. (default)</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>false</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Will not consider offers with dynamic properties - in queries, unless explicitly enabled by a policy passed to the query method.</td> - </tr> - </table> - </td> - </tr> - <tr> - <td width="26%"><tt>-TSsupports_modifiable_properties</tt></td> - <td width="74%"><table border="0" width="100%" cellpadding="3"> - <tr> - <td width="18%"><ul> - <li><em>true</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Will consider offers with not explicitly - modifable properties in queries unless explicitly disabled by a policy passed to the query - method. Enables the <tt>modify</tt> method on the <tt>Register</tt> interface. (default)</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>false</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">Will not consider dynamic properties in queries, - unless explicitly overridden by a query policy. Diables <tt>modify</tt> method on the <tt>Register</tt> - interface.</td> - </tr> - </table> - </td> - </tr> - <tr> - <td width="26%"><tt>-TSdef_search_card</tt></td> - <td width="74%">Search cardinality if none is specified as a query policy. (default is - 200)</td> - </tr> - <tr> - <td width="26%"><tt>-TSmax_search_card</tt></td> - <td width="74%">Upper limit on the search cardinality for a query. (default is 500)</td> - </tr> - <tr> - <td width="26%"><tt>-TSdef_match_card</tt></td> - <td width="74%">Match cardinality if none is specified as a query policy. (default is 200)</td> - </tr> - <tr> - <td width="26%"><tt>-TSmax_match_card</tt></td> - <td width="74%">Upper limit on the match cardinality for a query. (default is 500)</td> - </tr> - <tr> - <td width="26%"><tt>-TSdef_return_card</tt></td> - <td width="74%">Return cardinality if none is specified as a query policy. (default is - 200)</td> - </tr> - <tr> - <td width="26%"><tt>-TSmax_return_card</tt></td> - <td width="74%">Upper limit on the return cardinality for a query. (default is 500)</td> - </tr> - <tr> - <td width="26%"><tt>-TSdef_hop_count</tt></td> - <td width="74%">The depths a federated query may go if no query policy is specified. - (default 5)</td> - </tr> - <tr> - <td width="26%"><tt>-TSmax_hop_count</tt></td> - <td width="74%">The maximum number of links a federated query can travel after it passes - through this trader. (default is 10) </td> - </tr> - <tr> - <td width="26%"><tt>-TSdef_follow_policy</tt></td> - <td width="74%"><table border="0" width="100%" cellpadding="3"> - <tr> - <td width="18%"><ul> - <li><em>always</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">The trader will always pass a query onto the - next available linked trader.</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>if_no_local</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">The trader will pass a query onto the next - trader only if the local search produced no results. (default)</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>local_only</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">The trader will never pass on a query.</td> - </tr> - </table> - </td> - </tr> - <tr> - <td width="26%"><tt>-TSmax_follow_policy</tt></td> - <td width="74%"><table border="0" width="100%" cellpadding="3"> - <tr> - <td width="18%"><ul> - <li><em>always</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">The trader doesn't limit the importer to the - local offer space. (default)</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>if_no_local</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">The trader refuses to pass on queries of the - local search matched offers.</td> - </tr> - <tr> - <td width="18%"><ul> - <li><em>local_only</em></li> - </ul> - </td> - <td width="82%" valign="top" align="left">The trader will never allow federated queries.</td> - </tr> - </table> - </td> - </tr> - <tr> - <td width="26%"><tt>-ORBtradingserviceport</tt></td> - <td width="74%">Port on which to listen for multicast bootstrap requests.</td> - </tr> -</table> - -<p>By default the trader will listen for multicast <tt>resolve_initial_references</tt> -requests, and respond with the IOR of its <tt>Lookup</tt> inteface. For the purposes of -testing federated queries, when passed the <tt>-TSfederate</tt> method, instead of -becoming a bootstrappable server, the <tt>Trading_Service</tt> application will bootstrap -itself to a multicast trader, link itself to that trader and every other trader accessible -through that trader. This protocol will have all traders on the multicast network form a -complete graph. </p> - -<h2><a name="ColocatingtheTradingServiceinaTAOApplication">Colocating the Trading Service -in a TAO Application</a></h2> - -<p>Colocating the Trading Service in a TAO application amounts to constructing a <tt>TAO_TRADER</tt> -object using the <tt>TAO_Trader_Factory::construct_trader</tt> call. The <tt>argc</tt> and -<tt>argv</tt> parameters to <tt>construct_trader</tt> contain the configuration parameters -described in the previous section. The trader is also configurable programatically through -its attribute classes. The follow code exerpt demonstrates this. </p> - -<p>In addition the application will need to create a service type repository -implementation --- TAO's being the <tt>TAO_Service_Type_Repository</tt> --- and configure -the trader with it. The service type repository is separate from the trader in this way to -allow, for example, multiple traders to share the same service type repository. The -following code exerpt also demontrates configuring the repository:</p> - -<table border="1" width="100%" cellpadding="3"> - <tr> - <td width="100%"><pre>TAO_TRADER* trader = TAO_Trader_Factory::create_trader (argc, argv); -TAO_Support_Attributes_Impl& sup_attr = trader->support_attributes (); -TAO_Import_Attributes_Impl& imp_attr = trader->trading_components (); - -// Configure the trader with a service type repository. -CORBA::Environment _env; -TAO_Service_Type_Repository type_repos* type_repos = 0; -ACE_NEW (type_repos, TAO_Service_Type_Repository); -sup_attr.type_repos (type_repos->_this (_env)); -TAO_CHECK_ENV_RETURN (_env, -1);</pre> - <pre>// Configure other policies, overriding the command line arguments. -imp_attr.search_card (20); -sup_attr.supports_dynamic_properties (CORBA::B_FALSE);</pre> - </td> - </tr> -</table> - -<p>The trader interfaces register themselves with the default POA during the Trading -Service's construction. All that remains is to activate the POA and enter the ORB event -loop. </p> - -<hr> - -<h1><a name="RunningtheTradingServiceTests">Running the Trading Service Tests</a></h1> - -<p>There are two executables that test the Trading Service funtionality --- one to test -the exporter role, and the other, the importer role. To run the tests simply launch the <tt>Trading_Service</tt> -application, then run the <tt>export_test</tt> executable found in the <tt>orbsvcs/tests/Trading</tt> -directory. When the <tt>export_test</tt> ceases to output data and enters the event loop, -run the <tt>import_test</tt> found in the same directory. </p> - -<p><strong>Note: </strong>The export_test and the Trading_Service executables are servers ---- the export_test is a server of dynamic properties. Hence, if you run both executables -on the same machine, you must supply them with different ports. For example, add -ORBport -0 to the export_test command line. </p> - -<p>To test federated queries, run at least three copies of the <tt>Trading_Service</tt> -application, each using the <tt>-TSfederate</tt> flag. The traders will form a complete -graph, with each link follow policy set to <tt>CosTrading::always</tt>. When run with the <tt>-f</tt> -flag, the <tt>export_test</tt> will add the service types and export offers to each of the -traders in the federation. When run with the <tt>-f</tt> flag, the <tt>import_test </tt>will -perform a directed query to a trader two links distant from the trader boostrapped to, in -addition to performing federated queries. </p> - -<p>By default the tests dump the contents of service types and offers to the screen so the -tester can validate the results. To run the tests in quiet mode, where the results of the -describe and query methods are concealed, use the <tt>-q</tt> flag.</p> - -<hr> - -<h1><a name="KnownBugsandWorkarounds">Known Bugs and Workarounds</a></h1> - -<p>The following is a list of known problems with TAO that adversly affect the Trading -Service, and the workarounds applied to those problems.</p> - -<p><strong>Problem: </strong>TAO has difficulty marshalling and demarshalling object -references that extend <tt>CORBA::Object</tt> when they occur as a field in a <tt>struct</tt>. -In the CosTrading IDL file there are two <tt>structs</tt> passed that contain such object -references: <tt>CosTradingDynamic::DynamicProp</tt> and <tt>CosTrading::Link:LinkInfo</tt>. -<br> -<strong>Workaround</strong>: Instead of passing object references in the structs, we pass -the IORs of those object references, strings. The IDL file and the Trading Service code is -compiled with the preprocessor flag <tt>TAO_HAS_OBJECT_IN_STRUCT_MARSHAL_BUG</tt>. For -dynamic properties, as long as the trader clients use the <tt>TAO_Property_Evaluator</tt> -and <tt>TAO_Dynamic_Property</tt> classes, this workaround will be invisible --- these -classes hide the use of the <tt>DynamicProp struct</tt>. However, for those applications -that invoke the <tt>CosTrading::Link::describe_link</tt> method, checking for that flag -definition will be necessary. Two additional lines of code will suffice--- a call to <tt>CORBA::ORB::string_to_object</tt>, -and either <tt>CosTrading::Lookup::_narrow</tt> or <tt>CosTrading::Register::_narrow</tt> -depending on the field of LinkInfo.</p> - -<hr> - -<h1><a name="FutureWork">Future Work</a></h1> - -<ul> - <li><strong>Persistence</strong> --- Have the Trading Service offer database and service - type repository survive the lifetime of a single Trading Service process. This would be - accomplished by either taking advantage of the ability to serialize IDL types --- using - CDR streams --- or through memory-mapped files, <em>a la </em>the ACE Naming Service.</li> -</ul> - -<ul> - <li><strong>The <tt>Proxy</tt> Interface </strong>--- Should we ever feel so motivated, we - might implement the <tt>Proxy</tt> interface. </li> -</ul> - -<hr> - -<address> - <a href="mailto:sbw1@cs.wustl.edu">Seth Benjamin Widoff</a> -</address> -<!-- Created: Mon Jun 29 12:26:36 CDT 1998 --> -<!-- hhmts start --> -</body> -</html> |