6 Smart Proxies are a TAO extension that helps applications create
7 user-defined proxies that can be used to add custom client-side
8 processing and security to the default stub proxy.
10 For details on how TAO implements Smart Proxies please see:
12 www.cs.wustl.edu/~schmidt/ACE_wrappers/TAO/docs/Smart_Proxies.html
17 This directory contains a simple example that demostrats how the TAO
18 Smart Proxy feature can be used. In this example, just a single
19 method has been "smartified" to illustrate how you just implement the
20 methods you wish to customize since the rest will be taken care of the
21 genearated Smart Proxy base class.
23 All you need to define in the client application is a new factory that
24 will produce the kind of proxy desired by the user. This factory must
25 be provided by the user and must derive from the generated
26 TAO_Default_Proxy_Factory class.
28 This test particularly is used to test out the different policies for the
29 smart proxy. If the same smart proxy is needed for the interface the
30 "one-shot" policy is to be used by which once a smart proxy factory is
31 registered it is retained until the program terminates. This is the default
32 behavior. But if a more flexible option is desired where the smart proxy
33 can be different with every instance of the target object, then the
34 one-shot plolicy has to be disabled by passing a 0 at creation time.
36 For execution of the test:
38 1) ./server -o test1.ior
40 2) ./server -o test2.ior
44 The -f0 option tries out the "per-object" policy and the -f1 (default)
45 tries out the "one-shot" aka "per-interface" policy.
51 Happy troubleshooting!
54 ===============EXPECTED OUTPUT==========================
55 running Smart Proxy test consisting of the client and two servers with <one-shot> policy
60 Test_i::method () invoked
64 Test_i::method () invoked
67 running Smart Proxy test consisting of the client and two servers with <one-shot> policy disabled
72 Test_i::method () invoked
74 Test_i::method () invoked
76 ===========================================================================================
78 Note: Difference in output of first two cases:
79 "Yahoo, I am smart" signifies that the smart proxy is being called. In the first case,
80 it is seen twice demostrating that with both servers the same kind of smart proxy was
81 used since the smart proxy factory was permanent in behavior or "one-shot".
83 While in send portion of the output, the smart proxy is used only once, that is in the
84 first time around and the default proxy is called upon the second time. This is because
85 the smart proxy factory gets unregistered since the "one-shot" policy is disabled.
87 For details, please see: http://www.dre.vanderbilt.edu/~schmidt/PDF/COOTS-00.pdf