Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Scala@SmartNews AdFrontend を Scala で書いた話

10,914 views

Published on

Scala@SmartNews AdFrontend を Scala で書いた話

Published in: Technology
  • If you want to download or read this book, Copy link or url below in the New tab ......................................................................................................................... DOWNLOAD FULL PDF EBOOK here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download EPUB Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download Doc Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... .........................................................................................................................
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • If you want to download or read this book, Copy link or url below in the New tab ......................................................................................................................... DOWNLOAD FULL PDF EBOOK here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download EPUB Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download Doc Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... .........................................................................................................................
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD THI5 BOOKS INTO AVAILABLE FORMAT (Unlimited) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download Full EPUB Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... ACCESS WEBSITE for All Ebooks ......................................................................................................................... Download Full PDF EBOOK here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download EPUB Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download doc Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (Unlimited) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... Download Full EPUB Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ACCESS WEBSITE for All Ebooks ......................................................................................................................... Download Full PDF EBOOK here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... Download EPUB Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... Download doc Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (Unlimited) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... Download Full EPUB Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ACCESS WEBSITE for All Ebooks ......................................................................................................................... Download Full PDF EBOOK here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... Download EPUB Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... Download doc Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

Scala@SmartNews AdFrontend を Scala で書いた話

  1. 1. Scala@SmartNews Ad Frontend を Scala で書いた話 @kjim
  2. 2. 自己紹介 • 村石恵示 • スマートニュース (2014/09入社) • SmartNews Ads Engineer • 基本は Java な人
  3. 3. アドチームのミッション…
  4. 4. 12月に最高の広告 プロダクトをリリースする
  5. 5. Ads as Content
  6. 6. Web Framework ? • クラスのオートリロード(ホットリローディング)は必須。 • 静的型付けによるサポート欲しい。
 動かす前にある程度動く担保を作りたい。DB拡張に追随する時にコンパイラにエラーでナビゲートして欲しい。 • 宣言的ルーティング定義。 • 宣言的フォームバリデーション定義。 • DBスキーマからDataAccess層を生成したい。 • パフォーマンスはそんなに追求しない。 • Scala アリでは…
  7. 7. Scala + Play2 + Slick
  8. 8. Play2 宣言的なルーティング設定
  9. 9. Play2 宣言的なフォームバリデーション定義
  10. 10. Slick DataAccess層を自動生成 • スキーマのバージョン管理は flyway
 Evolution は使ってない • flyway で管理しているスキーマから Slick のテーブルクラスをリバースで 自動生成。生成するクラスはSourceCodeGeneratorをカスタマイズして 複数の .scala ファイルを生成するようにしている。 • ただし、自動生成したクラスは直接サービス層から使わずRepository層の 内側で利用 • 更新系は普通にSlickのメソッドを利用するが、参照系は普通にSQL書い てる。
  11. 11. Scala On the fly なコードを瞬時に書ける • Option
 Some(true), Some(false), Some(null), None
 メソッドの仕様を明示できる
 NullPointerException回避 • case class
 パターンマッチ
 便利メソッド、永続化など • Collection, Future, … • 業務系アプリを作るのにも最適な言語
  12. 12. ただし、 Scala最大のツラミは コンパイル速度
  13. 13. まとめ
  14. 14. まとめ • Scala + Play2 + Slick は開発のリズムを作りやすい • 型の安心感 • 宣言的プログラミング • 言語標準の豊かなAPI • Scala業務系アプリを作るのにも最適な言語 • Scalaはマジでコンパイルが遅い
  15. 15. SmartNews 世界中の良質な情報を必要な人に送り届ける • 一緒にスマートニュースを作ってくれる仲間を 募集しています。
 http://about.smartnews.com/ja/careers/ • オフィススペースを提供していますのでお声掛 けください。
  16. 16. ありがとうございました

×