chore: sync from fn-registry agent
This commit is contained in:
@@ -0,0 +1,62 @@
|
||||
#pragma once
|
||||
|
||||
// Tabs / panels for data_factory:
|
||||
// - Map (flat tree by kind, placeholder for future graph)
|
||||
// - Extractors (table of kind=extractor nodes)
|
||||
// - Transformers (kind=transformer)
|
||||
// - Databases (registered databases)
|
||||
// - Sinks (kind=sink)
|
||||
// - Health (KPIs derived from runs cache)
|
||||
// - Node Detail (side panel, fn metadata + recent runs)
|
||||
|
||||
#include "data_http.h"
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace data_factory_ui {
|
||||
|
||||
// Cross-tab selection.
|
||||
struct Selection {
|
||||
std::string node_id; // "" = none
|
||||
std::string run_id; // "" = none
|
||||
};
|
||||
|
||||
Selection& selection();
|
||||
|
||||
// Cached function metadata for the node detail panel.
|
||||
struct FunctionCache {
|
||||
std::string function_id;
|
||||
data_factory::FnInfo info;
|
||||
bool loaded = false;
|
||||
std::string error;
|
||||
};
|
||||
|
||||
FunctionCache& function_cache();
|
||||
|
||||
void draw_map(const std::string& api_url,
|
||||
const std::vector<data_factory::Node>& nodes);
|
||||
|
||||
void draw_extractors(const std::string& api_url,
|
||||
const std::vector<data_factory::Node>& nodes,
|
||||
const std::vector<data_factory::Run>& runs_all);
|
||||
|
||||
void draw_transformers(const std::string& api_url,
|
||||
const std::vector<data_factory::Node>& nodes,
|
||||
const std::vector<data_factory::Run>& runs_all);
|
||||
|
||||
void draw_databases(const std::string& api_url,
|
||||
const std::vector<data_factory::DatabaseInfo>& dbs);
|
||||
|
||||
void draw_sinks(const std::string& api_url,
|
||||
const std::vector<data_factory::Node>& nodes,
|
||||
const std::vector<data_factory::Run>& runs_all);
|
||||
|
||||
void draw_health(const std::string& api_url,
|
||||
const std::vector<data_factory::Run>& runs_all);
|
||||
|
||||
void draw_node_detail_panel(const std::string& api_url,
|
||||
const std::vector<data_factory::Node>& nodes,
|
||||
const std::vector<data_factory::Run>& runs_all,
|
||||
bool* p_open);
|
||||
|
||||
} // namespace data_factory_ui
|
||||
Reference in New Issue
Block a user