mirror of
https://github.com/hanzoai/swift-sdk.git
synced 2026-10-30 18:20:19 +00:00
The projection these were generated from predated the compute migration, so they described /v1/visor — which the API serves at zero paths now. No /v1/visor path survives here.
43 lines
1.4 KiB
Swift
43 lines
1.4 KiB
Swift
//
|
|
// O11yMetricsResponseSummary.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
/** Summary totals the window in one object, so a tile does not have to sum the series to render. errorRate is a RATIO of the window's requests, not a percentage, and p95Ms is over the window rather than the worst bucket. */
|
|
public struct O11yMetricsResponseSummary: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
public var errorRate: Double?
|
|
public var errors: Int64?
|
|
public var p95Ms: Double?
|
|
public var requests: Int64?
|
|
|
|
public init(errorRate: Double? = nil, errors: Int64? = nil, p95Ms: Double? = nil, requests: Int64? = nil) {
|
|
self.errorRate = errorRate
|
|
self.errors = errors
|
|
self.p95Ms = p95Ms
|
|
self.requests = requests
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case errorRate
|
|
case errors
|
|
case p95Ms
|
|
case requests
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(errorRate, forKey: .errorRate)
|
|
try container.encodeIfPresent(errors, forKey: .errors)
|
|
try container.encodeIfPresent(p95Ms, forKey: .p95Ms)
|
|
try container.encodeIfPresent(requests, forKey: .requests)
|
|
}
|
|
}
|
|
|