class_docstr: Hook for Google Cloud Dataproc Metastore APIs.
class_docstr_tok: ["Hook","for","Google","Cloud","Dataproc","Metastore","APIs","."]
docstr: Updates the parameters of a single service.
  
  :param project_id: Required. The ID of the Google Cloud project that the service belongs to.
  :param region: Required. The ID of the Google Cloud region that the service belongs to.
  :param service_id:  Required. The ID of the metastore service, which is used as the final component of
      the metastore service's name. This value must be between 2 and 63 characters long inclusive, begin
      with a letter, end with a letter or number, and consist of alphanumeric ASCII characters or
      hyphens.
  
      This corresponds to the ``service_id`` field on the ``request`` instance; if ``request`` is
      provided, this should not be set.
  :param service:  Required. The metastore service to update. The server only merges fields in the
      service if they are specified in ``update_mask``.
  
      The metastore service's ``name`` field is used to identify the metastore service to be updated.
  
      This corresponds to the ``service`` field on the ``request`` instance; if ``request`` is provided,
      this should not be set.
  :param update_mask:  Required. A field mask used to specify the fields to be overwritten in the
      metastore service resource by the update. Fields specified in the ``update_mask`` are relative to
      the resource (not to the full request). A field is overwritten if it is in the mask.
  
      This corresponds to the ``update_mask`` field on the ``request`` instance; if ``request`` is
      provided, this should not be set.
  :param request_id: Optional. A unique id used to identify the request.
  :param retry: Designation of what errors, if any, should be retried.
  :param timeout: The timeout for this request.
  :param metadata: Strings which should be sent along with the request as metadata.
docstr_tok: ["Updates","the","parameters","of","a","single","service",".",":","param","project_id",":","Required",".","The","ID","of","the","Google","Cloud","project","that","the","service","belongs","to",".",":","param","region",":","Required",".","The","ID","of","the","Google","Cloud","region","that","the","service","belongs","to",".",":","param","service_id",":","Required",".","The","ID","of","the","metastore","service",",","which","is","used","as","the","final","component","of","the","metastore","service","'s","name",".","This","value","must","be","between","2","and","63","characters","long","inclusive",",","begin","with","a","letter",",","end","with","a","letter","or","number",",","and","consist","of","alphanumeric","ASCII","characters","or","hyphens",".","This","corresponds","to","the","``","service_id","``","field","on","the","``","request","``","instance",";","if","``","request","``","is","provided",",","this","should","not","be","set",".",":","param","service",":","Required",".","The","metastore","service","to","update",".","The","server","only","merges","fields","in","the","service","if","they","are","specified","in","``","update_mask","``",".","The","metastore","service","'s","``","name","``","field","is","used","to","identify","the","metastore","service","to","be","updated",".","This","corresponds","to","the","``","service","``","field","on","the","``","request","``","instance",";","if","``","request","``","is","provided",",","this","should","not","be","set",".",":","param","update_mask",":","Required",".","A","field","mask","used","to","specify","the","fields","to","be","overwritten","in","the","metastore","service","resource","by","the","update",".","Fields","specified","in","the","``","update_mask","``","are","relative","to","the","resource","(","not","to","the","full","request",")",".","A","field","is","overwritten","if","it","is","in","the","mask",".","This","corresponds","to","the","``","update_mask","``","field","on","the","``","request","``","instance",";","if","``","request","``","is","provided",",","this","should","not","be","set",".",":","param","request_id",":","Optional",".","A","unique","id","used","to","identify","the","request",".",":","param","retry",":","Designation","of","what","errors",",","if","any",",","should","be","retried",".",":","param","timeout",":","The","timeout","for","this","request",".",":","param","metadata",":","Strings","which","should","be","sent","along","with","the","request","as","metadata","."]
code: def update_service(
      self,
      project_id: str,
      region: str,
      service_id: str,
      service: dict | Service,
      update_mask: FieldMask,
      request_id: str | None = None,
      retry: Retry | _MethodDefault = DEFAULT,
      timeout: float | None = None,
      metadata: Sequence[tuple[str, str]] = (),
  ):
      """
      Updates the parameters of a single service.
  
      :param project_id: Required. The ID of the Google Cloud project that the service belongs to.
      :param region: Required. The ID of the Google Cloud region that the service belongs to.
      :param service_id:  Required. The ID of the metastore service, which is used as the final component of
          the metastore service's name. This value must be between 2 and 63 characters long inclusive, begin
          with a letter, end with a letter or number, and consist of alphanumeric ASCII characters or
          hyphens.
  
          This corresponds to the ``service_id`` field on the ``request`` instance; if ``request`` is
          provided, this should not be set.
      :param service:  Required. The metastore service to update. The server only merges fields in the
          service if they are specified in ``update_mask``.
  
          The metastore service's ``name`` field is used to identify the metastore service to be updated.
  
          This corresponds to the ``service`` field on the ``request`` instance; if ``request`` is provided,
          this should not be set.
      :param update_mask:  Required. A field mask used to specify the fields to be overwritten in the
          metastore service resource by the update. Fields specified in the ``update_mask`` are relative to
          the resource (not to the full request). A field is overwritten if it is in the mask.
  
          This corresponds to the ``update_mask`` field on the ``request`` instance; if ``request`` is
          provided, this should not be set.
      :param request_id: Optional. A unique id used to identify the request.
      :param retry: Designation of what errors, if any, should be retried.
      :param timeout: The timeout for this request.
      :param metadata: Strings which should be sent along with the request as metadata.
      """
      client = self.get_dataproc_metastore_client()
  
      service_name = f"projects/{project_id}/locations/{region}/services/{service_id}"
  
      service["name"] = service_name
  
      result = client.update_service(
          request={
              "service": service,
              "update_mask": update_mask,
              "request_id": request_id,
          },
          retry=retry,
          timeout=timeout,
          metadata=metadata,
      )
      return result
  
imports: from __future__ import annotations
  from typing import TYPE_CHECKING, Any, Sequence
  from google.api_core.client_options import ClientOptions
  from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
  from google.cloud.metastore_v1 import DataprocMetastoreClient
  from airflow.exceptions import AirflowException
  from airflow.providers.google.common.consts import CLIENT_INFO
  from airflow.providers.google.common.hooks.base_google import GoogleBaseHook
label_desc: Use image node_id 15 for calling the DataprocMetastoreHook obj's underlying member method code with example usage: obj.update_service(project_id, region, service_id, service, update_mask, request_id, retry, timeout, metadata) and returns: result