1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-06 00:07:44 +01:00
unleash.unleash/frontend/src/openapi/models/RequestsPerSecondSegmentedSchema.ts
Christopher Kolstad 23094b016e
feat: first draft of chart for instance traffic in frontend (#2670)
## What
We've already added the backend for this. This is the initial work for
drawing a chart for instance traffic in the frontend. It requires the environment variable `PROMETHEUS_API` set to a valid prometheus-query-language (promql) supported backend, such as Prometheus itself or Victoria Metrics. Besides, at the moment we're hiding this functionality behind the flag `UNLEASH_EXPERIMENTAL_NETWORK_VIEW` which has to be set to true

Co-authored-by: Christopher Kolstad <chriswk@getunleash.ai>
Co-authored-by: Gastón Fournier <gaston@getunleash.ai>
2022-12-15 08:47:07 +00:00

81 lines
2.4 KiB
TypeScript

/* tslint:disable */
/* eslint-disable */
/**
* Unleash API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 4.19.0-beta.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { exists, mapValues } from '../runtime';
import type { RequestsPerSecondSchema } from './RequestsPerSecondSchema';
import {
RequestsPerSecondSchemaFromJSON,
RequestsPerSecondSchemaFromJSONTyped,
RequestsPerSecondSchemaToJSON,
} from './RequestsPerSecondSchema';
/**
*
* @export
* @interface RequestsPerSecondSegmentedSchema
*/
export interface RequestsPerSecondSegmentedSchema {
/**
*
* @type {RequestsPerSecondSchema}
* @memberof RequestsPerSecondSegmentedSchema
*/
clientMetrics?: RequestsPerSecondSchema;
/**
*
* @type {RequestsPerSecondSchema}
* @memberof RequestsPerSecondSegmentedSchema
*/
adminMetrics?: RequestsPerSecondSchema;
}
/**
* Check if a given object implements the RequestsPerSecondSegmentedSchema interface.
*/
export function instanceOfRequestsPerSecondSegmentedSchema(value: object): boolean {
let isInstance = true;
return isInstance;
}
export function RequestsPerSecondSegmentedSchemaFromJSON(json: any): RequestsPerSecondSegmentedSchema {
return RequestsPerSecondSegmentedSchemaFromJSONTyped(json, false);
}
export function RequestsPerSecondSegmentedSchemaFromJSONTyped(json: any, ignoreDiscriminator: boolean): RequestsPerSecondSegmentedSchema {
if ((json === undefined) || (json === null)) {
return json;
}
return {
'clientMetrics': !exists(json, 'clientMetrics') ? undefined : RequestsPerSecondSchemaFromJSON(json['clientMetrics']),
'adminMetrics': !exists(json, 'adminMetrics') ? undefined : RequestsPerSecondSchemaFromJSON(json['adminMetrics']),
};
}
export function RequestsPerSecondSegmentedSchemaToJSON(value?: RequestsPerSecondSegmentedSchema | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
'clientMetrics': RequestsPerSecondSchemaToJSON(value.clientMetrics),
'adminMetrics': RequestsPerSecondSchemaToJSON(value.adminMetrics),
};
}