diff options
author | jai <jai@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2007-01-29 21:15:18 +0000 |
---|---|---|
committer | jai <jai@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2007-01-29 21:15:18 +0000 |
commit | b71531b42b3325fd6079a7039aae8641262c8adf (patch) | |
tree | a5b9aa16924c541fcb424ee9460b1ac7f5a89352 /modules/CIAO/performance-tests/Benchmark/RoundTripClient/client.cpp | |
parent | a0f67cc97c0050d907145e312135b60c0125e56e (diff) | |
download | ATCD-DS-main.tar.gz |
branching/taggingDS-main
Diffstat (limited to 'modules/CIAO/performance-tests/Benchmark/RoundTripClient/client.cpp')
-rw-r--r-- | modules/CIAO/performance-tests/Benchmark/RoundTripClient/client.cpp | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/modules/CIAO/performance-tests/Benchmark/RoundTripClient/client.cpp b/modules/CIAO/performance-tests/Benchmark/RoundTripClient/client.cpp new file mode 100644 index 00000000000..23b58d9cece --- /dev/null +++ b/modules/CIAO/performance-tests/Benchmark/RoundTripClient/client.cpp @@ -0,0 +1,51 @@ +// $Id$ + +//============================================================== +/** + * @file client.cpp + * + * This is a simple client test program that interact with the RoundTrip + * component implementation. The single threaded client issues + * two-way operations, the total latency (response time) is measured + * NOTE: this client implementation has been adapted from the + * $TAO_ROOT/performance-results/Latency/Single_Threaded/ + * + * @author Arvind S. Krishna <arvindk@dre.vanderbilt.edu> + */ +//============================================================== +#include "RoundTripClientC.h" + +const char *ior = "file://test.ior"; + +int +main (int argc, char *argv[]) +{ + try + { + + // Initialize orb + CORBA::ORB_var orb = CORBA::ORB_init (argc, + argv, + ""); + + // Resolve HomeFinder interface + CORBA::Object_var obj + = orb->string_to_object (ior); + Benchmark::RoundTripClient_var test = + Benchmark::RoundTripClient::_narrow(obj.in()); + //Get the RoundTrip reference + Benchmark::Controller_var trigger = test->provide_controller (); + + //Send a trigger to start the test + trigger->start(); + + } + catch (const CORBA::Exception& ex) + { + ex._tao_print_exception ("Exception Handled:"); + return 1; + } + + + return 0; +} |