英題:Fluentd Hacking Guide
30分しかないため斜線部分は今回省く
- Fluentd の起動シーケンスとプラグインの読み込み
Fluentd の設定ファイルのパース- Input Plugin から Output Plugin にデータが渡る流れ
| import AVFoundation | |
| import Foundation | |
| // The maximum number of audio buffers in flight. Setting to two allows one | |
| // buffer to be played while the next is being written. | |
| private let kInFlightAudioBuffers: Int = 2 | |
| // The number of audio samples per buffer. A lower value reduces latency for | |
| // changes but requires more processing but increases the risk of being unable | |
| // to fill the buffers in time. A setting of 1024 represents about 23ms of |
| #!/bin/bash | |
| # BSD sed | |
| for keg in /usr/local/Library/LinkedKegs/*; do kegname="$(basename $keg)"; dir="$(find $keg/ -maxdepth 1 -type d | grep '\/\(sbin\|bin\|etc\|var\|lib\|include\|libexec\|share\)$' | head -n1)"; [ -z "${dir}" ] && continue; testee="$(find $dir -type f | head -n1 | sed -e "s|${keg}||")"; test -f /usr/local/$testee || (echo $keg && brew unlink $kegname; brew link --force $kegname); done |
| #!/bin/bash -ex | |
| exec > >(tee /var/log/user-data.log|logger -t user-data -s 2>/dev/console) 2>&1 | |
| while [ ! -e /dev/sdb ]; do echo Waiting for Ephemeral Disk to attach; sleep 5; done | |
| if ! `df | grep -q /media/ephemeral0` ; then | |
| mkfs.ext3 /dev/sdb | |
| mount -t ext3 /dev/sdb /media/ephemeral0 | |
| fi | |
| # snip... |
| mysql> SELECT * FROM t1; | |
| +-----+------+ | |
| | num | val | | |
| +-----+------+ | |
| | 1 | one | | |
| | 2 | two | | |
| | 3 | tree | | |
| +-----+------+ | |
| 3 rows in set (0.00 sec) |
スマートフォンのセキュリティについて
ma.la
| # 私が考える安全なプログラムを書くために必要なこと | |
| 今も昔も「入力によって挙動が大幅に変わるAPI」が世の中には多数存在していて、プログラマが本来意図した挙動と異なる動作を引き起こしている。 | |
| - ファイルを開こうとしたらコマンドを実行できてしまったり | |
| - CSSセレクタを書いてるつもりがHTMLタグを生成してしまったり | |
| - SELECT文を発行するつもりがDELETE文を発行できてしまったり | |
| こういったときに | |
| - 入力値検証をしないと危険になる |
| やわらかRubyはCC BY 4.0 で提供します。 | |
| 詳細: https://creativecommons.org/licenses/by/4.0/deed.ja | |
| This work is licensed under a Creative Commons Attribution 4.0 International License. | |
| See also: https://creativecommons.org/licenses/by/4.0/deed |