MCPcopy Index your code
hub / github.com/aws/aws-cli / _get_future_with_components

Method _get_future_with_components

awscli/s3transfer/manager.py:562–581  ·  view source on GitHub ↗
(self, call_args)

Source from the content-addressed store, hash-verified

560 return transfer_future
561
562 def _get_future_with_components(self, call_args):
563 transfer_id = self._id_counter
564 # Creates a new transfer future along with its components
565 transfer_coordinator = TransferCoordinator(transfer_id=transfer_id)
566 # Track the transfer coordinator for transfers to manage.
567 self._coordinator_controller.add_transfer_coordinator(
568 transfer_coordinator
569 )
570 # Also make sure that the transfer coordinator is removed once
571 # the transfer completes so it does not stick around in memory.
572 transfer_coordinator.add_done_callback(
573 self._coordinator_controller.remove_transfer_coordinator,
574 transfer_coordinator,
575 )
576 components = {
577 'meta': TransferMeta(call_args, transfer_id=transfer_id),
578 'coordinator': transfer_coordinator,
579 }
580 transfer_future = TransferFuture(**components)
581 return transfer_future, components
582
583 def _get_submission_task_main_kwargs(
584 self, transfer_future, extra_main_kwargs

Callers 1

_submit_transferMethod · 0.95

Calls 5

add_done_callbackMethod · 0.95
TransferCoordinatorClass · 0.90
TransferMetaClass · 0.90
TransferFutureClass · 0.90

Tested by

no test coverage detected