auto f = client.UpdateInstance( google::cloud::spanner::UpdateInstanceRequestBuilder(in) .SetDisplayName(new_display_name) .Build()); auto instance = f.get(); if(!instance)throw std::move(instance).status(); std::cout <<"Updated instance ["<< in <<"]\n"; }
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-21 UTC."],[[["This webpage details the `UpdateInstanceRequestBuilder` class in the Google Cloud Spanner C++ library, version 2.17.0, which is a builder for constructing `UpdateInstanceRequest` objects."],["The `UpdateInstanceRequestBuilder` class facilitates the modification of existing instances via its various functions, such as `SetDisplayName`, `SetNodeCount`, `SetProcessingUnits`, and adding labels with `AddLabels` or `SetLabels`."],["There is a list of various versions of this class, with the latest version being 2.37.0-rc, and the content page describing version 2.17.0."],["The class is used with the `google::cloud::spanner::InstanceAdminClient::UpdateInstance()` function to modify instance configurations, as shown in the provided example code."],["`UpdateInstanceRequestBuilder` offers several constructors, including those for creating from a string, an `Instance` object, or a `google::spanner::admin::instance::v1::Instance` object, offering flexibility in how instances are updated."]]],[]]