- [Instructor] In this chapter, we will build out
the service registry that keeps track of available
micro services and let's us query them to access them.
In (mumbles) files you find a folder service registry
in the provided sub folder.
This will serve as a starting point for everything we're
going to do now.
I've already copied that to a fresh directory
and opened it in Visual Studio Code.
Its foundation we are using the Express framework.
Express is a well-known framework for building websites
with node.js but it can easily strip down to provide
just what is needed to create a rest based service.
In bin run you'll find all the logic needed for running
the server.
In config index.js you'll find the basic configuration
module that will set up proper locking using bunyan
as a login engine.
Additionally, you're also reading out package.json
to find out the version in the package name of this
particular application.
In server service.js you'll find the actual expressed
application setup.
First we initialize express and then you can see that
we don't really do much here.
I omitted all the middle (mumbles) that you would usually
have in an Express application, no cookies, no (mumbles),
no (mumbles) and we also don't need to set up
a template engine.
Additionally our instant (mumbles) configuration,
you just need to make sure that the code I write
abides to some basic standards and is free
from well-known flaws.
To initialize the project now I'm running npm install
and you have to do that for all the provided files
in this course always.
And when this is run all the dependencies are done,
I can run npm start and this welcomes us with a friendly
log message.