From ce497fe89ccd9cccd8dc84ccd854427484fdd031 Mon Sep 17 00:00:00 2001 From: "Jonas L." Date: Mon, 5 Aug 2024 15:43:01 +0200 Subject: [PATCH] fix: update `NetworkSubnetType` constants (#499) - Update the properties documentation - Add deprecation warning for long deprecated `NetworkSubnetTypeServer`. --- hcloud/network.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/hcloud/network.go b/hcloud/network.go index 2688c93c..40459eec 100644 --- a/hcloud/network.go +++ b/hcloud/network.go @@ -29,8 +29,15 @@ type NetworkSubnetType string // List of available network subnet types. const ( - NetworkSubnetTypeCloud NetworkSubnetType = "cloud" - NetworkSubnetTypeServer NetworkSubnetType = "server" + // Used to connect cloud servers and load balancers. + NetworkSubnetTypeCloud NetworkSubnetType = "cloud" + // Used to connect cloud servers and load balancers. + // + // Deprecated: Use [NetworkSubnetTypeCloud] instead. + NetworkSubnetTypeServer NetworkSubnetType = "server" + // Used to connect cloud servers and load balancers with dedicated servers. + // + // See https://docs.hetzner.com/cloud/networks/connect-dedi-vswitch/ NetworkSubnetTypeVSwitch NetworkSubnetType = "vswitch" )