<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>anton0825</author_name>
  <author_url>https://blog.hatena.ne.jp/anton0825/</author_url>
  <blog_title>日々精進</blog_title>
  <blog_url>https://anton0825.hatenablog.com/</blog_url>
  <categories>
    <anon>IT</anon>
  </categories>
  <description>boto3のS3.Client.download_fileメソッドを使って大量のファイルをダウンロードすると、aws cliでダウンロードするよりかなり遅い。 boto3.amazonaws.com 理由はdownload_fileは同期処理なのに対してaws cliはマルチスレッド（ちゃんと調べてないのでマルチプロセスかも）で並列実行しているため。アップロードも同様。 以下を参考に、transfer_managerを使って並列実行するよう実装するとアップロード・ダウンロードが7倍程度早くなった。 stackoverflow.com</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fanton0825.hatenablog.com%2Fentry%2F2022%2F04%2F19%2F144621&quot; title=&quot;boto3でS3からファイルをダウンロード・アップロードするのを高速化する - 日々精進&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2022-04-19 14:46:21</published>
  <title>boto3でS3からファイルをダウンロード・アップロードするのを高速化する</title>
  <type>rich</type>
  <url>https://anton0825.hatenablog.com/entry/2022/04/19/144621</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
