Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
multiple-databases-demo
Search
Yuta Endo
November 22, 2017
Programming
0
530
multiple-databases-demo
Yuta Endo
November 22, 2017
Tweet
Share
More Decks by Yuta Endo
See All by Yuta Endo
LINE_Platform_-_UI_UX勉強会__02_-_Chat_Bot編資料.pdf
manzen
0
370
Other Decks in Programming
See All in Programming
SwiftUIで本格音ゲー実装してみた
hypebeans
0
160
Giselleで作るAI QAアシスタント 〜 Pull Requestレビューに継続的QAを
codenote
0
130
WebRTC と Rust と8K 60fps
tnoho
2
2k
複数人でのCLI/Infrastructure as Codeの暮らしを良くする
shmokmt
5
2.3k
「コードは上から下へ読むのが一番」と思った時に、思い出してほしい話
panda728
PRO
38
25k
なあ兄弟、 余白の意味を考えてから UI実装してくれ!
ktcryomm
11
11k
251126 TestState APIってなんだっけ?Step Functionsテストどう変わる?
east_takumi
0
310
dnx で実行できるコマンド、作ってみました
tomohisa
0
150
Full-Cycle Reactivity in Angular: SignalStore mit Signal Forms und Resources
manfredsteyer
PRO
0
210
STYLE
koic
0
170
開発に寄りそう自動テストの実現
goyoki
1
850
バックエンドエンジニアによる Amebaブログ K8s 基盤への CronJobの導入・運用経験
sunabig
0
150
Featured
See All Featured
Testing 201, or: Great Expectations
jmmastey
46
7.8k
Principles of Awesome APIs and How to Build Them.
keavy
127
17k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
1.8k
GraphQLとの向き合い方2022年版
quramy
50
14k
Context Engineering - Making Every Token Count
addyosmani
9
500
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.2k
Navigating Team Friction
lara
191
16k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
7.9k
jQuery: Nuts, Bolts and Bling
dougneiner
65
8.2k
For a Future-Friendly Web
brad_frost
180
10k
How STYLIGHT went responsive
nonsquared
100
6k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
54k
Transcript
KotlinとSpring Bootで 複数データベースを扱う Rest APIを作ってみた 2017/11/22 #m3kt どこでもKotlin #4 秋のLT大会
のらねこワークス株式会社 遠藤 @ENZEN0129
自己紹介 氏名:遠藤 友太 Twitter:@ENZEN0129 所属:のらねこワークス株式会社 エンジニア 得意:java ruby kotlin php
node angular react js aws … etc その他活動 • http://www.ittan.website/ • https://qiita.com/enzen • http://www.enzen.net/
今日のテーマ Kotlin x spring bootでマルチデータベースアクセス!!
環境
ディレクトリ構成
処理イメージ Controller Service Service Repository Repository
APIのイメージ Controller Service Service Repository Repository
Controller
Controller
Controller
None
Controller
None
最高やでKotlinたん
ちなみにJavaで書くとこんな感じ
None
None
APIのイメージ Controller Service Service Repository Repository
User Service
External User Info Service
APIのイメージ Controller Service Service Repository Repository
Repository
model
Primary Configuration
Configuration
Secondary Configuration
Configuration
Spring bootでできたしSpring batchでも Kotlin x spring batchでマルチデータベースアクセス!!
None
なんで?
None
None
誰か僕に教えてよ
None
こんなになるまでいろいろ 試したんだ
None
誰か僕を助けてよ!
None
None
None
Spring bootでできたしSpring batchでも。。。 あれ? Kotlin x spring batchでマルチデータベースアクセス!!
結果 Kotlin x spring boot x spring bootで マルチデータベースアクセス!!
最後に サンプルコードをGithubにあげています。 https://github.com/manzen/multiple-databases-demo