From e93aeae68262e6dde9bda623b9b466cc35062156 Mon Sep 17 00:00:00 2001 From: Matas Kaminskas Date: Tue, 14 May 2024 15:46:29 +0530 Subject: [PATCH] Add deprecation message for storage and compute optimized constraints (#315) * add deprecation message * update sdk * update docs * update message --- castai/resource_node_template.go | 2 ++ docs/resources/node_template.md | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/castai/resource_node_template.go b/castai/resource_node_template.go index 28b53a97..38bc151d 100644 --- a/castai/resource_node_template.go +++ b/castai/resource_node_template.go @@ -232,6 +232,7 @@ func resourceNodeTemplate() *schema.Resource { Optional: true, Default: false, Description: "Storage optimized instance constraint - will only pick storage optimized nodes if true", + Deprecated: "Storage optimized constraint is deprecated and will be replaced by a new argument in the next major release.", }, FieldNodeTemplateIsGpuOnly: { Type: schema.TypeBool, @@ -244,6 +245,7 @@ func resourceNodeTemplate() *schema.Resource { Optional: true, Default: false, Description: "Compute optimized instance constraint - will only pick compute optimized nodes if true.", + Deprecated: "Compute optimized constraint is deprecated and will be replaced by a new argument in the next major release.", }, FieldNodeTemplateInstanceFamilies: { Type: schema.TypeList, diff --git a/docs/resources/node_template.md b/docs/resources/node_template.md index a99fd125..dc734717 100644 --- a/docs/resources/node_template.md +++ b/docs/resources/node_template.md @@ -44,8 +44,8 @@ CAST AI node template resource to manage node templates Optional: - `architectures` (List of String) List of acceptable instance CPU architectures, the default is amd64. Allowed values: amd64, arm64. +- `compute_optimized` (Boolean, Deprecated) Compute optimized instance constraint - will only pick compute optimized nodes if true. - `azs` (List of String) The list of AZ names to consider for the node template, if empty or not set all AZs are considered. -- `compute_optimized` (Boolean) Compute optimized instance constraint - will only pick compute optimized nodes if true. - `custom_priority` (Block List) (see [below for nested schema](#nestedblock--constraints--custom_priority)) - `dedicated_node_affinity` (Block List) Dedicated node affinity - creates preference for instances to be created on sole tenancy or dedicated nodes. This feature is only available for GCP clusters and sole tenancy nodes with local @@ -68,7 +68,7 @@ Optional: - `spot_diversity_price_increase_limit_percent` (Number) Allowed node configuration price increase when diversifying instance types. E.g. if the value is 10%, then the overall price of diversified instance types can be 10% higher than the price of the optimal configuration. - `spot_interruption_predictions_enabled` (Boolean) Enable/disable spot interruption predictions. - `spot_interruption_predictions_type` (String) Spot interruption predictions type. Can be either "aws-rebalance-recommendations" or "interruption-predictions". -- `storage_optimized` (Boolean) Storage optimized instance constraint - will only pick storage optimized nodes if true +- `storage_optimized` (Boolean, Deprecated) Storage optimized instance constraint - will only pick storage optimized nodes if true - `use_spot_fallbacks` (Boolean) Spot instance fallback constraint - when true, on-demand instances will be created, when spots are unavailable.