<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>ymmt2005</author_name>
  <author_url>https://blog.hatena.ne.jp/ymmt2005/</author_url>
  <blog_title>誰かの役に立てばいいブログ</blog_title>
  <blog_url>https://ymmt.hatenablog.com/</blog_url>
  <categories>
    <anon>go</anon>
    <anon>Go</anon>
  </categories>
  <description>Go 1.7 から本体に入った context パッケージは便利、というより今や必須の道具です。以下のように書くことで、一定時間で処理をキャンセルできたりします。 func slowOperationWithTimeout(ctx context.Context) (Result, error) { ctx, cancel := context.WithTimeout(ctx, 100*time.Millisecond) defer cancel() // releases resources if slowOperation completes before timeout elapses …</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fymmt.hatenablog.com%2Fentry%2F2017%2F05%2F10%2F134147&quot; title=&quot; http.Response を返すような関数は作らないのが賢明 - 誰かの役に立てばいいブログ&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>2017-05-10 13:41:47</published>
  <title> http.Response を返すような関数は作らないのが賢明</title>
  <type>rich</type>
  <url>https://ymmt.hatenablog.com/entry/2017/05/10/134147</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
