<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>cateiru</author_name>
  <author_url>https://blog.hatena.ne.jp/cateiru/</author_url>
  <blog_title>cateiru のブログ</blog_title>
  <blog_url>https://blog.cateiru.com/</blog_url>
  <categories>
    <anon>技術</anon>
  </categories>
  <description>SQLBoilerでは、Debug Loggingという機能があり、これを有効にするとSQLクエリが実行されるたびに標準出力されます。 boil.DebugMode = true このデバッグログの出力先はデフォルトでos.Stdoutになっていますがboil.DebugWriterを使用することで自由に上書きすることができます。 この記事では、Goのロギングライブラリとして有名なzapでこのログを出力するようにします。 TL;DR stdOutLogger, err := zap.NewStdLogAt(L, zapcore.DebugLevel) if err != nil { panic…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.cateiru.com%2Fentry%2F2023%2F06%2F10%2F015011&quot; title=&quot;【備忘録】SQLBoilerのデバッグログをzap経由で出力する - cateiru のブログ&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/c/cateiru/20230610/20230610014837.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2023-06-10 01:50:11</published>
  <title>【備忘録】SQLBoilerのデバッグログをzap経由で出力する</title>
  <type>rich</type>
  <url>https://blog.cateiru.com/entry/2023/06/10/015011</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
