replication fixes -- "first: true" support (local.dbinfo.*); clean up class name

This commit is contained in:
Dwight
2008-12-02 14:24:45 -05:00
parent aa8d238b0f
commit 60b769a8cb
38 changed files with 1457 additions and 1241 deletions

View File

@@ -25,13 +25,15 @@
extern int port;
extern string replInfo;
time_t started = time(0);
class DbWebServer : public MiniWebServer {
public:
void doLockedStuff(stringstream& ss) {
dblock lk;
ss << "# clients: " << clients.size() << '\n';
if( client ) {
ss << "curclient: " << client->name;
ss << "# databases: " << databases.size() << '\n';
if( database ) {
ss << "curclient: " << database->name;
ss << '\n';
}
ss << "\n<b>replication</b>\n";
@@ -47,6 +49,7 @@ public:
void doUnlockedStuff(stringstream& ss) {
ss << "port: " << port << '\n';
ss << "dblocked: " << dbLocked << " (initial)\n";
ss << "uptime: " << time(0)-started << " seconds\n";
if( allDead )
ss << "<b>replication allDead=" << allDead << "</b>\n";
}