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
Swagger × Spring Cloud
Search
Hidetake Iwata
November 18, 2016
Technology
0
110
Swagger × Spring Cloud
Spring Day 2016 Lightning Talk
http://springday2016.springframework.jp
Hidetake Iwata
November 18, 2016
Tweet
Share
More Decks by Hidetake Iwata
See All by Hidetake Iwata
Rewrite Go error handling using AST transformation
int128
1
1.3k
Cluster AutoscalerをTerraformとHelmfileでデプロイしてPrometheusでモニタリングする / Deploy the Cluster Autoscaler with Terraform and Helmfile, Monitor with Prometheus
int128
3
1.8k
認証の仕組みとclient-go credential plugin / authentication and client-go credential plugin
int128
7
7.6k
CLIでOAuth/OIDCを快適に利用する
int128
0
940
AppEngine × Spring Boot × Kotlin
int128
0
130
いつものJIRA設定
int128
1
200
Swaggerのテンプレートを魔改造した話 / Customize Swagger Templates
int128
1
4.9k
本番環境のリリースを自動化した話
int128
0
800
The Evolution of System Architecture
int128
0
190
Other Decks in Technology
See All in Technology
Biz職でもDifyでできる! 「触らないAIワークフロー」を実現する方法
igarashikana
3
2.2k
Copilot Studio ハンズオン - 生成オーケストレーションモード
tomoyasasakimskk
0
200
様々なファイルシステム
sat
PRO
0
140
[2025年10月版] Databricks Data + AI Boot Camp
databricksjapan
1
240
CNCFの視点で捉えるPlatform Engineering - 最新動向と展望 / Platform Engineering from the CNCF Perspective
hhiroshell
0
130
AI AgentをLangflowでサクッと作って、1日働かせてみた!
yano13
1
130
だいたい分かった気になる 『SREの知識地図』 / introduction-to-sre-knowledge-map-book
katsuhisa91
PRO
3
1.3k
Zephyr(RTOS)にEdge AIを組み込んでみた話
iotengineer22
1
280
QA業務を変える(!?)AIを併用した不具合分析の実践
ma2ri
0
110
Implementing and Evaluating a High-Level Language with WasmGC and the Wasm Component Model: Scala’s Case
tanishiking
0
170
ヘンリー会社紹介資料(エンジニア向け) / company deck for engineer
henryofficial
0
330
Wasmの気になる最新情報
askua
0
180
Featured
See All Featured
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.5k
Automating Front-end Workflow
addyosmani
1371
200k
Speed Design
sergeychernyshev
32
1.2k
The Cult of Friendly URLs
andyhume
79
6.6k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
53k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
10
610
The World Runs on Bad Software
bkeepers
PRO
72
11k
Embracing the Ebb and Flow
colly
88
4.9k
Site-Speed That Sticks
csswizardry
13
920
Measuring & Analyzing Core Web Vitals
bluesmoon
9
630
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.7k
Code Reviewing Like a Champion
maltzj
526
40k
Transcript
Swagger × Spring Cloud @int128 (Hidetake Iwata)
None
Open API Specification / Swagger REST APIの仕様をJSONやYAMLで記述できる。 ツールセットが提供されている。 • Swagger
Editor(エディタ) • Swagger UI(APIコンソール) • Swagger Codegen(コード自動生成)
Swagger Codegen Swagger YAMLからいろんな言語のソースコードを自動生成する ツール。JARで提供されている。 • Java • Node.js •
PHP • などなど ※逆に、アノテーションからAPI仕様を生成する方法もある
Swagger Codegen × Spring 以下のテンプレートを選択できる: 1. spring-mvc ◦ APIサーバのControllerとModelが自動生成される ◦
Spring MVC 2. spring-cloud ◦ APIクライアントのClientとModelが自動生成される ◦ Spring Cloud Feign
自動生成コードの取り扱い 自動生成されたコードは変更しない。 JARに切り出して、ビルドツールで依存関係を張る。 地獄のパターン: • 自動生成されたコードをいじる(ControllerやModel) • API仕様が変わる • コードに変更を取り込む?
自動生成コード: • Controllerクラス ◦ ServiceクラスをDIしてメソッド実行 ◦ テンプレートをカスタマイズ • Modelクラス 実装コード:
• Serviceクラス:ビジネスロジックを実装 自動生成コードと実装コードをDIで分離
Gradle Swagger Generator Plugin Swagger YAMLからソースコードやドキュメントを生成 https://github.com/int128/gradle-swagger-generator-plugin
None
None
None
Thank you
2002年 2003年 2004年 2005年 Spring 1.0がリリースされたのはいつ?