{"id":14809,"date":"2018-06-08T19:35:53","date_gmt":"2018-06-08T10:35:53","guid":{"rendered":"http:\/\/www.skyarch.net\/blog\/?p=14809"},"modified":"2018-06-12T13:29:43","modified_gmt":"2018-06-12T04:29:43","slug":"lambda%e3%81%ae%e5%90%8c%e6%99%82%e5%ae%9f%e8%a1%8c%e6%95%b0%e8%a8%ad%e5%ae%9a%e3%81%ab%e3%81%a6%e5%a4%9a%e9%87%8d%e8%b5%b7%e5%8b%95%e9%98%b2%e6%ad%a2%e3%82%92%e8%a1%8c%e3%81%88%e3%82%8b%e3%81%8b","status":"publish","type":"post","link":"https:\/\/www.skyarch.net\/blog\/lambda%e3%81%ae%e5%90%8c%e6%99%82%e5%ae%9f%e8%a1%8c%e6%95%b0%e8%a8%ad%e5%ae%9a%e3%81%ab%e3%81%a6%e5%a4%9a%e9%87%8d%e8%b5%b7%e5%8b%95%e9%98%b2%e6%ad%a2%e3%82%92%e8%a1%8c%e3%81%88%e3%82%8b%e3%81%8b\/","title":{"rendered":"Lambda\u306e\u540c\u6642\u5b9f\u884c\u6570\u8a2d\u5b9a\u306b\u3066\u591a\u91cd\u8d77\u52d5\u9632\u6b62\u3092\u884c\u3048\u308b\u304b\u78ba\u304b\u3081\u3066\u307f\u307e\u3057\u305f"},"content":{"rendered":"<h2>\u306f\u3058\u3081\u306b<\/h2>\n<p>\u6bd4\u8f03\u7684\u6700\u8fd1\u5b9f\u88c5\u3055\u308c\u305f\uff082017\u5e7412\u6708 re:Invent2017\u306b\u3066\u767a\u8868\u3055\u308c\u305f\u6a5f\u80fd\uff09Lambda\u65b0\u6a5f\u80fd\u3092\u5229\u7528\u3057\u3001\u3088\u304f\u5229\u7528\u3055\u308c\u308b\u30d1\u30bf\u30fc\u30f3\u3067\u3042\u308b\u5b9a\u671f\u5b9f\u884cLambda\u306b\u3066\u3001\u540c\u6642\u5b9f\u884c\u6570\u8a2d\u5b9a\u3092\u884c\u3044\u672c\u5f53\u306b\u591a\u91cd\u8d77\u52d5\u9632\u6b62\u304c\u884c\u3048\u308b\u304b\u78ba\u304b\u3081\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<h2>\u76ee\u6b21<\/h2>\n<ul>\n<li><a href=\"#overview\">\u6982\u8981<\/a><\/li>\n<li><a href=\"#conclusion\">\u7d50\u8ad6<\/a><\/li>\n<li><a href=\"#event\">\u4e8b\u8c61<\/a><\/li>\n<li><a href=\"#conclusion\">\u7d50\u8ad6<\/a><\/li>\n<\/ul>\n<h2 id=\"overview\">\u6982\u8981<\/h2>\n<p>\u5b9a\u671f\u5b9f\u884cLambda(CloudWatch Events)\u306b\u3066\u8d77\u52d5\u3055\u308c\u308bLambda\u306e\u540c\u6642\u5b9f\u884c\u6570\u30921\u3068\u3059\u308b\u4e8b\u3067\u3001\u591a\u91cd\u8d77\u52d5\u9632\u6b62\u3092\u884c\u3048\u308b\u304b\u8a66\u3057\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Concurrent.png\" alt=\"\" width=\"554\" height=\"226\" class=\"aligncenter size-full wp-image-14831\" srcset=\"https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Concurrent.png 554w, https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Concurrent-300x122.png 300w\" sizes=\"auto, (max-width: 554px) 100vw, 554px\" \/>\n<h2 id=\"conclusion\">\u7d50\u8ad6<\/h2>\n<p>\u7a00\u306a\u30b1\u30fc\u30b9\u3068\u306f\u601d\u3044\u307e\u3059\u304c\u3001\u591a\u91cd\u8d77\u52d5\u304c\u8d77\u304d\u3066\u3057\u307e\u3046\u4e8b\u3092\u78ba\u8a8d\u3057\u307e\u3057\u305f\u3002\uff08\u4e0b\u8a18\u30ed\u30b0\u3092\u53c2\u7167\uff09<\/p>\n<h2 id=\"event\">\u4e8b\u8c61<\/h2>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Cloudwatch_Events.png\" alt=\"\" width=\"823\" height=\"238\" class=\"aligncenter size-full wp-image-14830\" srcset=\"https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Cloudwatch_Events.png 823w, https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Cloudwatch_Events-300x87.png 300w, https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Cloudwatch_Events-768x222.png 768w, https:\/\/www.skyarch.net\/blog\/wp-content\/uploads\/2018\/06\/Cloudwatch_Events-728x211.png 728w\" sizes=\"auto, (max-width: 823px) 100vw, 823px\" \/>\n<h3>time.sleep(300) \u3068\u3057\u305fLambda\u30921\u5206\u6bce\u306b\u5b9a\u671f\u5b9f\u884c<\/h3>\n<p>\u7279\u306b\u554f\u984c\u306a\u304f\u30af\u30ea\u30a2\u3057\u307e\u3057\u305f\u3002<br \/>\n\uff08\u3053\u306e\u305f\u3081\u3001\u5b9f\u969b\u306e\u30c7\u30fc\u30bf\u51e6\u7406\u3092\u3053\u306e\u65b9\u5f0f\u3067\u5b9f\u88c5\u3057\u307e\u3057\u305f\u304c...\uff09<\/p>\n<h3>\u30c7\u30fc\u30bf\u51e6\u7406\u3092\u884c\u306a\u3063\u3066\u3044\u308bLambda\u30921\u5206\u6bce\u306b\u5b9a\u671f\u5b9f\u884c<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n\u30c7\u30fc\u30bf\u304c\u591a\u3044\u5834\u5408\n1\u5206\u5185\u3067\u306f\u51e6\u7406\u304c\u5b8c\u4e86\u3057\u306a\u3044\u304c\u3001\u51e6\u7406\u304c\u7d42\u308f\u3063\u305f\u5f8c\u306b\u8d77\u52d5\u3057\u3066\u304f\u308c\u3066\u3044\u308b\n==================================================\n06:24:46 Starting 2521\n06:28:08 Ending 2521\nREPORT RequestId: 79951b93-XXXX Duration: 202186.40 ms Billed Duration: 202200 ms Memory Size: 256 MB Max Memory Used: 66 MB \n==================================================\n06:28:14 Starting 7682\n06:31:39 Ending 7682\nREPORT RequestId: e4df62f0-XXXX Duration: 205384.78 ms Billed Duration: 205400 ms Memory Size: 256 MB Max Memory Used: 71 MB \n\n\u2193\u3053\u3061\u3089\u304c\u6642\u9593\u91cd\u8907\u3042\u308a\u306e\u90e8\u5206\n==================================================\n06:31:41 Starting 1902\n06:35:32 Ending 1902\nREPORT RequestId: 2c3c6e11-XXXX Duration: 231481.03 ms Billed Duration: 231500 ms Memory Size: 256 MB Max Memory Used: 64 MB \n==================================================\n06:34:47 Starting 5117\n06:38:15 Ending 5117\nREPORT RequestId: df33b496-XXXX Duration: 208681.47 ms Billed Duration: 208700 ms Memory Size: 256 MB Max Memory Used: 67 MB \n==================================================\n\u2191\u3053\u3061\u3089\u304c\u6642\u9593\u91cd\u8907\u3042\u308a\u306e\u90e8\u5206\n\n\u4ee5\u964d\u306f\u51e6\u7406\u30c7\u30fc\u30bf\u304c\u5c11\u306a\u304f\u306a\u308a\u5b9f\u884c\u6642\u9593\u304c\u77ed\u7e2e\n\u3053\u3061\u3089\u3082\u51e6\u7406\u304c\u7d42\u308f\u3063\u305f\u5f8c\u306b\u8d77\u52d5\u3057\u3066\u304f\u308c\u3066\u3044\u308b\n==================================================\n06:38:17 Starting 189 \n06:41:48 Ending 189\nREPORT RequestId: 4a8d8c9f-XXXX Duration: 211292.77 ms Billed Duration: 211300 ms Memory Size: 256 MB Max Memory Used: 70 MB \n==================================================\n06:41:53 Starting 5963\n06:42:45 Ending 5963\nREPORT RequestId: b5efeed5-XXXX Duration: 52585.06 ms Billed Duration: 52600 ms Memory Size: 256 MB Max Memory Used: 62 MB \n==================================================\n06:42:45 Starting 9470 \n06:42:52 Ending 9470\nREPORT RequestId: d994ff2c-XXXX Duration: 6198.75 ms Billed Duration: 6200 ms Memory Size: 256 MB Max Memory Used: 70 MB \n==================================================\n06:42:53 Starting 2264 \n06:42:59 Ending 2264 \nREPORT RequestId: fd5f7060-XXXX Duration: 6470.71 ms Billed Duration: 6500 ms Memory Size: 256 MB Max Memory Used: 45 MB \n<\/pre>\n<h2 id=\"conclusion\">\u7d50\u8ad6<\/h2>\n<p>AWS\u30b5\u30dd\u30fc\u30c8\u306b\u554f\u3044\u5408\u308f\u305b\u305f\u6240\u3001\u3056\u3063\u304f\u308a\u3068\u4e0b\u8a18\u306e\u3088\u3046\u306a\u56de\u7b54\u3092\u3044\u305f\u3060\u304d\u307e\u3057\u305f\u3002<\/p>\n<blockquote><p>\n  CloudWatch Event \u304b\u3089\u306e\u4e26\u5217\u8d77\u52d5\u3092\u9632\u3050\u3053\u3068\u306f\u53ef\u80fd\u3060\u304c\u3001\u671f\u5f85\u3059\u308b\u300c\u9069\u5207\u306a\u5236\u9650\u300d\u306b\u306a\u308b\u304b\u3069\u3046\u304b\u306f\u3001\u95a2\u6570\u306e\u5b9f\u88c5\u3084\u30e6\u30fc\u30b9\u30b1\u30fc\u30b9\u306b\u4f9d\u5b58\u3059\u308b\u306e\u3067\u3001\u691c\u8a3c\u7b49\u3092\u5b9f\u65bd\u3057\u3066\u304b\u3089\u304a\u4f7f\u3044\u304f\u3060\u3055\u3044\u3002\n<\/p><\/blockquote>\n<p>\u3053\u306e\u305f\u3081\u3001\u540c\u6642\u5b9f\u884c\u6570\u8a2d\u5b9a\u306f\u3042\u304f\u307e\u3067\u3082\u76ee\u5b89\u3068\u3057\u3066\u8003\u3048\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<br \/>\n\u65e2\u306b\u51aa\u7b49\u6027\u304c\u62c5\u4fdd\u3055\u308c\u3066\u304a\u308a\u3001\u8907\u6570\u56de\u5b9f\u884c\u3055\u308c\u3066\u3082\u554f\u984c\u306a\u3044\u304c\u30a2\u30ab\u30a6\u30f3\u30c8\u5168\u4f53\u306e\u5b9f\u884c\u6570\u4e0a\u9650\u6570\u98df\u3044\u3064\u3076\u3057\u9632\u6b62\u7b49\u306e\u76ee\u7684\u3067\u5229\u7528\u3059\u3079\u304d\u3068\u5b66\u7fd2\u3057\u307e\u3057\u305f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u306f\u3058\u3081\u306b \u6bd4\u8f03\u7684\u6700\u8fd1\u5b9f\u88c5\u3055\u308c\u305f\uff082017\u5e7412\u6708 re:Invent2017\u306b\u3066\u767a\u8868\u3055\u308c\u305f\u6a5f\u80fd\uff09Lambda\u65b0\u6a5f\u80fd\u3092\u5229\u7528\u3057\u3001\u3088\u304f\u5229\u7528\u3055\u308c\u308b\u30d1\u30bf\u30fc\u30f3\u3067\u3042\u308b\u5b9a\u671f\u5b9f\u884cLambda\u306b\u3066\u3001\u540c\u6642\u5b9f\u884c\u6570\u8a2d\u5b9a\u3092\u884c\u3044\u672c\u5f53\u306b\u591a\u91cd\u8d77\u52d5\u9632\u6b62\u304c\u884c&#8230;<\/p>\n","protected":false},"author":2,"featured_media":14832,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_locale":"ja","_original_post":"14809","footnotes":""},"categories":[20,276],"tags":[],"class_list":{"0":"post-14809","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-aws","8":"category-serverless","9":"ja"},"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/posts\/14809","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/comments?post=14809"}],"version-history":[{"count":11,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/posts\/14809\/revisions"}],"predecessor-version":[{"id":14851,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/posts\/14809\/revisions\/14851"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/media\/14832"}],"wp:attachment":[{"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/media?parent=14809"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/categories?post=14809"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.skyarch.net\/blog\/wp-json\/wp\/v2\/tags?post=14809"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}