I hereby claim:
- I am mopemope on github.
- I am mopemope (https://keybase.io/mopemope) on keybase.
- I have a public key whose fingerprint is FC78 C29B 617B 2CF1 5EB9 BD7D DE91 BF6D 14CF 8CE7
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
$ packer -S yubikey-personalization yubikey-personalization-gui yubikey-neo-manager |
use "net/http" | |
actor Main | |
new create(env: Env) => | |
let service = try env.args(1) else "50000" end | |
let limit = try env.args(2).u64() else 100 end | |
Server(Info(env), Handle, CommonLog(env.out) where service = service, | |
limit = limit) |
近年、ネットワークアプリケーションを書くにあたり Erlang/OTP に対する注目が集まっています。 大規模サービスで使わているなどの事例が多く紹介されるようになり、導入を考えている方も多いでしょう。 ですが、Erlang は少々癖があり、難しく感じる方も少なくありません。 今回はそのような人向けに LFE を紹介しようと思います。
LFE とは (lisp (flavored (erlang))) の略です。その名の通り、 Erlang Virtual Machine (BEAM) 上で動く Lisp です。
(defmodule ppool-nagger | |
(export all) | |
(behavior gen_server)) | |
(defun start-link (task delay max send-to) | |
(gen_server:start_link (MODULE) `#(,task ,delay ,max ,send-to) '())) | |
(defun start_link (task delay max send-to) | |
(start-link task delay max send-to)) |
(defmodule band-supervisor | |
(export all) | |
(behavior 'supervisor)) | |
(defun start-link (type) | |
(supervisor:start_link `#(local ,(MODULE)) (MODULE) type)) | |
(defun start_link (type) | |
(start-link type)) |
(defmodule curling-accumulator | |
(export all) | |
(behavior 'gen_event)) | |
(defrecord state | |
(teams (orddict:new)) | |
(round 0)) | |
(defun init | |
(('()) `#(ok ,(make-state)))) |
(defmodule trade-call | |
(export all)) | |
(defun sync1 (pid) | |
(! pid (self)) | |
(receive | |
('ack 'ok))) | |
(defun sync2 () | |
(receive |
(defmodule kitty-gen-server | |
(export all) | |
(behavior 'gen_server)) | |
(defrecord cat | |
name | |
(color 'green) | |
description) | |
(defun start-link () |
(defmodule kitty-server2 | |
(export all)) | |
(defrecord cat | |
name | |
(color 'green) | |
description) | |
(defun start-link () | |
(my-server:start-link (MODULE) ())) |