Show elapsed time during queries and show execute and plan time above query explain.

This commit is contained in:
Eelke Klein 2017-01-08 15:16:16 +01:00
parent 30638b11e5
commit 5f3ddb80c6
5 changed files with 194 additions and 7 deletions

View file

@ -3,6 +3,7 @@
#include "asyncdbconnection.h"
#include "tsqueue.h"
#include <QLabel>
#include <QMainWindow>
#include <QSocketNotifier>
#include <memory>
@ -48,6 +49,12 @@ public:
private:
TSQueue m_taskQueue;
QLabel *m_timeElapsedLabel;
std::unique_ptr<QTimer> m_timer;
std::chrono::time_point<std::chrono::steady_clock> m_startTime;
void startTimer();
void endTimer();
std::unique_ptr<Ui::MainWindow> ui;
@ -73,6 +80,9 @@ private slots:
void receiveNotice(Pgsql::ErrorDetails notice);
void processCallableQueue();
void addLog(QString s);
void updateTimer();
};
#endif // MAINWINDOW_H