- Created T026-practical-test task.yaml for MVP smoke testing - Added k8shost-server to flake.nix (packages, apps, overlays) - Staged all workspace directories for nix flake build - Updated flake.nix shellHook to include k8shost Resolves: T026.S1 blocker (R8 - nix submodule visibility)
477 lines
11 KiB
Protocol Buffer
477 lines
11 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package fiberlb.v1;
|
|
|
|
option java_multiple_files = true;
|
|
option java_package = "cloud.fiberlb.v1";
|
|
|
|
// ============================================================================
|
|
// Load Balancer Service
|
|
// ============================================================================
|
|
|
|
service LoadBalancerService {
|
|
// Create a new load balancer
|
|
rpc CreateLoadBalancer(CreateLoadBalancerRequest) returns (CreateLoadBalancerResponse);
|
|
// Get a load balancer by ID
|
|
rpc GetLoadBalancer(GetLoadBalancerRequest) returns (GetLoadBalancerResponse);
|
|
// List load balancers
|
|
rpc ListLoadBalancers(ListLoadBalancersRequest) returns (ListLoadBalancersResponse);
|
|
// Update a load balancer
|
|
rpc UpdateLoadBalancer(UpdateLoadBalancerRequest) returns (UpdateLoadBalancerResponse);
|
|
// Delete a load balancer
|
|
rpc DeleteLoadBalancer(DeleteLoadBalancerRequest) returns (DeleteLoadBalancerResponse);
|
|
}
|
|
|
|
message LoadBalancer {
|
|
string id = 1;
|
|
string name = 2;
|
|
string org_id = 3;
|
|
string project_id = 4;
|
|
string description = 5;
|
|
LoadBalancerStatus status = 6;
|
|
string vip_address = 7;
|
|
uint64 created_at = 8;
|
|
uint64 updated_at = 9;
|
|
}
|
|
|
|
enum LoadBalancerStatus {
|
|
LOAD_BALANCER_STATUS_UNSPECIFIED = 0;
|
|
LOAD_BALANCER_STATUS_PROVISIONING = 1;
|
|
LOAD_BALANCER_STATUS_ACTIVE = 2;
|
|
LOAD_BALANCER_STATUS_UPDATING = 3;
|
|
LOAD_BALANCER_STATUS_ERROR = 4;
|
|
LOAD_BALANCER_STATUS_DELETING = 5;
|
|
}
|
|
|
|
message CreateLoadBalancerRequest {
|
|
string name = 1;
|
|
string org_id = 2;
|
|
string project_id = 3;
|
|
string description = 4;
|
|
}
|
|
|
|
message CreateLoadBalancerResponse {
|
|
LoadBalancer loadbalancer = 1;
|
|
}
|
|
|
|
message GetLoadBalancerRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message GetLoadBalancerResponse {
|
|
LoadBalancer loadbalancer = 1;
|
|
}
|
|
|
|
message ListLoadBalancersRequest {
|
|
string org_id = 1;
|
|
string project_id = 2;
|
|
int32 page_size = 3;
|
|
string page_token = 4;
|
|
}
|
|
|
|
message ListLoadBalancersResponse {
|
|
repeated LoadBalancer loadbalancers = 1;
|
|
string next_page_token = 2;
|
|
}
|
|
|
|
message UpdateLoadBalancerRequest {
|
|
string id = 1;
|
|
string name = 2;
|
|
string description = 3;
|
|
}
|
|
|
|
message UpdateLoadBalancerResponse {
|
|
LoadBalancer loadbalancer = 1;
|
|
}
|
|
|
|
message DeleteLoadBalancerRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message DeleteLoadBalancerResponse {}
|
|
|
|
// ============================================================================
|
|
// Pool Service
|
|
// ============================================================================
|
|
|
|
service PoolService {
|
|
rpc CreatePool(CreatePoolRequest) returns (CreatePoolResponse);
|
|
rpc GetPool(GetPoolRequest) returns (GetPoolResponse);
|
|
rpc ListPools(ListPoolsRequest) returns (ListPoolsResponse);
|
|
rpc UpdatePool(UpdatePoolRequest) returns (UpdatePoolResponse);
|
|
rpc DeletePool(DeletePoolRequest) returns (DeletePoolResponse);
|
|
}
|
|
|
|
message Pool {
|
|
string id = 1;
|
|
string name = 2;
|
|
string loadbalancer_id = 3;
|
|
PoolAlgorithm algorithm = 4;
|
|
PoolProtocol protocol = 5;
|
|
SessionPersistence session_persistence = 6;
|
|
uint64 created_at = 7;
|
|
uint64 updated_at = 8;
|
|
}
|
|
|
|
enum PoolAlgorithm {
|
|
POOL_ALGORITHM_UNSPECIFIED = 0;
|
|
POOL_ALGORITHM_ROUND_ROBIN = 1;
|
|
POOL_ALGORITHM_LEAST_CONNECTIONS = 2;
|
|
POOL_ALGORITHM_IP_HASH = 3;
|
|
POOL_ALGORITHM_WEIGHTED_ROUND_ROBIN = 4;
|
|
POOL_ALGORITHM_RANDOM = 5;
|
|
}
|
|
|
|
enum PoolProtocol {
|
|
POOL_PROTOCOL_UNSPECIFIED = 0;
|
|
POOL_PROTOCOL_TCP = 1;
|
|
POOL_PROTOCOL_UDP = 2;
|
|
POOL_PROTOCOL_HTTP = 3;
|
|
POOL_PROTOCOL_HTTPS = 4;
|
|
}
|
|
|
|
message SessionPersistence {
|
|
PersistenceType type = 1;
|
|
string cookie_name = 2;
|
|
uint32 timeout_seconds = 3;
|
|
}
|
|
|
|
enum PersistenceType {
|
|
PERSISTENCE_TYPE_UNSPECIFIED = 0;
|
|
PERSISTENCE_TYPE_SOURCE_IP = 1;
|
|
PERSISTENCE_TYPE_COOKIE = 2;
|
|
PERSISTENCE_TYPE_APP_COOKIE = 3;
|
|
}
|
|
|
|
message CreatePoolRequest {
|
|
string name = 1;
|
|
string loadbalancer_id = 2;
|
|
PoolAlgorithm algorithm = 3;
|
|
PoolProtocol protocol = 4;
|
|
SessionPersistence session_persistence = 5;
|
|
}
|
|
|
|
message CreatePoolResponse {
|
|
Pool pool = 1;
|
|
}
|
|
|
|
message GetPoolRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message GetPoolResponse {
|
|
Pool pool = 1;
|
|
}
|
|
|
|
message ListPoolsRequest {
|
|
string loadbalancer_id = 1;
|
|
int32 page_size = 2;
|
|
string page_token = 3;
|
|
}
|
|
|
|
message ListPoolsResponse {
|
|
repeated Pool pools = 1;
|
|
string next_page_token = 2;
|
|
}
|
|
|
|
message UpdatePoolRequest {
|
|
string id = 1;
|
|
string name = 2;
|
|
PoolAlgorithm algorithm = 3;
|
|
SessionPersistence session_persistence = 4;
|
|
}
|
|
|
|
message UpdatePoolResponse {
|
|
Pool pool = 1;
|
|
}
|
|
|
|
message DeletePoolRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message DeletePoolResponse {}
|
|
|
|
// ============================================================================
|
|
// Backend Service
|
|
// ============================================================================
|
|
|
|
service BackendService {
|
|
rpc CreateBackend(CreateBackendRequest) returns (CreateBackendResponse);
|
|
rpc GetBackend(GetBackendRequest) returns (GetBackendResponse);
|
|
rpc ListBackends(ListBackendsRequest) returns (ListBackendsResponse);
|
|
rpc UpdateBackend(UpdateBackendRequest) returns (UpdateBackendResponse);
|
|
rpc DeleteBackend(DeleteBackendRequest) returns (DeleteBackendResponse);
|
|
}
|
|
|
|
message Backend {
|
|
string id = 1;
|
|
string name = 2;
|
|
string pool_id = 3;
|
|
string address = 4;
|
|
uint32 port = 5;
|
|
uint32 weight = 6;
|
|
BackendAdminState admin_state = 7;
|
|
BackendStatus status = 8;
|
|
uint64 created_at = 9;
|
|
uint64 updated_at = 10;
|
|
}
|
|
|
|
enum BackendAdminState {
|
|
BACKEND_ADMIN_STATE_UNSPECIFIED = 0;
|
|
BACKEND_ADMIN_STATE_ENABLED = 1;
|
|
BACKEND_ADMIN_STATE_DISABLED = 2;
|
|
BACKEND_ADMIN_STATE_DRAIN = 3;
|
|
}
|
|
|
|
enum BackendStatus {
|
|
BACKEND_STATUS_UNSPECIFIED = 0;
|
|
BACKEND_STATUS_ONLINE = 1;
|
|
BACKEND_STATUS_OFFLINE = 2;
|
|
BACKEND_STATUS_CHECKING = 3;
|
|
BACKEND_STATUS_UNKNOWN = 4;
|
|
}
|
|
|
|
message CreateBackendRequest {
|
|
string name = 1;
|
|
string pool_id = 2;
|
|
string address = 3;
|
|
uint32 port = 4;
|
|
uint32 weight = 5;
|
|
}
|
|
|
|
message CreateBackendResponse {
|
|
Backend backend = 1;
|
|
}
|
|
|
|
message GetBackendRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message GetBackendResponse {
|
|
Backend backend = 1;
|
|
}
|
|
|
|
message ListBackendsRequest {
|
|
string pool_id = 1;
|
|
int32 page_size = 2;
|
|
string page_token = 3;
|
|
}
|
|
|
|
message ListBackendsResponse {
|
|
repeated Backend backends = 1;
|
|
string next_page_token = 2;
|
|
}
|
|
|
|
message UpdateBackendRequest {
|
|
string id = 1;
|
|
string name = 2;
|
|
uint32 weight = 3;
|
|
BackendAdminState admin_state = 4;
|
|
}
|
|
|
|
message UpdateBackendResponse {
|
|
Backend backend = 1;
|
|
}
|
|
|
|
message DeleteBackendRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message DeleteBackendResponse {}
|
|
|
|
// ============================================================================
|
|
// Listener Service
|
|
// ============================================================================
|
|
|
|
service ListenerService {
|
|
rpc CreateListener(CreateListenerRequest) returns (CreateListenerResponse);
|
|
rpc GetListener(GetListenerRequest) returns (GetListenerResponse);
|
|
rpc ListListeners(ListListenersRequest) returns (ListListenersResponse);
|
|
rpc UpdateListener(UpdateListenerRequest) returns (UpdateListenerResponse);
|
|
rpc DeleteListener(DeleteListenerRequest) returns (DeleteListenerResponse);
|
|
}
|
|
|
|
message Listener {
|
|
string id = 1;
|
|
string name = 2;
|
|
string loadbalancer_id = 3;
|
|
ListenerProtocol protocol = 4;
|
|
uint32 port = 5;
|
|
string default_pool_id = 6;
|
|
TlsConfig tls_config = 7;
|
|
uint32 connection_limit = 8;
|
|
bool enabled = 9;
|
|
uint64 created_at = 10;
|
|
uint64 updated_at = 11;
|
|
}
|
|
|
|
enum ListenerProtocol {
|
|
LISTENER_PROTOCOL_UNSPECIFIED = 0;
|
|
LISTENER_PROTOCOL_TCP = 1;
|
|
LISTENER_PROTOCOL_UDP = 2;
|
|
LISTENER_PROTOCOL_HTTP = 3;
|
|
LISTENER_PROTOCOL_HTTPS = 4;
|
|
LISTENER_PROTOCOL_TERMINATED_HTTPS = 5;
|
|
}
|
|
|
|
message TlsConfig {
|
|
string certificate_id = 1;
|
|
TlsVersion min_version = 2;
|
|
repeated string cipher_suites = 3;
|
|
}
|
|
|
|
enum TlsVersion {
|
|
TLS_VERSION_UNSPECIFIED = 0;
|
|
TLS_VERSION_TLS_1_2 = 1;
|
|
TLS_VERSION_TLS_1_3 = 2;
|
|
}
|
|
|
|
message CreateListenerRequest {
|
|
string name = 1;
|
|
string loadbalancer_id = 2;
|
|
ListenerProtocol protocol = 3;
|
|
uint32 port = 4;
|
|
string default_pool_id = 5;
|
|
TlsConfig tls_config = 6;
|
|
uint32 connection_limit = 7;
|
|
}
|
|
|
|
message CreateListenerResponse {
|
|
Listener listener = 1;
|
|
}
|
|
|
|
message GetListenerRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message GetListenerResponse {
|
|
Listener listener = 1;
|
|
}
|
|
|
|
message ListListenersRequest {
|
|
string loadbalancer_id = 1;
|
|
int32 page_size = 2;
|
|
string page_token = 3;
|
|
}
|
|
|
|
message ListListenersResponse {
|
|
repeated Listener listeners = 1;
|
|
string next_page_token = 2;
|
|
}
|
|
|
|
message UpdateListenerRequest {
|
|
string id = 1;
|
|
string name = 2;
|
|
string default_pool_id = 3;
|
|
TlsConfig tls_config = 4;
|
|
uint32 connection_limit = 5;
|
|
bool enabled = 6;
|
|
}
|
|
|
|
message UpdateListenerResponse {
|
|
Listener listener = 1;
|
|
}
|
|
|
|
message DeleteListenerRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message DeleteListenerResponse {}
|
|
|
|
// ============================================================================
|
|
// Health Check Service
|
|
// ============================================================================
|
|
|
|
service HealthCheckService {
|
|
rpc CreateHealthCheck(CreateHealthCheckRequest) returns (CreateHealthCheckResponse);
|
|
rpc GetHealthCheck(GetHealthCheckRequest) returns (GetHealthCheckResponse);
|
|
rpc ListHealthChecks(ListHealthChecksRequest) returns (ListHealthChecksResponse);
|
|
rpc UpdateHealthCheck(UpdateHealthCheckRequest) returns (UpdateHealthCheckResponse);
|
|
rpc DeleteHealthCheck(DeleteHealthCheckRequest) returns (DeleteHealthCheckResponse);
|
|
}
|
|
|
|
message HealthCheck {
|
|
string id = 1;
|
|
string name = 2;
|
|
string pool_id = 3;
|
|
HealthCheckType type = 4;
|
|
uint32 interval_seconds = 5;
|
|
uint32 timeout_seconds = 6;
|
|
uint32 healthy_threshold = 7;
|
|
uint32 unhealthy_threshold = 8;
|
|
HttpHealthConfig http_config = 9;
|
|
bool enabled = 10;
|
|
uint64 created_at = 11;
|
|
uint64 updated_at = 12;
|
|
}
|
|
|
|
enum HealthCheckType {
|
|
HEALTH_CHECK_TYPE_UNSPECIFIED = 0;
|
|
HEALTH_CHECK_TYPE_TCP = 1;
|
|
HEALTH_CHECK_TYPE_HTTP = 2;
|
|
HEALTH_CHECK_TYPE_HTTPS = 3;
|
|
HEALTH_CHECK_TYPE_UDP = 4;
|
|
HEALTH_CHECK_TYPE_PING = 5;
|
|
}
|
|
|
|
message HttpHealthConfig {
|
|
string method = 1;
|
|
string path = 2;
|
|
repeated uint32 expected_codes = 3;
|
|
string host = 4;
|
|
}
|
|
|
|
message CreateHealthCheckRequest {
|
|
string name = 1;
|
|
string pool_id = 2;
|
|
HealthCheckType type = 3;
|
|
uint32 interval_seconds = 4;
|
|
uint32 timeout_seconds = 5;
|
|
uint32 healthy_threshold = 6;
|
|
uint32 unhealthy_threshold = 7;
|
|
HttpHealthConfig http_config = 8;
|
|
}
|
|
|
|
message CreateHealthCheckResponse {
|
|
HealthCheck health_check = 1;
|
|
}
|
|
|
|
message GetHealthCheckRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message GetHealthCheckResponse {
|
|
HealthCheck health_check = 1;
|
|
}
|
|
|
|
message ListHealthChecksRequest {
|
|
string pool_id = 1;
|
|
int32 page_size = 2;
|
|
string page_token = 3;
|
|
}
|
|
|
|
message ListHealthChecksResponse {
|
|
repeated HealthCheck health_checks = 1;
|
|
string next_page_token = 2;
|
|
}
|
|
|
|
message UpdateHealthCheckRequest {
|
|
string id = 1;
|
|
string name = 2;
|
|
uint32 interval_seconds = 3;
|
|
uint32 timeout_seconds = 4;
|
|
uint32 healthy_threshold = 5;
|
|
uint32 unhealthy_threshold = 6;
|
|
HttpHealthConfig http_config = 7;
|
|
bool enabled = 8;
|
|
}
|
|
|
|
message UpdateHealthCheckResponse {
|
|
HealthCheck health_check = 1;
|
|
}
|
|
|
|
message DeleteHealthCheckRequest {
|
|
string id = 1;
|
|
}
|
|
|
|
message DeleteHealthCheckResponse {}
|