Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Lotus
Search
Luca Guidi
October 14, 2014
Programming
8
560
Lotus
Lotus: a complete web framework for Ruby.
Luca Guidi
October 14, 2014
Tweet
Share
More Decks by Luca Guidi
See All by Luca Guidi
Functional Web with Hanami
jodosha
4
440
Lessons Learned While Building Hanami
jodosha
4
1.1k
Lotus RubyDay 2015
jodosha
2
940
Lotus For Rails Developers
jodosha
2
320
Lotus - Brighton Ruby 2015
jodosha
3
910
A Rails Criticism
jodosha
4
1.7k
Other Decks in Programming
See All in Programming
守る「だけ」の優しいEMを抜けて、 事業とチームを両方見る視点を身につけた話
maroon8021
3
1.3k
How to stabilize UI tests using XCTest
akkeylab
0
140
ベクトル検索のフィルタを用いた機械学習モデルとの統合 / python-meetup-fukuoka-06-vector-attr
monochromegane
2
510
Migration to Signals, Signal Forms, Resource API, and NgRx Signal Store @Angular Days 03/2026 Munich
manfredsteyer
PRO
0
130
モダンOBSプラグイン開発
umireon
0
170
AI Assistants for Your Angular Solutions
manfredsteyer
PRO
0
160
API Platformを活用したPHPによる本格的なWeb API開発 / api-platform-book-intro
ttskch
1
150
Redox OS でのネームスペース管理と chroot の実現
isanethen
0
410
Claude Code Skill入門
mayahoney
0
420
AWS×クラウドネイティブソフトウェア設計 / AWS x Cloud-Native Software Design
nrslib
16
3.3k
社内規程RAGの精度を73.3% → 100%に改善した話
oharu121
13
8.3k
存在論的プログラミング: 時間と存在を記述する
koriym
4
430
Featured
See All Featured
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
110
Producing Creativity
orderedlist
PRO
348
40k
The agentic SEO stack - context over prompts
schlessera
0
710
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
410
From π to Pie charts
rasagy
0
150
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.2k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.8k
Darren the Foodie - Storyboard
khoart
PRO
3
2.9k
Building Adaptive Systems
keathley
44
3k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
480
Heart Work Chapter 1 - Part 1
lfama
PRO
5
35k
Transcript
Lotus A c o mp l e t e web
framework @jodosha / #lotusrb
None
Do we need yet another web framework?
Are you reinventing the wheel?
What if we never reinvented the wheel?
The wheel
None
We reinvented the wheel after observing it
Complexity should be managed, not hidden.
Why does this matter?
The ultimate goal is…
Money https://flic.kr/p/aFAEHR
Use case: http://bit.ly/github-rails-upgrade
We should not trade control for convenience.
Cost of maintenance 0 20 40 60 80 Years 0
1 2 3 Covenience Simplicity
Silver bullets are a lie.
Philosophy
Standalone frameworks
Full stack applications
Few conventions More objects No monkey- patching
Few conventions More objects No monkey- patching
Few conventions More objects No monkey- patching
Simple
Simplicity is achieved by removing what isn’t essential
Coffee https://flic.kr/p/6rX8pn
Convenient https://flic.kr/p/93Bk4K
Simple https://flic.kr/p/mn57Zm
The output https://flic.kr/p/9oG93w
Lotus doesn’t enable optional features by default
We perceive as simple the things we are familiar with
BookRepository.find 23
Rails.application.routes.draw do get '/' => 'home#index', as: :home resources :books
end ! Rails.application.routes # => ???
router = Lotus::Router.new do get '/', to: 'home#index', as: :home
resources :books end ! router.path(:home) # => '/' router.call(env) # Rack env run router # in config.ru
Fast
Micro benchmarks http://bit.ly/lotus-micro-bench
HTTP benchmarks http://bit.ly/lotus-http-bench
Rails 1027.73 Sinatra 2207.73 Lotus 4175.90 http://bit.ly/lotus-http-bench req/s
Rails 1027.73 Sinatra 2207.73 Lotus 4175.90 http://bit.ly/lotus-http-bench req/s
Rails 1027.73 Sinatra 2207.73 Lotus 4175.90 http://bit.ly/lotus-http-bench req/s
Testable
Testability is a virtue
There is no “test-damaged” design
class Show include Lotus::Action ! expose :book ! def initialize(repository
= BooksRepository) @repository = repository end ! def call(params) @book = @repository.find params[:id] end end
book = Object.new repository = Minitest::Mock.new repository.expect(:find, book, [Integer]) !
action = Show.new(repository) action.call(id: 23) # => [200, {}, nil] ! repository.verify action.book.must_equal book # assigns(:book) isn’t needed
Demo
The future
Get involved
lotusrb.org #lotusrb @jodosha
Q&A
Thank you!