Skip to content

Commit d26a533

Browse files
authored
fix: helm value and config path mismatch bug (#238)
* fix: config path mismatch issue * fix: tsdb schema precision issue
1 parent 77ff337 commit d26a533

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

charts/tensor-fusion/templates/rbac-hypervisor.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ rules:
88
resources:
99
- nodes
1010
- pods
11+
- namespaces
1112
verbs:
1213
- get
1314
- list

internal/metrics/migrate.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,17 @@ var TFVersionMigrationMap = []struct {
88
}{
99
// init version, just run init SQL
1010
{"1.0", []string{
11-
"CREATE TABLE IF NOT EXISTS tf_worker_resources (\n `worker` String NULL SKIPPING INDEX,\n `workload` String NULL INVERTED INDEX,\n `pool` String NULL INVERTED INDEX,\n `namespace` String NULL INVERTED INDEX,\n `qos` String NULL,\n `tflops_request` Double NULL,\n `tflops_limit` Double NULL,\n `vram_bytes_request` Double NULL,\n `vram_bytes_limit` Double NULL,\n `gpu_count` BigInt NULL,\n `raw_cost` Double NULL,\n `ts` Timestamp_ms TIME INDEX,\n PRIMARY KEY (`worker`, `workload`, `pool`, `namespace`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
11+
"CREATE TABLE IF NOT EXISTS tf_worker_resources (\n `worker` String NULL SKIPPING INDEX,\n `workload` String NULL INVERTED INDEX,\n `pool` String NULL INVERTED INDEX,\n `namespace` String NULL INVERTED INDEX,\n `qos` String NULL,\n `tflops_request` Double NULL,\n `tflops_limit` Double NULL,\n `vram_bytes_request` Double NULL,\n `vram_bytes_limit` Double NULL,\n `gpu_count` BigInt NULL,\n `raw_cost` Double NULL,\n `ts` Timestamp_ns TIME INDEX,\n PRIMARY KEY (`worker`, `workload`, `pool`, `namespace`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
1212

13-
"CREATE TABLE IF NOT EXISTS tf_node_resources (\n `node_name` String NULL INVERTED INDEX,\n `pool` String NULL INVERTED INDEX,\n `allocated_tflops` Double NULL,\n `allocated_tflops_percent` Double NULL,\n `allocated_vram_bytes` Double NULL,\n `allocated_vram_percent` Double NULL,\n `allocated_tflops_percent_virtual` Double NULL,\n `allocated_vram_percent_virtual` Double NULL,\n `raw_cost` Double NULL,\n `gpu_count` BigInt NULL,\n `ts` Timestamp_ms TIME INDEX,\n PRIMARY KEY (`node_name`, `pool`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
13+
"CREATE TABLE IF NOT EXISTS tf_node_resources (\n `node_name` String NULL INVERTED INDEX,\n `pool` String NULL INVERTED INDEX,\n `allocated_tflops` Double NULL,\n `allocated_tflops_percent` Double NULL,\n `allocated_vram_bytes` Double NULL,\n `allocated_vram_percent` Double NULL,\n `allocated_tflops_percent_virtual` Double NULL,\n `allocated_vram_percent_virtual` Double NULL,\n `raw_cost` Double NULL,\n `gpu_count` BigInt NULL,\n `ts` Timestamp_ns TIME INDEX,\n PRIMARY KEY (`node_name`, `pool`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
1414

15-
"CREATE TABLE IF NOT EXISTS tf_system_metrics (\n `pool` String NULL INVERTED INDEX,\n `total_workers_cnt` BigInt NULL,\n `total_nodes_cnt` BigInt NULL,\n `total_allocation_fail_cnt` BigInt NULL,\n `total_allocation_success_cnt` BigInt NULL,\n `total_scale_up_cnt` BigInt NULL,\n `total_scale_down_cnt` BigInt NULL,\n `ts` Timestamp_ms TIME INDEX,\n PRIMARY KEY (`pool`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
15+
"CREATE TABLE IF NOT EXISTS tf_system_metrics (\n `pool` String NULL INVERTED INDEX,\n `total_workers_cnt` BigInt NULL,\n `total_nodes_cnt` BigInt NULL,\n `total_allocation_fail_cnt` BigInt NULL,\n `total_allocation_success_cnt` BigInt NULL,\n `total_scale_up_cnt` BigInt NULL,\n `total_scale_down_cnt` BigInt NULL,\n `ts` Timestamp_ns TIME INDEX,\n PRIMARY KEY (`pool`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
1616

1717
"CREATE TABLE IF NOT EXISTS tf_system_log (\n `component` String NULL INVERTED INDEX,\n `container` String NULL INVERTED INDEX,\n `message` String NULL FULLTEXT INDEX WITH (analyzer = 'English' , case_sensitive = 'false'),\n `namespace` String NULL INVERTED INDEX,\n `pod` String NULL SKIPPING INDEX,\n `stream` String NULL,\n `timestamp` String NULL,\n `greptime_timestamp` Timestamp_ms TIME INDEX,\n PRIMARY KEY (`component`, `container`, `namespace`, `pod`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
1818

19-
"CREATE TABLE IF NOT EXISTS tf_worker_usage (\n `workload` String NULL INVERTED INDEX,\n `worker` String NULL SKIPPING INDEX,\n `pool` String NULL INVERTED INDEX,\n `node_name` String NULL INVERTED INDEX,\n `uuid` String NULL INVERTED INDEX,\n `compute_percentage` Double NULL,\n `memory_bytes` BigInt UNSIGNED NULL,\n `compute_tflops` Double NULL,\n `compute_throttled_cnt` BigInt NULL,\n `vram_freezed_cnt` BigInt NULL,\n `vram_resumed_cnt` BigInt NULL,\n `ts` Timestamp_ms TIME INDEX,\n PRIMARY KEY (`workload`, `worker`, `pool`, `node_name`, `uuid`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
19+
"CREATE TABLE IF NOT EXISTS tf_worker_usage (\n `workload` String NULL INVERTED INDEX,\n `worker` String NULL SKIPPING INDEX,\n `pool` String NULL INVERTED INDEX,\n `node_name` String NULL INVERTED INDEX,\n `uuid` String NULL INVERTED INDEX,\n `compute_percentage` Double NULL,\n `memory_bytes` BigInt UNSIGNED NULL,\n `compute_tflops` Double NULL,\n `compute_throttled_cnt` BigInt NULL,\n `vram_freezed_cnt` BigInt NULL,\n `vram_resumed_cnt` BigInt NULL,\n `ts` Timestamp_ns TIME INDEX,\n PRIMARY KEY (`workload`, `worker`, `pool`, `node_name`, `uuid`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
2020

21-
"CREATE TABLE IF NOT EXISTS tf_gpu_usage (\n `node_name` String NULL INVERTED INDEX,\n `pool` String NULL INVERTED INDEX,\n `uuid` String NULL INVERTED INDEX,\n `compute_percentage` Double NULL,\n `memory_percentage` Double NULL,\n `memory_bytes` BigInt UNSIGNED NULL,\n `compute_tflops` Double NULL,\n `rx` Double NULL,\n `tx` Double NULL,\n `temperature` Double NULL,\n `ts` Timestamp_ms TIME INDEX,\n PRIMARY KEY (`node_name`, `pool`, `uuid`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
21+
"CREATE TABLE IF NOT EXISTS tf_gpu_usage (\n `node_name` String NULL INVERTED INDEX,\n `pool` String NULL INVERTED INDEX,\n `uuid` String NULL INVERTED INDEX,\n `compute_percentage` Double NULL,\n `memory_percentage` Double NULL,\n `memory_bytes` BigInt UNSIGNED NULL,\n `compute_tflops` Double NULL,\n `rx` Double NULL,\n `tx` Double NULL,\n `temperature` Double NULL,\n `ts` Timestamp_ns TIME INDEX,\n PRIMARY KEY (`node_name`, `pool`, `uuid`))\n ENGINE=mito WITH( ttl='30d', merge_mode = 'last_non_null')",
2222
}},
2323

2424
// add alter SQL in future

0 commit comments

Comments
 (0)