diff --git a/quesma/quesma/ui/console_routes.go b/quesma/quesma/ui/console_routes.go index 6a5d0ace4..aaf190964 100644 --- a/quesma/quesma/ui/console_routes.go +++ b/quesma/quesma/ui/console_routes.go @@ -61,7 +61,7 @@ func (qmc *QuesmaManagementConsole) createRouting() *mux.Router { }) router.HandleFunc("/data-sources", func(writer http.ResponseWriter, req *http.Request) { - buf := qmc.generateDatasources() + buf := qmc.generateDatasourcesPage() _, _ = writer.Write(buf) }) @@ -107,6 +107,11 @@ func (qmc *QuesmaManagementConsole) createRouting() *mux.Router { _, _ = writer.Write(buf) }) + router.HandleFunc("/panel/data-sources", func(writer http.ResponseWriter, req *http.Request) { + buf := qmc.generateDatasources() + _, _ = writer.Write(buf) + }) + router.PathPrefix("/request-Id/{requestId}").HandlerFunc(func(writer http.ResponseWriter, r *http.Request) { vars := mux.Vars(r) buf := qmc.generateReportForRequestId(vars["requestId"]) diff --git a/quesma/quesma/ui/dashboard.go b/quesma/quesma/ui/dashboard.go index 5b7d1d66a..caf7d60ec 100644 --- a/quesma/quesma/ui/dashboard.go +++ b/quesma/quesma/ui/dashboard.go @@ -6,7 +6,7 @@ import ( "github.com/shirou/gopsutil/v3/host" "github.com/shirou/gopsutil/v3/mem" "mitmproxy/quesma/buildinfo" - "mitmproxy/quesma/quesma/ui/internal/buffer" + "mitmproxy/quesma/quesma/ui/internal/builder" "mitmproxy/quesma/stats/errorstats" "net/url" "runtime" @@ -90,7 +90,7 @@ func (qmc *QuesmaManagementConsole) generateDashboardTrafficElement(typeName str } func (qmc *QuesmaManagementConsole) generateDashboardTrafficPanel() []byte { - var buffer buffer.HtmlBuffer + var buffer builder.HtmlBuffer // Clickhouse -> Kibana if qmc.config.ReadsFromClickhouse() { @@ -124,7 +124,7 @@ func statusToDiv(s healthCheckStatus) string { } func (qmc *QuesmaManagementConsole) generateDashboardPanel() []byte { - var buffer buffer.HtmlBuffer + var buffer builder.HtmlBuffer dashboardName := "