We've now taken a look twice at this style of asynchronous communication and at this point you probably
have some really burning questions but this video I want to go over some questions I think you might
have and some possible answers.
The first thing you might be thinking is something like Wait a minute Steven you're saying that if we
have two types of resources so in our case posts and comments if we want to serve out that information
effectively we have to create a third service.
No that is not what I'm saying at all.
We are not always going to be creating extra services just for the sole purpose of joining data together.
In reality if we were actually building this sort of blog application it well this put blog application
will be part of a larger scheme of resources or a larger application.
In reality we would probably put this idea of posts and comments together in the same service so we
could join that data together at the code level rather than at the service level by creating a third
service.
So what we're doing right now is solely for learning purposes.
This is just to help expose you to these ideas of how we can have information stored in multiple services
and eventually kind of replicate that data or make use of it in one single location.
So I'm not advocating that you create an extra service for every last joint of data that you need second
big question you might have.
I've been saying many times that these services are independent and if one crashes the others stay alive
you might say who cares.
How often are these services going to be crashing.
Well at this point the Course I haven't really gone into a lot of reasons on why you would use micro
services in the first place to be totally honest with you I'm kind of assuming that if you're in this
course you've already done at least a little bit of research and you might have an idea of why you want
to use micro services.
One of the big reasons that we use micro services is the possibility of increasing the overall reliability
of our system.
That's a huge driving force in why we use micro services.
So the fact that we can make these things independent and keep the vast majority of our application
running even if some part of it goes down that's a huge driving force in why we are here learning about
micro services in the first place.
The third thing you might be saying OK this is way too complicated for the tiny bit of benefit that
we get where we're having to create entire new projects just to support these very basic data queries.
And I know it seems that way now I know this entire event style architecture might seem really complicated
and challenging but it really just seems like that at this point.
We're going to very shortly start to add in another feature to the project.
So the one we're working on right now and by taking this kind of event style architecture adding in
this additional feature is going to actually be somewhat darn easy compared to if we were using a monolith
or possibly some kind of synchronous style of communication.
So I know it seems like this is way over the top right now.
That turns out that some things down the line start to get a little bit easier.
The last thing on I mentioned here is that at this point if you are really starting to think through
this architecture you might be starting to say hey Steven wait.
This system is going to work in this scenario or what if this event occurs and that event or what about
this corner case over here.
Just be clear.
There are definitely some super special corner cases that unite need to be concerned about or very special
scenarios when we start using this event based architecture.
We are going to take a deep look at some of these problems and I mean a deep look later on INSIDE the
course and if you don't see anything wrong with this current approach I don't sweat it.
It's something you really have to think about for a pretty long time before we start to realize where
things start might start to go wrong again if you see some stuff to look a little bit funny right now
don't sweat it.
We're going to go over a lot of possible corporate case later on.
And we have solutions for a lot of them not going to say like every possible solution.
I'm sure you could think of some things that are going to go wrong that I have not thought of.
But again on that big application we're gonna work on later we're gonna look at a lot of these different
corner cases.
OK so that's it.
Just want to go over a couple of questions and answers that you might have had.
So with all that in mind let's take a pause right here.
We're gonna start to implement this new query service.
We're gonna start to set up this event bus and then have all these services communicating with each
other.
The events in the next video.