Create a form to characterize a server configuration (cpu, ram, ...)
da-ekchajzer opened this issue · comments
The impacts are retrieved from server configuration. We want users to be able to give a specific configuration through a form. The inputs will be used in the construction of a request to the API.
Specifications
Router
router : https://dev.api.boavizta.org/v1/server/
openapi spec : https://dev.api.boavizta.org/docs#/server/server_impact_from_configuration_v1_server__post
Explanation : https://doc.dev.api.boavizta.org/Explanations/devices/server/
Reference : https://doc.dev.api.boavizta.org/Reference/server_route/
RAM
see : https://doc.dev.api.boavizta.org/Explanations/components/ram/
Fields
units
capacity
manufacturer
- select from https://dev.api.boavizta.org/docs#/utils/utils_get_all_ram_manufacturer_v1_utils_ram_manufacturer_getprocess
API request
{
...
"configuration":{
"ram":[{
"units":2,
"capacity": 32,
"manufacturer": "Samsung",
"process": 30.0
}],
...}
}
CPU
see : https://doc.dev.api.boavizta.org/Explanations/components/cpu/
Fields
units
core_units
die_size
manufacturer
die_size_per_core
model_range
- select from https://dev.api.boavizta.org/docs#/utils/utils_get_all_cpu_model_range_v1_utils_cpu_model_range_getfamily
- select from https://dev.api.boavizta.org/docs#/utils/utils_get_all_cpu_family_v1_utils_cpu_family_getname
tdp
API requests
{
...
"configuration":{
"cpu":{
"core_units": 24,
"die_size_per_core": 0.245,
"tdp":150
},
...
}
}
{
...
"configuration":{
"cpu":{
"name": "Intel Core i7-1065",
"tdp":150
},
...
}
}
HDD
see HDD : https://doc.dev.api.boavizta.org/Explanations/components/hdd/
Field
units
type
capacity
(not used)
API request
{
...
"configuration":{
"disk":[{
"type": "HDD"
}]
},
...
}
SSD
see SSD : https://doc.dev.api.boavizta.org/Explanations/components/ssd/
Field
units
type
capacity
density
manufacturer
- select from https://dev.api.boavizta.org/docs#/utils/utils_get_all_ssd_manufacturer_v1_utils_ssd_manufacturer_get
API request
{
"configuration":{
...
"disk":[{
"type": "SSD",
"capacity": 500,
"manufacturer": "Samsung",
}],
...
}
}
{
...
"configuration":{
"disk":[{
"type": "SSD",
"capacity": 500,
"density": 50.6
}],
...
}
}
POWER SUPPLY
see : https://doc.dev.api.boavizta.org/Explanations/components/power_supply/
Field
units
unit_weight
API request
{
...
"configuration":{
"power_supply":{
"units": 2,
"unit_weight": 2.99
},
...
}
}
CASE
see : https://doc.dev.api.boavizta.org/Explanations/components/case/
Field
type
: "blade" or "rack" - select from https://dev.api.boavizta.org/docs#/utils/utils_get_all_case_type_v1_utils_case_type_get
API request
{
"model": {
"type": "rack",
},
"configuration":{...}
...
}
General exemple
{
"configuration":
{
"cpu":
{
"units": 2,
"core_units": 24,
"die_size_per_core": 0.245
},
"ram":
[
{
"units": 12,
"capacity": 32,
"density": 1.79
}
],
"disk":
[
{
"units": 1,
"type": "ssd",
"capacity": 400,
"density": 50.6
}
],
"power_supply":
{
"units": 2,
"unit_weight": 2.99
}
}
}