updateGlossary method

Future<UpdateGlossaryResponse> updateGlossary({
  1. required String identifier,
  2. String? clientToken,
  3. String? description,
  4. String? name,
})

Updates a business glossary in Glue Data Catalog.

May throw AccessDeniedException. May throw AlreadyExistsException. May throw ConcurrentModificationException. May throw EntityNotFoundException. May throw InternalServiceException. May throw InvalidInputException. May throw ThrottlingException.

Parameter identifier : The unique identifier of the glossary to update.

Parameter clientToken : A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.

Parameter description : The updated description of the glossary.

Parameter name : The updated name of the glossary.

Implementation

Future<UpdateGlossaryResponse> updateGlossary({
  required String identifier,
  String? clientToken,
  String? description,
  String? name,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AWSGlue.UpdateGlossary'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'Identifier': identifier,
      'ClientToken': clientToken ?? _s.generateIdempotencyToken(),
      if (description != null) 'Description': description,
      if (name != null) 'Name': name,
    },
  );

  return UpdateGlossaryResponse.fromJson(jsonResponse.body);
}