Performance Profiles
Create Performance Profile
Client will invoke the Kruize createPerformanceProfile API for each deployment. Documentation still in progress stay tuned.
Attributes
- name
A unique string name for identifying each performance profile. - profile_version
a double value specifying the current version of the profile. - slo
Service Level Objective containing the direction, objective_function and function_variables- slo_class
a standard slo “bucket” defined by Kruize. Can be “resource_usage”, “throughput” or “response_time” - direction
based on the slo_class, it can be ‘maximize’ or ‘minimize’ - objective_function
Define the performance objective here.- function_type
can be specified as ‘source’ (a java file) or as an ‘expression‘(algebraic). If it’s an expression, it needs to defined below. - expression
an algebraic expression that details the calculation using function variables. Only valid if the “function_type” is “expression”
- function_type
- function_variables
Define the variables used in the objective_function- name
name of the variable - datasource
datasource of the query - value_type
can be double or integer - query
one of the query or aggregation_functions is mandatory. Both can be present. - kubernetes_object
k8s object that this query is tied to: “deployment”, “pod” or “container” - aggregation_functions
aggregate functions associated with this variable- function
can be ‘avg’, ‘sum’, ‘min’, ‘max’ - query
corresponding query - versions
Any specific versions that this query is tied to
- function
- name
- slo_class
Response
- Success
{
"message": "Performance Profile : <name> created successfully. View all performance profiles at /listPerformanceProfiles",
"httpcode": 201,
"documentationLink": "",
"status": "SUCCESS"
}
- Failure
- Duplicate Performance Profile name.
{ "message": "Performance Profile already exists", "httpcode": 409, "documentationLink": "", "status": "ERROR" } - Mandatory parameters are missing.
{ "message": "Missing mandatory parameters", "httpcode": 400, "documentationLink": "", "status": "ERROR" } - Any unknown exception on server side
{ "message": "Internal Server Error", "httpcode": 500, "documentationLink": "", "status": "ERROR" }
- Duplicate Performance Profile name.
-
You can get the API details here