mirror of
https://github.com/hanzo-cpp/sdk.git
synced 2026-11-20 19:55:32 +00:00
The projection these were generated from was a month old and predated the compute migration, so every one of them described /v1/visor — which the API serves at zero paths now. That is why a hand-written console client and a generated one had drifted the same way at the same time. No /v1/visor path survives here. The word still appears as a source-plane value and inside gvisor and supervisor, which are not this rename.
130 lines
3.5 KiB
C++
130 lines
3.5 KiB
C++
/**
|
|
* Hanzo Cloud API
|
|
* The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
|
|
*
|
|
* The version of the OpenAPI document: v1
|
|
*
|
|
* NOTE: This class is auto generated by OpenAPI-Generator 7.14.0.
|
|
* https://openapi-generator.tech
|
|
* Do not edit the class manually.
|
|
*/
|
|
|
|
/*
|
|
* FleetSpec.h
|
|
*
|
|
*
|
|
*/
|
|
|
|
#ifndef HANZO_MODEL_FleetSpec_H_
|
|
#define HANZO_MODEL_FleetSpec_H_
|
|
|
|
#include <boost/optional.hpp>
|
|
|
|
#include "hanzo/ModelBase.h"
|
|
|
|
#include <cpprest/details/basic_types.h>
|
|
|
|
namespace hanzo {
|
|
namespace model {
|
|
|
|
|
|
|
|
class FleetSpec
|
|
: public ModelBase
|
|
{
|
|
public:
|
|
FleetSpec();
|
|
virtual ~FleetSpec();
|
|
|
|
/////////////////////////////////////////////
|
|
/// ModelBase overrides
|
|
|
|
void validate() override;
|
|
|
|
web::json::value toJson() const override;
|
|
bool fromJson(const web::json::value& json) override;
|
|
|
|
void toMultipart(std::shared_ptr<MultipartFormData> multipart, const utility::string_t& namePrefix) const override;
|
|
bool fromMultiPart(std::shared_ptr<MultipartFormData> multipart, const utility::string_t& namePrefix) override;
|
|
|
|
|
|
/////////////////////////////////////////////
|
|
/// FleetSpec members
|
|
|
|
|
|
/// <summary>
|
|
/// Arch is the CPU architecture, amd64 or arm64, and it is what decides whether a binary built for the fleet will run here. Only the sources that report one carry it (a linked run-target, a BYO worker).
|
|
/// </summary>
|
|
utility::string_t getArch() const;
|
|
bool archIsSet() const;
|
|
void unsetArch();
|
|
void setArch(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// CPUs is logical cores on the unit.
|
|
/// </summary>
|
|
int64_t getCpus() const;
|
|
bool cpusIsSet() const;
|
|
void unsetCpus();
|
|
void setCpus(int64_t value);
|
|
|
|
/// <summary>
|
|
/// GPUModel names the FIRST accelerator (\"NVIDIA GB10\") as the representative of the set; GPUs carries how many. Empty for a cluster, whose cards are counted rather than modelled, and for a unit with none.
|
|
/// </summary>
|
|
utility::string_t getGpuModel() const;
|
|
bool gpuModelIsSet() const;
|
|
void unsetGpuModel();
|
|
void setGpuModel(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// GPUs is how many accelerators the unit has. For a cluster it is the vendor totals summed across every node, so it counts cards, not machines.
|
|
/// </summary>
|
|
int64_t getGpus() const;
|
|
bool gpusIsSet() const;
|
|
void unsetGpus();
|
|
void setGpus(int64_t value);
|
|
|
|
/// <summary>
|
|
/// Memory is total system RAM in BYTES — not GB, and not what is free right now (fleetMetrics carries that). Absent when the source reports no RAM figure.
|
|
/// </summary>
|
|
int64_t getMemory() const;
|
|
bool memoryIsSet() const;
|
|
void unsetMemory();
|
|
void setMemory(int64_t value);
|
|
|
|
/// <summary>
|
|
/// OS is the operating system the unit runs: linux, darwin or windows. Empty when the source does not report one — a cluster row does not.
|
|
/// </summary>
|
|
utility::string_t getOs() const;
|
|
bool osIsSet() const;
|
|
void unsetOs();
|
|
void setOs(const utility::string_t& value);
|
|
|
|
|
|
protected:
|
|
utility::string_t m_Arch;
|
|
bool m_ArchIsSet;
|
|
|
|
int64_t m_Cpus;
|
|
bool m_CpusIsSet;
|
|
|
|
utility::string_t m_GpuModel;
|
|
bool m_GpuModelIsSet;
|
|
|
|
int64_t m_Gpus;
|
|
bool m_GpusIsSet;
|
|
|
|
int64_t m_Memory;
|
|
bool m_MemoryIsSet;
|
|
|
|
utility::string_t m_Os;
|
|
bool m_OsIsSet;
|
|
|
|
};
|
|
|
|
|
|
}
|
|
}
|
|
|
|
#endif /* HANZO_MODEL_FleetSpec_H_ */
|