您能否在 `aws s3` CLI 调用之间保持连接打开?

Can you keep the connection open between invocations of `aws s3` CLI?

SSH a useful opt-in feature 允许您在调用之间重用连接:

ssh host 'echo example' # this opens the connection to host, and leaves it open
ssh host 'echo example2' # this reuses the connection from the previous command

A​​WS S3 命令行界面是否有类似的东西?例如:

aws s3 mv s3://bucketname/example1 s3://bucketname/example2
aws s3 mv s3://bucketname/example3 s3://bucketname/example4

如果第一个命令打开一个连接,并保持打开状态以供第二个命令利用它,那就太好了。当 运行 大量小命令时,这将极大地加快 AWS S3 CLI。

你不能。您始终可以直接使用 boto3、Python SDK,或者实际上是任何受支持语言的任何 SDK。它将允许您保持连接,但 CLI 不支持这种事情。