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
2022 - COSCUP - 打造高速 Ruby 專案開發流程
Search
蒼時弦や
July 31, 2022
Programming
320
0
Share
2022 - COSCUP - 打造高速 Ruby 專案開發流程
現代軟體開發對於品質跟速度的要求越來越高,然而當我們開始一個全新專案的時候,總是難以很好的兼顧這些問題,這場演講將會分享如何實踐。
蒼時弦や
July 31, 2022
More Decks by 蒼時弦や
See All by 蒼時弦や
2024 - COSCUP - Clean Architecture in Rails
elct9620
2
200
2023 - RubyConfTW - Rethink Rails Architecture
elct9620
0
230
20230916 - DDDTW - 導入 Domain-Driven Design 的最佳時機
elct9620
0
470
2023 - WebConf - 選擇適合你的技能組合
elct9620
0
680
20230322 - Generative AI 小聚 ft. Happy Designer
elct9620
0
450
2022 - 默默會 - 重新學習 MVC 的 Model
elct9620
1
510
MOPCON 2022 - 從 Domain-Driven Design 看網站開發框架隱藏
elct9620
1
530
2022 - COSCUP - 我想慢慢寫程式該怎麼辦?
elct9620
0
290
2021 - RubyKaigi - It is time to build your mruby VM on the microcontroller?
elct9620
0
300
Other Decks in Programming
See All in Programming
Symfony AI in Action - SymfonyLive Berlin 2026
chr_hertel
1
110
Programming with a DJ Controller — not vibe coding
m_seki
3
730
Vibe NLP for Applied NLP
inesmontani
PRO
0
570
GitHubCopilotCLIをはじめよう.pdf
htkym
0
310
Kingdom of the Machine
yui_knk
2
1.3k
의존성 주입과 모듈화
fornewid
0
160
AI-DLC Deep Dive
yuukiyo
9
5.3k
[RubyKaigi 2026] Require Hooks
palkan
1
280
Swift Concurrency Type System
inamiy
1
570
SREに優しいTerraform構成 modulesとstateの組み方
hiyanger
2
160
JOAI2026 1st solution - heron0519 -
heron0519
0
170
JAWS-UG横浜 #100 祝・第100回スペシャルAWS は VPC レスの時代へ
maroon1st
0
200
Featured
See All Featured
Information Architects: The Missing Link in Design Systems
soysaucechin
0
910
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
2
1.5k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.3k
Producing Creativity
orderedlist
PRO
348
40k
Why Our Code Smells
bkeepers
PRO
340
58k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
130
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
Why You Should Never Use an ORM
jnunemaker
PRO
61
9.8k
HDC tutorial
michielstock
2
650
Ecommerce SEO: The Keys for Success Now & Beyond - #SERPConf2024
aleyda
1
2k
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
Transcript
打造⾼速 Ruby 產品 開發流程
@elct9620 THE PROGRAMMER OF CREATIVE ႏָࣛɰ
#Consulting Job
#Ruby/Rails Course and Tools Product
https://blog.aotoki.me Blog
https://discord.com/invite/t2Kd6PNvvA Discord
https://www.youtube.com/channel/UCcABbJfCL0DfNh3wDk_-7lg YouTube
慢在哪裡
None
初始化 當我們做完 rails new 命令後,還有多少設定要調整
規格 確認規格後到實現功能要多久的時間
審查 撰寫的程式碼符合團隊風格、沒有太多技術債、壞味道的檢查時間有多長
測試 完成的功能測試所需的時間,是否有⾃動測試和⼈⼯測試
部署 安裝伺服器、完整的網路、雲端等設定所需的時間
監控 產品部署後是否可以順利監控效能、錯誤並且得以持續改善
敏捷⽅法
完成 Done 跟 Finished 不同在於前者是「堪⽤」後者是「結束」
可驗證 在「堪⽤」狀態下表⽰「功能不完整」但可⽤,因此可以透過⾃動測試驗證完成狀況
由上⾄下 從完整的設計系統改為「可以看到畫⾯」或「可以呼叫 API」的⽅式開始開發
關注功能 開發產品需要關⼼的是功能的可⽤,因此⽬標是打造「最⼩可⾏」的功能(產品)
持續整合 產品只有⼀個主幹分⽀所有⼈直接推到 main branch,隨時都保持在最新的狀態
⾃動測試 為了可以持續整合,我們需要⼤量的⾃動測試確保「功能」正常
重構 在有測試保護的狀況下已不改變功能的前提「持續改善」程式碼
持續部署 產品的所有功能隨時都是可⽤的狀態,隨時都可以部署給使⽤者使⽤
功能開關 尚未準備好釋出的功能使⽤ Feature Flag 保護起來,讓持續部署得以實現隨時部署
敏捷開發是⽂化、流程上的改變
思考 無法改變⽂化、流程的狀況下,還能做些什麼?
使⽤⼯具
Bankai 預先設定好習慣的 Rails 專案設定,初始化專案只需要數分鐘 https://github.com/5xRuby/bankai
Cucumber E2E 測試⼯具,⽅便溝通規格以及確認使⽤者⾓度的「使⽤」是沒問題的
RSpec 夠熟練的話⽤來寫單元測試非常好⽤,適合針對 Cucumber 的細部功能做測試
Rubocop 減少 Code Review 針對寫法的檢查,⾃動化的檢查撰寫的風格和避開容易出問題的寫法
Brakeman 針對 Rails 常⾒資安問題的寫法做檢查,可以減少常⾒的⼈為疏失
Bundler Audit ⽤來檢查 Ruby Gem 的漏洞,來確保可以持續更新到沒問題的版本
Bundler Leak 跟 Bundler Audit 類似,可以⽤來找到使⽤的 Ruby Gem 是否有記憶體洩漏的問題
Ruby GitLab CI Tempalte 預先設定從靜態分析到測試和部署所有步驟的樣板,可以快速的完成 CI/CD 流程的建置 https://github.com/elct9620/ruby-gitlab-ci
⾃動⽣成 Production ⽤的 Dockerfile 可以節省⾃⼰撰寫跟設計的時間 Boxing
容器的 Entrypoint ⼯具,可以增加安全性以及確保 Rails 在資料庫準備好後才啟動 Openbox https://github.com/elct9620/openbox
Health Check ⽤的套件,可以⾃訂檢查規則來快速讓 AWS ALB 這類服務能做檢查 Liveiness https://github.com/elct9620/liveness
⼯具、技術、⽂化漸進式的改善
#Thanks Q&A