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
Low fat backends for mobile guys
Search
Alexandru Simonescu
February 28, 2016
Programming
0
94
Low fat backends for mobile guys
Low fat backends for mobile guys:
Develop simple backends in Java in minutes
Alexandru Simonescu
February 28, 2016
Tweet
Share
More Decks by Alexandru Simonescu
See All by Alexandru Simonescu
Software Architecture Journey
alxsimo
4
760
Serverless mobile applications with Firebase v2
alxsimo
4
250
Serverless mobile applications with Firebase
alxsimo
5
300
!Smelly code - The origins
alxsimo
0
87
Cleaner code with Guava v2
alxsimo
5
510
Cleaner code with Guava
alxsimo
3
140
GIT: what else?
alxsimo
1
100
Other Decks in Programming
See All in Programming
Micro Frontends Unmasked Opportunities, Challenges, Alternatives
manfredsteyer
PRO
0
110
Click-free releases & the making of a CLI app
oheyadam
2
120
Amazon Bedrock Agentsを用いてアプリ開発してみた!
har1101
0
340
TypeScript Graph でコードレビューの心理的障壁を乗り越える
ysk8hori
2
1.1k
C++でシェーダを書く
fadis
6
4.1k
Snowflake x dbtで作るセキュアでアジャイルなデータ基盤
tsoshiro
2
520
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
480
ローコードSaaSのUXを向上させるためのTypeScript
taro28
1
630
A Journey of Contribution and Collaboration in Open Source
ivargrimstad
0
970
よくできたテンプレート言語として TypeScript + JSX を利用する試み / Using TypeScript + JSX outside of Web Frontend #TSKaigiKansai
izumin5210
6
1.7k
ふかぼれ!CSSセレクターモジュール / Fukabore! CSS Selectors Module
petamoriken
0
150
ActiveSupport::Notifications supporting instrumentation of Rails apps with OpenTelemetry
ymtdzzz
1
250
Featured
See All Featured
Happy Clients
brianwarren
98
6.7k
Testing 201, or: Great Expectations
jmmastey
38
7.1k
Designing on Purpose - Digital PM Summit 2013
jponch
115
7k
Optimizing for Happiness
mojombo
376
70k
Automating Front-end Workflow
addyosmani
1366
200k
Six Lessons from altMBA
skipperchong
27
3.5k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
28
2k
The World Runs on Bad Software
bkeepers
PRO
65
11k
How GitHub (no longer) Works
holman
310
140k
Put a Button on it: Removing Barriers to Going Fast.
kastner
59
3.5k
The Power of CSS Pseudo Elements
geoffreycrofte
73
5.3k
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
Transcript
Low fat backends For mobile guys
Alexandru Simonescu
[email protected]
@alexsimonescu http://blog.alexsimo.com “Do what you love. Love
what you do.” - Ray Bradbury
do you really need a backend? think twice
mbaas sometimes do the trick
mbaas cons not a golden unicorn _you depend on some
else infrastructure _normally can be cheap, related your needs _no full control, your data is not yours _sometimes hard to scale
and now what?
why not roll your own backend?
we all have a backend dev inside
backend cons or not :-) _custom backend is hard to
develop _can be expensive _i can’t setup infrastructure _i’m just a mobile guy
infrastructure AWS Digital Ocean VPS Dime ~ 5€ month
showtime create required entities, layers and configuration
kickstart 1. set project metadata 2. choose dependencies 3. download
4. import in favorite IDE 5. customize and run https://start.spring.io/
Rest controllers Data access layer Domain entities
hello world controller @Controller @RequestMapping("/status") public class StatusController { @RequestMapping(value
= "/", method = RequestMethod.GET) @ResponseBody public String status() { return "All looks ok from here! :-)"; } }
more complex controller @RestController @RequestMapping(value = "/movie") public class MovieController
{ @Autowired MovieRepository movieRepository; @RequestMapping(value = "/", method = RequestMethod.GET) public List<Movie> all() { return movieRepository.getAll(); } }
persistance entity @Data @Builder @Entity public class Actor { @Id
private Integer id; private String name; }
data access public interface ActorRepository extends JpaRepository<Actor, Integer> { }
rest data access @RepositoryRestResource(collectionResourceRel = "actor", path = "actor") public
interface ActorRepository extends JpaRepository<Actor, Integer> { }
run your backend @SpringBootApplication @Import(SecurityConfiguration.class) public class MoviecloudApplication { public
static void main(String[] args) { SpringApplication.run(MoviecloudApplication.class, args); } }
working project https://github.com/alexsimo/backend-low-fat