- In this video, we're gonna discuss the role
of a back-end web developer.
Now this is a part of a three-video series of videos
that I've released on YouTube.
Part one was one that I released previously.
Click on up here to check that out.
And that discussed the role of a front-end developer.
But this video, we're gonna talk about a back-end developer
in the typical role.
And also coming up after that,
the third video in the series,
I'm gonna discuss the pros and cons of each.
But for today, let's get started on the role
of a back-end web developer.
This video is brought to you
by the Learn Programming Academy's Python Masterclass.
Join close to 120,000 students
and get 42 hours of video training,
which will teach you Python the right way.
We have a massive discount and instant access
by visiting lpa.dev/YoutubePython
or by clicking on the link in the description of this video.
(light music)
Welcome back.
My name is Time Buchalka
with another programming tip of the day.
Right.
So, let's get stuck into it.
We're talking now about the role
of a back-end web developer.
All right.
So, a back-end web developer, unlike a front-end developer,
creates code that typically executes on a web server
on the Internet.
Now if you recall, a front-end web developer,
they create code that typically runs in a user's browser
on their computer.
So, basically it's executing on the user's computer
contrasting that to a back-end developer
who's typically creating code that executes on a web server
somewhere on the Internet, i.e., not the user's computer.
Now the back-end coder makes this layer or code
available or basically makes available key functionality
to the front-end developer or basically to any programmer
who needs to access it to perform specific tasks,
so things like accessing a database and so on.
But it's probably best served by an example.
So, let's go and check out
my Learn Programming Academy website again.
Now on that website,
I've got a list of all my programming courses.
Now when you visit this page here
and then you click on courses,
then it lists all the various courses
that I've got available.
Now the front-end code,
we're talking about how this code works,
then actually contacts the web server
and effectively asks for list of all the courses.
So, basically the code is calling the back-end code
and asking, can you give me a list
of all the available courses, in this case.
So, there may be no courses, there may be none,
or whatever number there is.
The back-end code, in this case,
basically opens up the database.
Now incidentally the database also resides
on that web server.
So, it's accessing that database locally
again on the web server, which is somewhere on the Internet,
and it retrieves the course information that it needs
and sends it back over the Internet
from the web server to the user's browser again
where the front-end code,
typically JavaScript or HTML, CSS, et cetera,
well, JavaScript is gonna be the code
that's executing to actually retrieve the information
and HTML and CSS is gonna instal that
and share it on the screen.
So, basically what's happening again is the back-end code
is sending the course information, I should say,
back to the front-end code, which then basically formats it
into a format you can see here on the screen
and shows the list of all the various courses.
Now scrolling the list of courses as I'm doing here,
that's a process of the front-end.
So, that's basically the front-end code
that's actually scrolling it.
It's already retrieved the information
from the back-end code at this point in time
and it's now basically starting it
and providing the nice layout and fonts and so forth.
But the ability to scroll that information,
that's coming from the front-end.
Now that's the case of if I'm retrieving all the courses.
But then if I click a link like this one here,
the Java Masterclass, if I click on a single link,
what happens is, after that click is made by the user
who's actually navigating the website,
the front-end code will again call the back-end code.
So, it's setting up a listen.
So, this time, instead of giving me a list
of all the courses, send me just a list or the information
for this one specific course.
And so, what happens again is that the back-end code
then goes back into its database, retrieves the data
from the database, in this case the details
of that one course, the Java Masterclass course,
sends the information back over the Internet,
back to the front-end code,
effectively being executed, remember,
on the user's browser or through the user's browser,
and then basically gives that information
or shows that information on the screen.
And you can see in that case there,
we've now got all the details about a specific course.
So, you can see what the back-end is doing here,
effectively the back-end code is exposing certain functions,
like in these two examples I showed you,
retrieving a list of all the courses
or also retrieving the details of a specific course.
But from the front-end code's perspective,
it doesn't directly access the database.
So, basically what's happening is,
it's quite going off in calling the code
that resides on the back-end and saying,
just give me a list of courses.
It's got no idea where that data is coming from.
It's just called a particular function
that the back-end code has made available
to the front-end to actually retrieve that information.
All right.
So, further to that, a lot of the key information
like retrieving data, which database is used, and so on,
that's usually hidden from the front-end code.
So, the front-end code again has got no idea
basically how that information came to be,
where it came from, whether it came from a database
or which database, did it come from MySQL database,
Postgres, or did it come from a text file
on the web server or somewhere else in the cloud perhaps.
The implementation, the bottom line here,
is up to the back-end developer.
What the back-end developer does is expose the functionality
to, in this case, retrieve a list of all the courses
or return a list of all the courses or a specific course.
Now obviously there's usually a lot more complexity to that,
but that's it in a nutshell.
And what that means is as a result of this
is that the back-end code could completely change the way
that it's stored and retrieve the data,
and the front-end code would still execute
and be none the wiser that anything's changed.
So long as the same call mechanism,
the same API call hadn't changed,
you'd still be calling it.
For the front-end developer, you'd call this function
and retrieve a list of courses
not knowing that the back-end code
may have completely rewritten that code
or used another database or accessed it from another place.
So, I think that's pretty cool,
the separation of concerns, if you will,
and the ability to basically be a boxed function,
if you will, and not have to know
how the back-end code works.
All right.
So, let's now talk about some typical programming languages
that would be used in back-end development.
Now some of the more common ones, PHP is one,
Java, C#, and Python, now that's just naming a few,
but increasingly today, runtime environments
like for example Node.js are blurring the lines
of typical front-end and back-end code.
And that's because they're allowing
what were traditionally front-end programming languages
like JavaScript for example to now run on a web server
and not just the user's browser,
which it typically used to do.
So, what that basically means is that you can now use
Node.js, which is effectively JavaScript,
for back-end development as well.
I think that's pretty cool.
All right.
So, this is back-end development in a nutshell.
And again just a reminder, the next video coming
over this series will be part three.
We're gonna go over the pros and cons
of both front-end and back-end development,
who gets paid more, and perhaps come up hopefully
with a decision you can make as to which way you should go,
whether you should be focusing on front-end or back-end
or basically even a combined role,
which is another possibility as well
because some people, some programmers, web developers
go for what's called full-stack development
where they're actually able to basically focus on both ends.
And we'll talk about full-stack development
in a future video.
Well, for now though, that's back-end development.
I'll see you in the next video.
All right.
So, I hope that helped.
If you've got any questions, feel free to leave a comment
and I'll get back to you.
If you're ready to look at the next tip,
click on up here and you can check that out.
If you're interested in coding-specific programming videos,
click on the link in the bottom left-hand corner.
Consider subscribing by clicking on the link up here.
And I'll see you soon.