From 7b3a421839a4ea4d306f517f2a92f2df6123156f Mon Sep 17 00:00:00 2001 From: aperdizs Date: Tue, 5 Sep 2023 12:10:06 +0200 Subject: [PATCH] API-711 add boostIndex to datasets configuration --- gfw/api/types.go | 1 + gfw/resource_dataset.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/gfw/api/types.go b/gfw/api/types.go index 8baddc6..54381d2 100644 --- a/gfw/api/types.go +++ b/gfw/api/types.go @@ -116,6 +116,7 @@ type DatasetConfiguration struct { Intervals []string `json:"intervals,omitempty"` NumLayers int `json:"numLayers,omitempty"` Index string `json:"index,omitempty"` + IndexBoost float64 `json:"indexBoost,omitempty"` Version int `json:"version,omitempty"` Translate bool `json:"translate,omitempty"` Documentation *DatasetDocumentation `json:"documentation,omitempty"` diff --git a/gfw/resource_dataset.go b/gfw/resource_dataset.go index c1e2c2d..1f8ef02 100644 --- a/gfw/resource_dataset.go +++ b/gfw/resource_dataset.go @@ -611,6 +611,7 @@ func schemaToDatasetConfiguration(schema map[string]interface{}) api.DatasetConf Bucket: schema["bucket"].(string), Folder: schema["folder"].(string), Index: schema["index"].(string), + IndexBoost: schema["indexBoost"].(float64), GeometryType: schema["geometry_type"].(string), PropertyToInclude: schema["property_to_include"].(string), FilePath: schema["file_path"].(string), @@ -794,6 +795,7 @@ func flattenDatasetConfiguration(config api.DatasetConfiguration) interface{} { a["intervals"] = config.Intervals a["num_layers"] = config.NumLayers a["index"] = config.Index + a["indexBoost"] = config.IndexBoost a["version"] = config.Version a["translate"] = config.Translate a["num_bytes"] = config.NumBytes