This commit is contained in:
parent
709fedf6bf
commit
f9c5f32a89
|
@ -22,8 +22,7 @@ namespace AC_OTE {
|
|||
testFuncs theseFuncs;
|
||||
|
||||
bool acTkInitialised = false, fatal = false, done = false, transferGainer;
|
||||
|
||||
const char *thisRegistry="Donuts", *thatAccount="secura2-ote2", *thisAccount="secura1-ote";
|
||||
const char *thisRegistry="Unknown", *thatAccount="Unknown", *thisAccount="Unknown";
|
||||
char *thisName;
|
||||
|
||||
int cmd=0,debug=1000;
|
||||
|
@ -64,8 +63,7 @@ namespace AC_OTE {
|
|||
DomainCheckCommand *c = new DomainCheckCommand(thisName);
|
||||
DomainCheckResponse *r = new DomainCheckResponse();
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push( new Transaction(c, r) );
|
||||
|
||||
}
|
||||
|
||||
|
@ -80,8 +78,7 @@ namespace AC_OTE {
|
|||
LPChkRespExtension chkRspE;
|
||||
r->registerExtension(&chkRspE);
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push(new Transaction(c, r));
|
||||
|
||||
}
|
||||
|
||||
|
@ -91,8 +88,7 @@ namespace AC_OTE {
|
|||
DomainCreateCommand *c = new DomainCreateCommand(thisName,pw,&RID, &tech, &ns, &admin, &billing);
|
||||
DomainCreateResponse *r = new DomainCreateResponse();
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push(new Transaction(c, r));
|
||||
|
||||
}
|
||||
|
||||
|
@ -108,8 +104,7 @@ namespace AC_OTE {
|
|||
c->appendExtension(crtE1);
|
||||
DomainCreateResponse *r;
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push(new Transaction(c, r));
|
||||
}
|
||||
|
||||
void createContact() {
|
||||
|
@ -118,8 +113,7 @@ namespace AC_OTE {
|
|||
ContactCreateCommand *c = new ContactCreateCommand(ctc,ctcPW,&ctcPO,ctcEmail);
|
||||
ContactCreateResponse *r = new ContactCreateResponse();
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push(new Transaction(c, r));
|
||||
|
||||
}
|
||||
|
||||
|
@ -132,8 +126,7 @@ namespace AC_OTE {
|
|||
c->appendExtension(crtE2);
|
||||
DomainCreateResponse *r = new DomainCreateResponse();
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push(new Transaction(c, r));
|
||||
|
||||
}
|
||||
|
||||
|
@ -145,8 +138,7 @@ namespace AC_OTE {
|
|||
c->appendExtension(crtE1);
|
||||
DomainCreateResponse *r = new DomainCreateResponse();
|
||||
|
||||
thisTest = new Transaction(c, r);
|
||||
acq.push(thisTest);
|
||||
acq.push(new Transaction(c, r));
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -57,6 +57,7 @@
|
|||
|
||||
#ifndef SANS_BOOST
|
||||
#include<boost/asio/datagram_socket_service.hpp>
|
||||
#include<boost/heap/priority_queue.hpp>
|
||||
#endif
|
||||
|
||||
using namespace std;
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
#include <json/json.h>
|
||||
#include "mdJSON.hpp"
|
||||
|
||||
typedef std::priority_queue < Transaction* > ACWQ;
|
||||
typedef boost::heap::priority_queue<Transaction *> ACWQ;
|
||||
|
||||
ACWQ acq;
|
||||
|
||||
|
@ -216,7 +216,7 @@ void ausRegEPPTK::registryXOTE() { // PROD in OTE
|
|||
}
|
||||
void ausRegEPPTK::doPROD()
|
||||
{
|
||||
int hours=0,hoops,minutes=0,seconds=0,idleSeconds=0,lastSeconds=0,lastMinutes;
|
||||
int debug=1000000,hours=0,hoops,minutes=0,seconds=0,idleSeconds=0,lastSeconds=0,lastMinutes;
|
||||
string op("newInstance");
|
||||
|
||||
scenario(thisConfig->tkScenario,thisConfig->cfg_path);
|
||||
|
@ -238,7 +238,14 @@ void ausRegEPPTK::doPROD()
|
|||
if (!acq.empty()) { idleSeconds = 0;
|
||||
|
||||
Transaction *tx = acq.top();
|
||||
|
||||
if (debug > 999)
|
||||
theseLogs->logN(3,"Tx dequeued @ minute %d second %d (%d waiting).",minutes,seconds,acq.size()-1);
|
||||
|
||||
manager->execute(*tx);
|
||||
if (debug > 999)
|
||||
theseLogs->logN(2,"Tx completed @ minute %d second %d.",minutes,seconds);
|
||||
|
||||
acq.pop();
|
||||
delete tx;
|
||||
|
||||
|
@ -260,6 +267,9 @@ void ausRegEPPTK::doPROD()
|
|||
theseLogs->logN(1,"AC Production Hour %d.",hours++);
|
||||
lastMinutes = minutes;
|
||||
}
|
||||
|
||||
if (debug > 9999 && !(seconds % 10))
|
||||
theseLogs->logN(3,"AC Production %d:%d:%d.",hours-1,minutes,seconds);
|
||||
}
|
||||
|
||||
sess->close();
|
||||
|
|
|
@ -65,23 +65,26 @@ bool mdJSON::run()
|
|||
for ( i = 0; i < itemNames.size(); ++i ) { const char *thisItem;
|
||||
try {
|
||||
thisItem = itemNames[i].c_str();
|
||||
if (debug > 100)
|
||||
if (debug > 100000)
|
||||
theseLogs->logN(1,"item %s.",thisItem);
|
||||
if (!stricmp(thisItem,"registry")) {
|
||||
|
||||
}
|
||||
if (strncmp(thisItem,"case",4)) continue;
|
||||
if (strlen(thisItem) != 6) continue;
|
||||
if (debug > 100)
|
||||
if (debug > 100000)
|
||||
theseLogs->logN(1,"case %s.",thisItem);
|
||||
if (!AC_OTE::theseFuncs[thisItem]) {
|
||||
theseLogs->logN(1,"No logic to bind to '%s', need it.",thisItem);
|
||||
return false;
|
||||
}
|
||||
if (!suite[i].isObject()) {
|
||||
theseLogs->logN(1,"'%s' isn't an object, can't use.",thisItem);
|
||||
continue;
|
||||
} /*
|
||||
//if (!suite[i].isObject()) {
|
||||
// theseLogs->logN(1,"'%s' isn't an object, can't use.",thisItem);
|
||||
// continue;
|
||||
//}
|
||||
AC_OTE::theseCases[nCases].parms = NULL;
|
||||
AC_OTE::theseCases[nCases].fBody = AC_OTE::theseFuncs[thisItem];
|
||||
AC_OTE::theseCases[nCases++].caseName = thisItem; */
|
||||
AC_OTE::theseCases[nCases++].caseName = thisItem;
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
|
@ -93,10 +96,9 @@ bool mdJSON::run()
|
|||
|
||||
for (i=0;i<AC_OTE::theseCases.size();i++) {
|
||||
try{
|
||||
theseLogs->logN(2,"%d (%s) Begin ",i,AC_OTE::theseCases[i].caseName );
|
||||
theseLogs->logN(2,"%d Begin setup of %s ",i+1,AC_OTE::theseCases[i].caseName );
|
||||
AC_OTE::theseCases[i].fBody();
|
||||
theseLogs->logN(2,"%d (%s) End ",i,AC_OTE::theseCases[i].caseName );
|
||||
|
||||
theseLogs->logN(2,"%d End setup of %s ",i+1,AC_OTE::theseCases[i].caseName );
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue