You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
Clojureのいろんな並行処理の使い分け Clojureには標準でもagent系のsend, send-offに加え、future関数というスレッド起動系関数があります。 core.asyncの登場で、ここにgoマクロとthreadマクロが加わりました。 これらはすべて、背後ではJavaのExecutorsを使ってスレッドプールを作り、一度生成したスレッドの再利用を行いますが、それぞれ使っているスレッドプールが異なります。さらに関数自体の機能も異なるため、どれをつかったらいいのか迷ってしまうことがあります。 自分用に整理したので、メモとしておいておきます。 IOバウンドとCPUバウンドまず、Clojureのスレッド関連関数の用途は、大きく2種類にわけられます。それが、IOバウンドとCPUバウンドです。 IOバウンドな処理は、実行中の処理がCPUよりもIO処理に強く依存します。DBアクセス
もう1週間以上経ってしまったけど、10/10に開かれたClojure夜会に参加してきた。 Clojure 夜会(Evening Party) - Clojure大好き! | Doorkeeper 平日の夜から(しかも東京で)のイベントだったので最初は参加は難しいなぁと思っていたのだけど、休みがギリギリとれたので4日前くらいになって急遽参加することにした。 発表について せっかくわざわざ東京まで行くのにただ話を聞いているだけというのももったいないなと思い、LT枠も余っている様子だったのでそこから急造でネタごしらえ。自分が最近やっていることでネタになりそうなおもしろい話が特になかったので、去年くらいからちょくちょく海外のClojureコミュニティの人たちのブログで話に挙がるStuart Sierra*1が提案するClojureワークフローについて紹介することにした。 当日の発表資料はこちら。
Aug 10, 2014 Rich Hickey様から以下のような発信がなされました。 Clojure1.7にtransducersというものが追加されるよ、という話です。 Transducers are Coming — Cognitect Blog どんなものかというと、従来のcoreのシーケンスを扱う関数群に新しい機能が追加されていてたとえば (map inc) これがmapping transducerというtransducerを返します。 このtransducerを使って (def xform (map inc)) (sequence xform '(1 2 3)) ; => (2 3 4) (into xform [1 2 3]) ; => [2 3 4] このように任意のtransducerによるシーケンスの変換ができるわけです。ほかにも多数の関数がtransducerを扱え
はじめに Light Table Plugin Tutorialの翻訳になります。 LightTable のプラグインに関する日本語情報が不足しているため、翻訳してみました。 間違い等ありましたら、ご指摘いただけると助かります。 Original article: Light Table Plugin Tutorial by Jakub Arnold ちなみにオリジナルの記事はLightTableのwikiにもリンクが貼ってあります。 元記事の著者の許可は取得済み↓ Hi, @darthdeus. Would you mind if I translate this article(http://t.co/UrF1TYuRpR) in Japanese? and post on my blog?— Satoshi Kondo (@snufkon) 2014, 3月 2 @darthdeus
I love REPL Driven Development. My style is to write expressions directly in the file that I’m working on and to use C-x C-e to view the value of the last command in the minibuffer. Being able to move my cursor to a sub-expression and see the value of that expression immediately feels like a superpower. I love this ability and it’s one of the things that keeps me locked into Clojure+Emacs as my pr
► 2016 (18) ► October (3) ► September (5) ► August (6) ► July (4) ▼ 2014 (12) ► November (1) ► August (1) ► July (5) ► April (1) ▼ February (4) Testing with clojure.test and midje Clojure: from not knowing it to testing a web serv... Plain text screencast Rules to write functional Scala code and stay sane ► 2013 (9) ► December (1) ► November (2) ► October (1) ► May (2) ► April (3)
Thanks to REST and Swagger, we can build beautiful apis to feed both our browser front-ends and external applications. But, wrapping your Clojure code into resources mostly for your ClojureScript front-end doesn't feel right? Just use RPC? Meet in the middle? Kekkonen is a small library for managing your (web) apis as commands and queries. No magic, data-driven, un-restful and non-rpc. It's goals
Room metro #23 大阪 LT http://metrostyledev.net/index.php/event/20131026/ 実務でよく使うhtml,css,jsの小技をつらつらと紹介します。 ※2/11のスクーの授業中で使った資料です。 https://schoo.jp/class/1776 【オシャレCSS編】 1. transformを使って要素を変形させるワザ 2. transitionを使い、CSSだけで簡単なアニメーションを行うワザ 3. keyframesを使ってCSSだけで複雑なアニメーションを行うワザ 4. 矢印アイコンをcssだけで表現するワザ 5. アイコンをアニメーションさせるワザ 6. CSSプロパティ”filter”で画像を加工するワザ 【地味だけど使えるワザ編】 7. 今どきの、要素を上下中央寄せにするワ
Previously: Debugging. In this chapter, we’ll discuss some of Clojure’s mechanisms for polymorphism: writing programs that do different things depending on what kind of inputs they receive. We’ll show ways to write open functions, which can be extended to new conditions later on, without changing their original definitions. Along the way, we’ll investigate Clojure’s type system in more detail–disc
こんにちは。kimukimuです。 徐々に暖かくなってきていますね。春は目前です。 さて、つい先日Apache Stormとして初リリースとなる「0.9.1-incubating」がリリースされました! #ちなみに前回リリースは「0.9.0.1」です。 今回リリース内容は大きく分けて、Apache Incubatorに移行したため発生したものと、 機能追加/不具合対応によるものの2つがあります。 節目のリリースですので両方についてリリースノートより主要な項目を紹介しますね。 1. Apache Incubatorとしてのリリース内容 ライセンスの変更 ライセンスが「Eclipse Public License - v 1.0」から「Apache License Version 2.0」に変更になってます。 今回の変更で今まで使っていた方が使えなくなる・・・ということはないのですが、 きちん
※ この集計結果には、統計上の誤謬が多く含まれるので、どの言語を勉強すると儲かるかという視点でなく、あくまでもEnliveとIncanterを使うとWeb上のデータを使って簡単に集計プログラムが作れるよという点をお楽しみください。 どのプログラミング言語が儲かるのか、意識の高いエンジニアには気になるネタですよね。 indeed.comという求人サイトがありますが、これはクローラー型求人サイトとよばれるタイプで、各求人サイトからの情報をかき集めて検索ができるようになっています。 IndeedにもAPIはあるのですが、給与レンジをとることは出来なさそうなので、スクレイピングで対応します。Indeedでキーワード検索すると、右下に推定年収が表示されます。これを拾いだしてグラフを書いてみます。 スクレイピングにはJsoupのラッパーとしても使い勝手のよいEnliveを使います。 推定年収のDiv要
The true delight is in the finding out rather than in the knowing. -- Isaac Asimov Clojure is one of the most interesting new languages targeting the JVM. Initially only the JVM, in the meantime it is also available for JavaScript. Essentially, you can write Clojure and either execute it as Java program or JavaScript program, of course each flavor has its unique features as well. Clojure is a Lisp
This website was developed by the Clojure Documentation Team. This page was last updated on January 18, 2018 at 06:28.
タイトルを見て何のことか想像つく人には多分つまらない話です。ついでに nil と seq というキーワードも追加します。おそらく想像通りの内容です。あしからず。 少し長い前置き 前のエントリで逆引き天気予報のプログラムを書きましたが、書いていて何か違和感を感じていました。この部分です。 (defn report* [re id] (let [rss (rss-zip (city-url id))] (when-let [fcs (-> (search-forecast re rss) seq)] (let [city (title-city rss)] (->> fcs (map (fn [fc] {:forecast fc :city city :id id}))))))) 解説します。 reが予報の検索条件で正規表現のpatternオブジェクトを渡します。idは地域を表す番号です。この
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く