Skip to content

update_smb_file_share_visibility

update_smb_file_share_visibility(
    gateway_arn: GatewayARN,
    file_shares_visible: Boolean,
    *,
    config_overrides: Optional[StorageGatewayClientConfig] = None,
) -> UpdateSMBFileShareVisibilityOutput

Controls whether the shares on an S3 File Gateway are visible in a net view or browse list. The operation is only supported for S3 File Gateways.

Parameters:

  • file_shares_visible (Boolean) –

    The shares on this gateway appear when listing shares.

Raises:

  • InternalServerError –

    An internal server error has occurred during the request. For more information, see the error and message fields.

  • InvalidGatewayRequestException –

    An exception occurred because an invalid gateway request was issued to the service. For more information, see the error and message fields.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_storage_gateway/_services/storage_gateway.py
def update_smb_file_share_visibility(
    self,
    gateway_arn: "capo_storage_gateway.types.gateway_arn.GatewayARN",
    file_shares_visible: "capo_storage_gateway.types.boolean.Boolean",
    *,
    config_overrides: Optional[StorageGatewayClientConfig] = None,
) -> "capo_storage_gateway.types.update_smb_file_share_visibility_output.UpdateSMBFileShareVisibilityOutput":
    """<p>Controls whether the shares on an S3 File Gateway are visible in a net view or browse list. The operation is only supported for S3 File Gateways.</p>

    Args:
        file_shares_visible: <p>The shares on this gateway appear when listing shares.</p>

    Raises:
        capo_storage_gateway.errors.internal_server_error.InternalServerError: <p>An internal server error has occurred during the request. For more information, see the error and message fields.</p>
        capo_storage_gateway.errors.invalid_gateway_request_exception.InvalidGatewayRequestException: <p>An exception occurred because an invalid gateway request was issued to the service. For more information, see the error and message fields.</p>
        capo_storage_gateway.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_storage_gateway.types.update_smb_file_share_visibility_input.UpdateSMBFileShareVisibilityInput]",
    ) -> OperationResponse[
        "capo_storage_gateway.types.update_smb_file_share_visibility_output.UpdateSMBFileShareVisibilityOutput"
    ]:
        import capo_storage_gateway._operations.storage_gateway_20130630.update_smb_file_share_visibility

        output, http_response = (
            capo_storage_gateway._operations.storage_gateway_20130630.update_smb_file_share_visibility.update_smb_file_share_visibility(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UpdateSMBFileShareVisibility")
    )
    input_: capo_storage_gateway.types.update_smb_file_share_visibility_input.UpdateSMBFileShareVisibilityInput = {
        "gateway_arn": gateway_arn,
        "file_shares_visible": file_shares_visible,
    }

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output