<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>muryoimpl</author_name>
  <author_url>https://blog.hatena.ne.jp/muryoimpl/</author_url>
  <blog_title>ESM アジャイル事業部 開発者ブログ</blog_title>
  <blog_url>https://blog.agile.esm.co.jp/</blog_url>
  <categories>
  </categories>
  <description>どうも muryoimpl です。 先日 ActiveRecord::LobSubscriber を使ってログ出力に手を加えたので、その意図と実装例をご紹介したいと思います。 ActiveRecord::LogSubscriber とは ActiveRecord で発行されたクエリをログに出力する役割を担ったクラスです。ログレベルを debug とした場合に、ActiveRecord のクエリを発行した際に実行時間や SQL 文が出力されますが、それはこのクラスが活躍しているおかげです。 ActiveSupport::Notifications の仕組みを使ってログに記録する ActiveSu…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.agile.esm.co.jp%2Fentry%2Fintroduce-activerecord-logsubscriber&quot; title=&quot;ActiveRecord::LogSubscriber を使って追加でログを出力する - ESM アジャイル事業部 開発者ブログ&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.user.blog.st-hatena.com/default_entry_og_image/118345113/1514250491570739</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2021-04-30 12:00:00</published>
  <title>ActiveRecord::LogSubscriber を使って追加でログを出力する</title>
  <type>rich</type>
  <url>https://blog.agile.esm.co.jp/entry/introduce-activerecord-logsubscriber</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
