Building Microservices with Node, Docker and Nginx pt 2 - Making a Microservice

  Рет қаралды 35,407

Fredrik Christenson

Fredrik Christenson

Күн бұрын

Пікірлер: 47
@sujeetagrahari2292
@sujeetagrahari2292 5 жыл бұрын
It's very rare you find a tutorial where people tell you something by their heart. Why I am saying that because most of the people are here to boost their business, advertise their premium courses and other stuff. No one talks about best practices, I don't know why. Thanks for sharing your experience, I see it that way. Passing information and experience to others in purest way, thanks.
@martindimitrov8547
@martindimitrov8547 5 жыл бұрын
Dude, this is pure gold. Thank you!
@FredrikChristenson
@FredrikChristenson 5 жыл бұрын
No worries m8, glad you enjoy the video! Have a great day and thank you so much for watching!
@andreigatej6704
@andreigatej6704 3 жыл бұрын
It is a great feeling to watch this after a while and finally understand what's going on. I remember the first time I found this video, I was both enthusiastic and confused(which is also an interesting feeling), but now.. things start to make sense. Thank you!
@AphixDev
@AphixDev 3 жыл бұрын
Best explanations out there man, this is the best tutorial I've ever watched! (And trust me, I've watched a ton)
@saporito_eth
@saporito_eth 4 жыл бұрын
This is the best free tutorial series I've ever come across, it's exactly what I'm looking for: to the point and gets all of the important things across along with some extra tips and tricks Thanks!
@Danutz13bv
@Danutz13bv 5 жыл бұрын
The story about the 9min response time is from a conference talk called "avoiding microservices megadisasters". It's on KZbin and it's very interesting, worth checking it out.
@mysteriousmsn
@mysteriousmsn 2 жыл бұрын
Best video...Microservices + bonuses explained well....!!
@mattkirby207
@mattkirby207 2 жыл бұрын
Incredible. Amazing tutorial, well done!
@alex_chugaev
@alex_chugaev 5 жыл бұрын
Priceless tutorial, thank you so much
@hectorflores1176
@hectorflores1176 4 жыл бұрын
I dont why people unvote this kind of videos, are made better than paid ones
@mariemjabloun4500
@mariemjabloun4500 3 жыл бұрын
This is a great talk, so simple and amazing with good tips. Thanks :)
@dejo095
@dejo095 5 жыл бұрын
Thank you very much for this excellent explanation.
@tdias25
@tdias25 4 жыл бұрын
Another great video, please do one about SOA, and the differences x microservices also, did you already started with calisthenics? get on it! lol
@siddharthsonone5751
@siddharthsonone5751 4 жыл бұрын
Best tutorial ever,
@aranyadas5919
@aranyadas5919 4 жыл бұрын
Maybe a .dockerignore file would have helped?Beginner here.New to both docker and node.But are we not supposed to exclude Dockerfile and node_modules folder when building a docker file?
@giorgibatsiashvili4270
@giorgibatsiashvili4270 5 жыл бұрын
just what i was looking for
@FredrikChristenson
@FredrikChristenson 5 жыл бұрын
The monolith will scale up to a size where you will find it hard to work with other developers on the same code and that is when it becomes a good idea to split it into more services but the monolith will almost always start out as a simpler solution. If you go for Microservices in the beginning of the project you will spend more time on maintaining the services and setting up infrastructure and that is time you should spend on feature development. You can always migrate to Microservices when the time is right but starting on day 1 is like building a super highway for a small town when what you need is a simple dirt road. Have a great day and thank you so much for watching!
@crowdozer
@crowdozer 5 жыл бұрын
You can scale your monolith easily if it's containerized. For example, you can use a cloud based autoscaling SQL service for your database and you can spin up multiple instances of your monolithic containerized app behind a load balancer with ease. Google cloud makes this particularly easy and hands-off. AWS and Azure have similar services. It's not a replacement for the separation of concerns and ease of maintenance that a properly set up microservice can bring but it's a viable option, and might even be one you can use while performing the transition.
@Mona001-01g
@Mona001-01g 3 жыл бұрын
Could you make a video on difference between service and api?
@FredrikChristenson
@FredrikChristenson 3 жыл бұрын
Each term has a wide meaning that you can look up if you want the semantics. For normal day work you can think of service as the server running code you need to use. The API are the endpoints the service exposes so your system can connect to the server.
@elyu_vibes
@elyu_vibes 5 жыл бұрын
What would you suggest for api versioning with my current structure? ------------------ app.js const deviceRoute = require('./routes/device') app.use('/api/v1/device', deviceRoute) ----------------- device.js (route) const deviceController = require('../controllers/device') router.get('', deviceController.getAll)
@FredrikChristenson
@FredrikChristenson 5 жыл бұрын
Using a path version number is fairly standard and works perfectly fine if you ask me. If you are working with services I suggest you add the commit id as the image version. Have a great day and thank you so much for watching!
@elyu_vibes
@elyu_vibes 5 жыл бұрын
@@FredrikChristenson Thanks! Is it ok to have my frontend along with nginx? Or have it in a separate container? My frontend is just pure html/css/js
@RUSGALEDON
@RUSGALEDON 5 жыл бұрын
love it! When is k8s coming ?
@FredrikChristenson
@FredrikChristenson 5 жыл бұрын
I haven't planned anything specific to k8s as it is not really needed to grasp how services work or how architecture works. Have a great day and thank you so much for watching!
@tuttocrafting
@tuttocrafting 4 жыл бұрын
I would love to have a more advanced example of microservices communication. (Maybe with rabbitmq) For example: if my services have all it's own database, but all requie authentication and I have users how can I manage that? Should I replicate the UserID to have the foreign key constraint valid?
@FredrikChristenson
@FredrikChristenson 4 жыл бұрын
The common way to validate users is to have a validation service. That service gives out a bearer token that can be used to access the other services. Usually this is only needed in a large application. Otherwise it is simpler to use a session cookie with a shared session database.
@beunmin6
@beunmin6 5 жыл бұрын
Thanks man!
@vijay1438ful
@vijay1438ful 4 жыл бұрын
Hi Great tutorial ,How can we keep model folder common for all services ?
@FredrikChristenson
@FredrikChristenson 4 жыл бұрын
Publish it as a npm package.
@vijay1438ful
@vijay1438ful 4 жыл бұрын
@@FredrikChristenson Thanks Bro for replying
@hvintik
@hvintik 5 жыл бұрын
Will it work if we move models in separate folder and copy it in each image in Dockerfile?
@hvintik
@hvintik 5 жыл бұрын
it seams to be working, I just defined volume for each microservice, so all they use models from one place volumes: - ./web:/usr/src/app - ./models:/usr/src/app/models
@Arm924
@Arm924 6 жыл бұрын
Great!
@hemantjoshi8388
@hemantjoshi8388 6 жыл бұрын
Can you provide github link?
@FredrikChristenson
@FredrikChristenson 6 жыл бұрын
Sure m8! github.com/fChristenson/microservices-example Have a great day and thank you so much for watching!
@MrDelhiite
@MrDelhiite 6 жыл бұрын
Here -> github.com/fChristenson/microservices-example
@pjmclenon
@pjmclenon 4 жыл бұрын
hello it seems in your code when speaking at pointing to localhost or other IP you use the .env file but i dont see it, thxz Lisa
@pjmclenon
@pjmclenon 4 жыл бұрын
because just to expand on my previous comment , iwas inanother project and when i was testing tutum/hello-world image i could not bring it up in the browser in localhost:3000, i had to use 192.168.99.100 or any IP from 1 to 100 since i had put that whitlist rule in my firewall..so do i have to put localhost as docker IP in my firewall?..not sure if it relates to this vid Lisa
@pjmclenon
@pjmclenon 4 жыл бұрын
i am using docker toolbox on my win 10 because for some reason hypervsior no longer works and i cant use docker desktop and so in toolboz i use kitematic GUI and CLI and it use Vbox as a linux base default OS
@llupRisingll
@llupRisingll 5 жыл бұрын
This isn't in your playlist
@szeredaiakos
@szeredaiakos 5 жыл бұрын
Your 'search solution is sub-optimal and you should leave message queues to messages not - what it is, essentially - index data. Here is a couple of better solutions: - Set up an ftp server on search in which books and videos dump their index data regularly. Read that data and update your local DB on search. Bad: latency on adding and removing items from search. Good: impossible to break. - set up a data pump (similar to oracle's idea or) on books and videos towards search and move an operations cache over either realtime or periodically. Bad: you need a periodic sync jobs. Good: less latency on item changes. Reasoning: failing to open up a particular 'book page (for ex) has significantly less implications than having no books in your search. Storage is cheap, data duplication is a non issue. (Orchestration is a temporal bandaid before fusion or decoupling solution. Same with choreography.)
@Treegrower
@Treegrower 5 жыл бұрын
This is a detailed video of how to dockerize microservices. It's not a video on optimizing a basic search demo.
@szeredaiakos
@szeredaiakos 5 жыл бұрын
@@Treegrower I know that. That's the reason why i commented/liked ;)
@Treegrower
@Treegrower 5 жыл бұрын
@@szeredaiakos I'm just saying it's kinda offtopic and unrelated.
@abhijeet1719
@abhijeet1719 5 жыл бұрын
BRO i NEED HELP
My Daughter's Dumplings Are Filled With Coins #funny #cute #comedy
00:18
Funny daughter's daily life
Рет қаралды 30 МЛН
1 сквиш тебе или 2 другому? 😌 #шортс #виола
00:36
Watermelon magic box! #shorts by Leisi Crazy
00:20
Leisi Crazy
Рет қаралды 115 МЛН
Introduction to Microservices, Docker, and Kubernetes
55:08
James Quigley
Рет қаралды 1,6 МЛН
MicroServices, RabbitMQ, CQRS and Event sourcing with Node
34:48
Fredrik Christenson
Рет қаралды 16 М.
Deploying MicroServices with Kubernetes Nginx Docker and Node pt1
24:44
Fredrik Christenson
Рет қаралды 4,2 М.
The hardest part of microservices is your data
46:05
Red Hat Summit
Рет қаралды 178 М.
Scaling Your Node.JS API Like a Boss (Part One)
47:04
Volkan Özçelik
Рет қаралды 26 М.
Tech Talk: Server Scaling in Node.js
12:05
Fullstack Academy
Рет қаралды 88 М.
My Daughter's Dumplings Are Filled With Coins #funny #cute #comedy
00:18
Funny daughter's daily life
Рет қаралды 30 МЛН