<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>kiras7</author_name>
  <author_url>https://blog.hatena.ne.jp/kiras7/</author_url>
  <blog_title>My Dev : ただの開発・実験等のメモ</blog_title>
  <blog_url>https://kiras7.hatenablog.com/</blog_url>
  <categories>
    <anon>Python</anon>
    <anon>Flask</anon>
    <anon>Locust</anon>
  </categories>
  <description>FlaskにはWebサイト・アプリ全体に適用できるキャッシュ機構としてFlask-Cachingがありますが、最近よく見かけるAstroなどの静的サイト生成みたいに、最初から静的HTMLを生成しておいてFlask側で読み込むだけにした場合、Flask-Cachingを有効にしたWebアプリと比べて、どのくらい処理が高速になるか、簡単に実験してみました。 準備: まずはFlaskアプリで自動生成しているWebページをhtmlファイルとして取得します。 テスト用に1～100までの連番ページを以下のコードでゲットしていきます。 import requests import os base_url =…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fkiras7.hatenablog.com%2Fentry%2F2024%2F08%2F04%2F121058&quot; title=&quot;メモ_Flask-Cachingと簡易静的サイト配信の比較 - My Dev : ただの開発・実験等のメモ&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>https://cdn-ak.f.st-hatena.com/images/fotolife/k/kiras7/20240804/20240804115726.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2024-08-04 12:10:58</published>
  <title>メモ_Flask-Cachingと簡易静的サイト配信の比較</title>
  <type>rich</type>
  <url>https://kiras7.hatenablog.com/entry/2024/08/04/121058</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
