summaryrefslogtreecommitdiff
path: root/cppe/demo/IceE/throughput/Server.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cppe/demo/IceE/throughput/Server.cpp')
-rw-r--r--cppe/demo/IceE/throughput/Server.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/cppe/demo/IceE/throughput/Server.cpp b/cppe/demo/IceE/throughput/Server.cpp
index 78d459eda97..b33bd0a3eff 100644
--- a/cppe/demo/IceE/throughput/Server.cpp
+++ b/cppe/demo/IceE/throughput/Server.cpp
@@ -14,8 +14,20 @@ using namespace std;
int
run(int argc, char* argv[], const Ice::CommunicatorPtr& communicator)
{
+ //
+ // Check if we need to run with small sequences
+ //
+ int reduce = 1;
+ for(int i = 0; i < argc; ++i)
+ {
+ if(strcmp(argv[i], "--small") == 0)
+ {
+ reduce = 100;
+ }
+ }
+
Ice::ObjectAdapterPtr adapter = communicator->createObjectAdapter("Throughput");
- Ice::ObjectPtr object = new ThroughputI;
+ Ice::ObjectPtr object = new ThroughputI(reduce);
adapter->add(object, Ice::stringToIdentity("throughput"));
adapter->activate();
communicator->waitForShutdown();