Skip to content
Open
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
93aa97b
Add ResourceStatsDetail proto definitions
jumpei527 Jan 16, 2026
b32d8c0
Generate proto code
jumpei527 Jan 16, 2026
2e451ad
Update ResourceStats API to use Info.Stats
jumpei527 Jan 16, 2026
7651250
Implement ResourceStatsDetail API in gateway lb handler
jumpei527 Jan 19, 2026
05c1c68
Add ResourceStats methods to vald client
jumpei527 Jan 22, 2026
e4a3428
Trigger arm64 build
jumpei527 Jan 22, 2026
1fcff79
Register Stats gRPC service for ResourceStatsDetail
jumpei527 Jan 24, 2026
83494e1
Move ResourceStatsDetail to vald.v1.Stats service
jumpei527 Jan 24, 2026
874b1ba
Regenerate proto files for vald.v1.Stats service
jumpei527 Jan 25, 2026
62c169b
Integrate vald.v1.Stats service into vald.Server
jumpei527 Jan 25, 2026
6e462db
Move StatsDetail API
jumpei527 Feb 11, 2026
aa295fa
Sync swagger and .gitfiles after rebase
jumpei527 Feb 11, 2026
3a9c309
Format rs files
jumpei527 Feb 11, 2026
cf96108
Add StatsDetail e2e test
jumpei527 Feb 12, 2026
df7883b
Fix grammar
jumpei527 Feb 12, 2026
8fbed64
Merge branch 'main' into feature/gateway/add-resource-stats-detail
jumpei527 Mar 7, 2026
e41aea5
Fix redeclared variable
jumpei527 Mar 7, 2026
0a0aea2
:robot: Update license headers / Format go codes and yaml files
vdaas-ci Mar 9, 2026
5f93be8
Use local callErr in broadCast callback to prevent data race
jumpei527 Mar 16, 2026
6c84bf2
Use local callErr in BroadCast callbacks of IndexStatisticsDetail and…
jumpei527 Mar 17, 2026
b8e4ac2
Merge branch 'main' into feature/gateway/add-resource-stats-detail
jumpei527 Mar 17, 2026
f0721f5
Update NGT version
jumpei527 Mar 17, 2026
628704b
Add cargo clean
jumpei527 Mar 18, 2026
63e5986
Revert "Add cargo clean"
jumpei527 Mar 18, 2026
db67104
Merge branch 'main' into feature/gateway/add-resource-stats-detail
jumpei527 Apr 8, 2026
5e042b9
Fix panic in mergeInfoIndexStatistics when all stats are invalid
jumpei527 Apr 8, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitfiles
Original file line number Diff line number Diff line change
Expand Up @@ -1828,6 +1828,7 @@ pkg/agent/core/faiss/handler/grpc/remove.go
pkg/agent/core/faiss/handler/grpc/remove_test.go
pkg/agent/core/faiss/handler/grpc/search.go
pkg/agent/core/faiss/handler/grpc/search_test.go
pkg/agent/core/faiss/handler/grpc/stats.go
pkg/agent/core/faiss/handler/grpc/update.go
pkg/agent/core/faiss/handler/grpc/update_test.go
pkg/agent/core/faiss/handler/grpc/upsert.go
Expand Down Expand Up @@ -1876,6 +1877,7 @@ pkg/agent/core/ngt/handler/grpc/remove.go
pkg/agent/core/ngt/handler/grpc/remove_test.go
pkg/agent/core/ngt/handler/grpc/search.go
pkg/agent/core/ngt/handler/grpc/search_test.go
pkg/agent/core/ngt/handler/grpc/stats.go
pkg/agent/core/ngt/handler/grpc/update.go
pkg/agent/core/ngt/handler/grpc/update_test.go
pkg/agent/core/ngt/handler/grpc/upsert.go
Expand Down Expand Up @@ -2045,6 +2047,7 @@ pkg/gateway/lb/handler/grpc/remove_test.go
pkg/gateway/lb/handler/grpc/search.go
pkg/gateway/lb/handler/grpc/search_benchmark_test.go
pkg/gateway/lb/handler/grpc/search_test.go
pkg/gateway/lb/handler/grpc/stats.go
pkg/gateway/lb/handler/grpc/update.go
pkg/gateway/lb/handler/grpc/update_test.go
pkg/gateway/lb/handler/grpc/upsert.go
Expand Down Expand Up @@ -2407,6 +2410,7 @@ tests/v2/e2e/crud/kubernetes_test.go
tests/v2/e2e/crud/modification_test.go
tests/v2/e2e/crud/object_test.go
tests/v2/e2e/crud/search_test.go
tests/v2/e2e/crud/stats_test.go
tests/v2/e2e/crud/strategy_test.go
tests/v2/e2e/hdf5/hdf5.go
tests/v2/e2e/kubernetes/client.go
Expand Down
84 changes: 67 additions & 17 deletions apis/docs/v1/docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,14 @@
- [Info.Nodes](#payload-v1-Info-Nodes)
- [Info.Pod](#payload-v1-Info-Pod)
- [Info.Pods](#payload-v1-Info-Pods)
- [Info.ResourceStats](#payload-v1-Info-ResourceStats)
- [Info.Service](#payload-v1-Info-Service)
- [Info.ServicePort](#payload-v1-Info-ServicePort)
- [Info.Services](#payload-v1-Info-Services)
- [Info.Stats](#payload-v1-Info-Stats)
- [Info.Stats.CgroupStats](#payload-v1-Info-Stats-CgroupStats)
- [Info.Stats.ResourceStats](#payload-v1-Info-Stats-ResourceStats)
- [Info.Stats.ResourceStatsDetail](#payload-v1-Info-Stats-ResourceStatsDetail)
- [Info.Stats.ResourceStatsDetail.DetailsEntry](#payload-v1-Info-Stats-ResourceStatsDetail-DetailsEntry)
- [Insert](#payload-v1-Insert)
- [Insert.Config](#payload-v1-Insert-Config)
- [Insert.MultiObjectRequest](#payload-v1-Insert-MultiObjectRequest)
Expand Down Expand Up @@ -143,6 +147,7 @@
- [RetryInfo](#rpc-v1-RetryInfo)
- [v1/rpc/stats/stats.proto](#v1_rpc_stats_stats-proto)
- [Stats](#rpc-v1-Stats)
- [StatsDetail](#rpc-v1-StatsDetail)
- [v1/vald/filter.proto](#v1_vald_filter-proto)
- [Filter](#vald-v1-Filter)
- [v1/vald/flush.proto](#v1_vald_flush-proto)
Expand Down Expand Up @@ -576,18 +581,6 @@ Represent the multiple pod information message.
| ----- | -------------------------------- | -------- | ----------------------------- |
| pods | [Info.Pod](#payload-v1-Info-Pod) | repeated | The multiple pod information. |

<a name="payload-v1-Info-ResourceStats"></a>

### Info.ResourceStats

Represent the resource stats

| Field | Type | Label | Description |
| ------------ | ------------------------------------------------ | ----- | ----------------------------------- |
| name | [string](#string) | | |
| ip | [string](#string) | | |
| cgroup_stats | [Info.CgroupStats](#payload-v1-Info-CgroupStats) | | Container resource usage statistics |

<a name="payload-v1-Info-Service"></a>

### Info.Service
Expand Down Expand Up @@ -624,6 +617,54 @@ Represent the multiple service information message.
| -------- | ---------------------------------------- | -------- | --------------------------------- |
| services | [Info.Service](#payload-v1-Info-Service) | repeated | The multiple service information. |

<a name="payload-v1-Info-Stats"></a>

### Info.Stats

Represents the stats info messages.

<a name="payload-v1-Info-Stats-CgroupStats"></a>

### Info.Stats.CgroupStats

| Field | Type | Label | Description |
| ------------------ | ----------------- | ----- | ----------------------------------- |
| cpu_limit_cores | [double](#double) | | CPU cores available |
| cpu_usage_cores | [double](#double) | | CPU usage in cores (not percentage) |
| memory_limit_bytes | [uint64](#uint64) | | Memory limit in bytes |
| memory_usage_bytes | [uint64](#uint64) | | Memory usage in bytes |

<a name="payload-v1-Info-Stats-ResourceStats"></a>

### Info.Stats.ResourceStats

Represent the resource stats

| Field | Type | Label | Description |
| ------------ | ------------------------------------------------------------ | ----- | ----------------------------------- |
| name | [string](#string) | | |
| ip | [string](#string) | | |
| cgroup_stats | [Info.Stats.CgroupStats](#payload-v1-Info-Stats-CgroupStats) | | Container resource usage statistics |

<a name="payload-v1-Info-Stats-ResourceStatsDetail"></a>

### Info.Stats.ResourceStatsDetail

Represents the resource stats for each agent

| Field | Type | Label | Description |
| ------- | ------------------------------------------------------------------------------------------------------ | -------- | ----------- |
| details | [Info.Stats.ResourceStatsDetail.DetailsEntry](#payload-v1-Info-Stats-ResourceStatsDetail-DetailsEntry) | repeated | |

<a name="payload-v1-Info-Stats-ResourceStatsDetail-DetailsEntry"></a>

### Info.Stats.ResourceStatsDetail.DetailsEntry

| Field | Type | Label | Description |
| ----- | ---------------------------------------------------------------- | ----- | ----------- |
| key | [string](#string) | | |
| value | [Info.Stats.ResourceStats](#payload-v1-Info-Stats-ResourceStats) | | |

<a name="payload-v1-Insert"></a>

### Insert
Expand Down Expand Up @@ -1661,12 +1702,21 @@ reached.

### Stats

Overview
Represent the resource stats service.

| Method Name | Request Type | Response Type | Description |
| ------------- | -------------------------------------- | ---------------------------------------------------------------- | ----------------------------------------------------- |
| ResourceStats | [.payload.v1.Empty](#payload-v1-Empty) | [.payload.v1.Info.ResourceStats](#payload-v1-Info-ResourceStats) | Overview Represent the RPC to get the resource stats. |
| Method Name | Request Type | Response Type | Description |
| ------------- | -------------------------------------- | ---------------------------------------------------------------------------- | -------------------------------------------- |
| ResourceStats | [.payload.v1.Empty](#payload-v1-Empty) | [.payload.v1.Info.Stats.ResourceStats](#payload-v1-Info-Stats-ResourceStats) | Represent the RPC to get the resource stats. |

<a name="rpc-v1-StatsDetail"></a>

### StatsDetail

Represent the resource stats detail service.

| Method Name | Request Type | Response Type | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------- | ----------------------------------------------------------- |
| ResourceStatsDetail | [.payload.v1.Empty](#payload-v1-Empty) | [.payload.v1.Info.Stats.ResourceStatsDetail](#payload-v1-Info-Stats-ResourceStatsDetail) | Represent the RPC to get the resource stats for each agent. |

<a name="v1_vald_filter-proto"></a>

Expand Down
148 changes: 122 additions & 26 deletions apis/docs/v1/payload.md.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -270,14 +270,6 @@
{{ template "_field:payload.v1.Info.Memory" }}
{{ template "_field:payload.v1.Info.Node" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.ResourceStats" -}}
{{ template "_scheme:payload.v1.Info.ResourceStats" }}
{{ template "_scheme:payload.v1.Info.CgroupStats" }}
{{- end -}}
{{- define "field:payload.v1.Info.ResourceStats" -}}
{{ template "_field:payload.v1.Info.ResourceStats" }}
{{ template "_field:payload.v1.Info.CgroupStats" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.Service" -}}
{{ template "_scheme:payload.v1.Info.Service" }}
{{ template "_scheme:payload.v1.Info.ServicePort" }}
Expand Down Expand Up @@ -318,6 +310,48 @@
{{ template "_field:payload.v1.Info.Labels.LabelsEntry" }}
{{ template "_field:payload.v1.Info.Annotations.AnnotationsEntry" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.Stats" -}}
{{ template "_scheme:payload.v1.Info.Stats" }}
{{- end -}}
{{- define "field:payload.v1.Info.Stats" -}}
{{ template "_field:payload.v1.Info.Stats" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.Stats.CgroupStats" -}}
{{ template "_scheme:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "field:payload.v1.Info.Stats.CgroupStats" -}}
{{ template "_field:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.Stats.ResourceStats" -}}
{{ template "_scheme:payload.v1.Info.Stats.ResourceStats" }}
{{ template "_scheme:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "field:payload.v1.Info.Stats.ResourceStats" -}}
{{ template "_field:payload.v1.Info.Stats.ResourceStats" }}
{{ template "_field:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.Stats.ResourceStatsDetail" -}}
{{ template "_scheme:payload.v1.Info.Stats.ResourceStatsDetail" }}
{{ template "_scheme:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" }}
{{ template "_scheme:payload.v1.Info.Stats.ResourceStats" }}
{{ template "_scheme:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "field:payload.v1.Info.Stats.ResourceStatsDetail" -}}
{{ template "_field:payload.v1.Info.Stats.ResourceStatsDetail" }}
{{ template "_field:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" }}
{{ template "_field:payload.v1.Info.Stats.ResourceStats" }}
{{ template "_field:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "scheme:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" -}}
{{ template "_scheme:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" }}
{{ template "_scheme:payload.v1.Info.Stats.ResourceStats" }}
{{ template "_scheme:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "field:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" -}}
{{ template "_field:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" }}
{{ template "_field:payload.v1.Info.Stats.ResourceStats" }}
{{ template "_field:payload.v1.Info.Stats.CgroupStats" }}
{{- end -}}
{{- define "scheme:payload.v1.Insert" -}}
{{ template "_scheme:payload.v1.Insert" }}
{{- end -}}
Expand Down Expand Up @@ -1610,24 +1644,6 @@
| pods | Info.Pod | repeated | The multiple pod information. |
{{- end -}}

{{- define "_scheme:payload.v1.Info.ResourceStats" }}
message Info.ResourceStats {
string name = 1;
string ip = 2;
Info.CgroupStats cgroup_stats = 3;
}
{{- end -}}

{{- define "_field:payload.v1.Info.ResourceStats" }}
- Info.ResourceStats

| field | type | label | description |
| :---: | :--- | :---- | :---------- |
| name | string | | |
| ip | string | | |
| cgroup_stats | Info.CgroupStats | | Container resource usage statistics |
{{- end -}}

{{- define "_scheme:payload.v1.Info.Service" }}
message Info.Service {
string name = 1;
Expand Down Expand Up @@ -1682,6 +1698,86 @@
| services | Info.Service | repeated | The multiple service information. |
{{- end -}}

{{- define "_scheme:payload.v1.Info.Stats" }}
message Info.Stats {
// empty
}
{{- end -}}

{{- define "_field:payload.v1.Info.Stats" }}
- Info.Stats

empty
{{- end -}}

{{- define "_scheme:payload.v1.Info.Stats.CgroupStats" }}
message Info.Stats.CgroupStats {
double cpu_limit_cores = 1;
double cpu_usage_cores = 2;
uint64 memory_limit_bytes = 3;
uint64 memory_usage_bytes = 4;
}
{{- end -}}

{{- define "_field:payload.v1.Info.Stats.CgroupStats" }}
- Info.Stats.CgroupStats

| field | type | label | description |
| :---: | :--- | :---- | :---------- |
| cpu_limit_cores | double | | CPU cores available |
| cpu_usage_cores | double | | CPU usage in cores (not percentage) |
| memory_limit_bytes | uint64 | | Memory limit in bytes |
| memory_usage_bytes | uint64 | | Memory usage in bytes |
{{- end -}}

{{- define "_scheme:payload.v1.Info.Stats.ResourceStats" }}
message Info.Stats.ResourceStats {
string name = 1;
string ip = 2;
Info.Stats.CgroupStats cgroup_stats = 3;
}
{{- end -}}

{{- define "_field:payload.v1.Info.Stats.ResourceStats" }}
- Info.Stats.ResourceStats

| field | type | label | description |
| :---: | :--- | :---- | :---------- |
| name | string | | |
| ip | string | | |
| cgroup_stats | Info.Stats.CgroupStats | | Container resource usage statistics |
{{- end -}}

{{- define "_scheme:payload.v1.Info.Stats.ResourceStatsDetail" }}
message Info.Stats.ResourceStatsDetail {
repeated Info.Stats.ResourceStatsDetail.DetailsEntry details = 1;
}
{{- end -}}

{{- define "_field:payload.v1.Info.Stats.ResourceStatsDetail" }}
- Info.Stats.ResourceStatsDetail

| field | type | label | description |
| :---: | :--- | :---- | :---------- |
| details | Info.Stats.ResourceStatsDetail.DetailsEntry | repeated | |
{{- end -}}

{{- define "_scheme:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" }}
message Info.Stats.ResourceStatsDetail.DetailsEntry {
string key = 1;
Info.Stats.ResourceStats value = 2;
}
{{- end -}}

{{- define "_field:payload.v1.Info.Stats.ResourceStatsDetail.DetailsEntry" }}
- Info.Stats.ResourceStatsDetail.DetailsEntry

| field | type | label | description |
| :---: | :--- | :---- | :---------- |
| key | string | | |
| value | Info.Stats.ResourceStats | | |
{{- end -}}

{{- define "_scheme:payload.v1.Insert" }}
message Insert {
// empty
Expand Down
Loading
Loading