Add server sub-resource topology API

Add a new server topology API to show server NUMA information:
  - GET /servers/{server_id}/topology

Add new policy to control the default behavior:
  - compute:server:topology:index
  - compute:server:topology:host:index

Change-Id: Ie647ef96597195b0ef00f77cece16c2bef8a78d4
Implements: blueprint show-server-numa-topology
Signed-off-by: Yongli He <yongli.he@intel.com>
This commit is contained in:
Yongli He
2019-02-26 06:57:52 +08:00
parent eb6fcb2191
commit 3dcb404b1f
19 changed files with 620 additions and 3 deletions
@@ -0,0 +1,31 @@
{
"nodes": [
{
"memory_mb": 1024,
"siblings": [
[
0,
1
]
],
"vcpu_set": [
0,
1
]
},
{
"memory_mb": 2048,
"siblings": [
[
2,
3
]
],
"vcpu_set": [
2,
3
]
}
],
"pagesize_kb": 4
}
@@ -0,0 +1,41 @@
{
"nodes": [
{
"cpu_pinning": {
"0": 0,
"1": 5
},
"host_node": 0,
"memory_mb": 1024,
"siblings": [
[
0,
1
]
],
"vcpu_set": [
0,
1
]
},
{
"cpu_pinning": {
"2": 1,
"3": 8
},
"host_node": 1,
"memory_mb": 2048,
"siblings": [
[
2,
3
]
],
"vcpu_set": [
2,
3
]
}
],
"pagesize_kb": 4
}
@@ -19,7 +19,7 @@
}
],
"status": "CURRENT",
"version": "2.77",
"version": "2.78",
"min_version": "2.1",
"updated": "2013-07-23T11:33:21Z"
}
@@ -22,7 +22,7 @@
}
],
"status": "CURRENT",
"version": "2.77",
"version": "2.78",
"min_version": "2.1",
"updated": "2013-07-23T11:33:21Z"
}