Вы находитесь на странице: 1из 16

06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Talha Ocak Follow


Software programmer and triathlete.
Jan 23, 2016 14 min read

How to become an expensive Java


developer by self learning?

New graduates and under graduates slog on nding the correct way
for becoming a Java full stack expensive developer. For a stranger,
Java environment may seem so complex and foggy. In fact, this is the
case for experienced ones. This is because rapidly changing
requirements of business world. I will try to explain what is used in
the business world to let you spend your time on most important
technologies.

You may use guide to build your knowledge without losing your way.

1. Java language itself

You need to know how to write a simple console application with


Java.

First step is basic syntax, basic control structures like if statements, for
loops

Then you learn about object creation, object references, methods,


passing parameters to methods.

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 1/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Third step is to use built-in classes like Date, String, Calendar and
Number classes and most of their methods for simulating real world
values in programming.

Then you learn collections for ltering, sorting, grouping lots of


objects.

Here is a deal for you: Learn Java 8 and functional


programming with my course; take next steps upon a
concrete knowledge by taking this 20 hours
videocourse:

https://www.udemy.com/java-8-core-training-/?
couponCode=MEDIUMSPECIAL
2. Object oriented programming

Java is mostly an object oriented programming. That means the rst


class citizen of the environment is object or data. Any attribute or
behaviour of an object is attached directly to the object. The relation
between dierent objects, their hierarchies follow some standards.
Anything you will use in Java environment will apply the same rules.
So you need to become familiar with data encapsulation, inheritance,
abstraction and composition terms.

3. HTML programming

HTML is used for constructing a web page that can be displayed in a


web browser like Chrome, Safari etc Regardless of the language you
use for server side, only HTML is used for front end. Because HTML is
a markup language independent from all other programming or
scripting languages.

You may put input elds, buttons, images etc by using HTML tags.

4. Javascript programming (Optional)

No need to say, there is no relation between Javascript and Java


except some name similarity. Javascript is the front end technology
for modifying the HTML output of a page on client side. (Reclaim for
ones who are not beginners: I can not talk about NodeJS, AngularJS
etc at this point..)

So a basic understanding of Javascript is required to create a more


alive web page.

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 2/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

If you got the basics of Javascript, learn a Javascript library for easing
the tasks and prevent boilerplate (repeating over and over again)
codes. The most popular libraries are: JQuery and Sencha.

5. CSS (Optional)

CSS is a special styling language to beautify the HTML pages and


arranging the HTML elements on the page. Before proceeding to next
steps, it would be good to have a supercial knowledge on CSS.

6. HTTP protocol

Any web page displayed on a browser communicates with the server


side with HTTP or secure HTTP (HTTPS) protocol. Communication is
bidirectional that is the page rendered on users browser sends data to
your server application and get data from it via HTTP protocol.

HTTP has GET and POST verbs for operating. You must know the
dierences between these verbs and the cases they are used.

7. Servlet

The simplest server-side element of Java Web (JavaEE) is called as


servlet. Servlets are the endpoint of a HTTP channel. The other side
of the channel is the users browser. So you may assume HTTP
channel as a bidirectional pipe between users browser that is
displaying the HTML page you serve and the servlets you serve at
your server.

Servlets get the users requests as HTTPServletRequest objects and


they may return some data by using HTTPServletResponse objects.

8. JSP-Java Server Pages

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 3/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

JSP is the simplest user interface (front-end) element of Java EE. The
data which is prepared by a servlet is shown on a JSP page. JSP page
is an HTML page which contains some special markups (Java-
specic markups ) that servlets understand and interact
bidirectionally. Whatever you put inside a JSP page is converted
to HTML page before sending the page to users browser. As I said
before, a browser can not execute a language-specic tag but only
HTML tags.

9. Servlet containers or application servers

Java web technologies rely on JSP and Servlets. Any other complex
frameworks are built on these technologies.

JSP and servlets require some special software to execute. For


instance an HTTP request coming from the browser is converted into
HTTPServletRequest and passed to the related servlet by a servlet
container. Similarly, the result is written into HTTP channel by the
help of the servlet container again. Also, special JSP tags are converted
into HTML tags after being processed by the servlet container.
Application servers manage multi-threading so that parallel requests
and responses do not mix each other. (This is called as
synchronisation of the resources)

Thats why you need to learn how to put your JSP-Servlet application
into a servlet container (called as deployment) and their basic
management.

The simplest and most popular servlet container is Apache Tomcat.

While you gain experience, you will need more capability and Java EE
features. In this time, you will switch to application servers. (Which is
simple servlet container plus much more professional tools)

10. AJAX Asynchronous Javascript call

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 4/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Any modern web application uses AJAX (asynchronous http request)


eectively. Let me explain what is asynchronous and synchronous
rst.

The lifecycle of an HTTP request is synchronous by default and runs like


this: Lets say you are a user and displaying a web page and you need to
post your personal information to register the system. In this case, you
are lling an HTML form and the data inside the form is put into a http
request and send to the server by an http connection. The server side logic
process the data, maybe gather some information and return the result.
This is important, the result must be a totally new page. Totally. I mean,
what you entered into the form can not be seen by the client anymore. (If
you did not write special codes for this as a web developer)

So synchronised HTTP lifecycle ends with a totally new page (without any
exception) and cause all the previous data lost.

But modern applications must send/get some data to/from a server


without changing the page, losing the existing data on the page. For
this, HTML page need to communicate with the server side
asynchronously. This calls are made by AJAX technology. So AJAX is
a must-learn item.

11. Databases

Regardless of the language, to store data and get it back, you need to
use a database. Nowadays there are two options: Relational databases
and document based databases.

Relational databases are the most traditional and most widely used
one. Oracle, MySql, PostgreSQL are widely used relational database
systems.

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 5/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Data is stored in tables which has a predened structure. Each tables


data is related to some other via keys. (primary keys and foreign keys)

These tables and the data inside them are read, manipulated and
deleted by a special language called as SQL. SQL must be studied
hard because it has so many features such as grouping, ltering,
combining data.

After learning SQL, you need to study database normalisation which


means the breaking a huge data set to smaller chunks for preventing
data repetition.

Here is the best-seller course for SQL learning. I highly recommend


this course.

Document based databases are the modern way. Unlike the


relational databases, they do not use database normalisation and
transactions. Instead of database tables, they are stored in les that
contains lots of JSON objects. Huge data is not separated into smaller
structures so that getting a huge object from the DB is speed up. The
cons of document based system is the search time for an object is
much more than the relational databases.

Most popular document based systems are MongoDB and CouchDB.

If you want to work inside a startup or a trend-follower enterprise,


learning document based databases is an important plus.

If you will work in a enterprise company, possibly you will use a


relational database (RDBMS) so you need to learn database
normalisation and SQL language.

If the company is using Oracle, you will need to learn Oracle specic
SQL queries also.

12- Connecting Java application with database system

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 6/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Regardless of the database system type, you will need to make the
java application and the database communicate. For this, you need to
learn JDBC. (Java Database Connectivity)

JDBC deals with all the low-level operations so that you can manage
the data easily.

13- Managing the database connections more optimized

As your web application grows up, you will need to learn to use your
machines resources more eectively. Most memory and time
consuming steps of an operation is the management of DB
connections. To save some time and memory you need to create DB
connections before running the application and use them later on.
When you are done with the DB connection you should clear the
connection and put back to the place you get it so that other user may
reuse it. This is called as connection pooling. In JavaEE projects it is
done by c3p0 library mostly.

14- Switching to application servers.

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 7/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

At this point you are using servlet container named Tomcat for
executing your servlet and JSPs. But from now on you will use more
complex systems called application servers. They have the connection
pools internally and manage them by their own. Since managing the
connection pools and database transactions are error-prone, you need
to switch one of the application servers. The options are Wildy
(formerly JBoss), Weblogic etc

When a connection pool is managed by an application server, it is


called as data source.

These application servers have many congurations so you need to


spend some time on one of them and learn how to congure. After
that you may stick with the one you chose.

15- Model View Controller Pattern (MVC)

Some methods distinguishes the cheap developers and expensive


developers. There are a bunch of items like this.

First one is using the model view controller. It simply says you need
to separate the concerns for displaying data, data itself and the
units that process the data and none of them may leak into other
one.

Some frameworks force using this pattern.

Here is a great deal for you. Get my best seller video course covering
the sections from 6 to 14 with a great sale:

https://www.udemy.com/java-web-developmen-with-real-world-
development-ow/?couponCode=medium

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 8/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

16- MVC frameworks:

Struts 2, Spring MVC and similar frameworks force using MVC


pattern. Nowadays the strong option is Spring MVC. Struts 2 is also
used inside older projects.

17- Spring and Dependency Injection

For the server applications to serve thousands of parallel users, server


resources such as memory and CPU is really critical. For this, a
created object must be reused and should be used as long as possible
and reasonable.

This reasonable life of an object is dened by scopes. There are


several scopes in Java EE. For instance the objects in request scope
live as long as the request lives. When the request is destroyed, all the
objects sticked to must be killed. Other scopes are page, session,
application etc

Managing the lifecycle of objects in dierent scopes is somehow hard


and error prone. To prevent possible errors we invert the control to
other systems. This is called as inversion of control or
dependency injection.

By using a dependency injection provider, you only dene the scope


of an object and all the lifecycle is managed by the provider.

The options you may use is Spring (open source and wider usage) and
CDI (Java EE standard and narrower usage). You may choose one of
them and spend tens of hours on it.

18- ORM tools

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 9/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

This is a controversial part of Java EE development. Some calls ORM


(object relational mappings) tools as over-engineering and stick with
traditional JDBC.

As you know, all data in Java environment is object instances. But


data inside relational databases are scalar (totally separated number,
date, text values). To combine the related data inside an object we
need to write manual code or may use ORM tools. Alternatives are
Hibernate and pure JPA.

For Hibernate you should learn; associations and mapping between


objects (one-to-many etc), Hibernate session
management(replacement of database connections),

19- Spring-ORM tools combination

ORM classes must be managed by Spring in a professional Java web


project. Otherwise managing the connections, ORM sessions,
database transactions and data caching may be a cumbersome.

So much time may be spent to learn for this combination.

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 10/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

20- DAO ( Data Access Objects)

All database operations namely create, update, delete, read (CRUD)


related to a table should be inside a class. For each table, there should
be a separate class ( may be a parametrised class) and the DB
operations should be wrapped together. This objects are called as
DAO.

All DAO objects should compose a DAO layer for all DB operations on
all DB tables.

21- View-Service-DAO layer architecture

This also distinguishes the cheap developer and expensive developer.


A professional developer must separate the concerns with view-
service-dao layers.

View layers must deal with data visualisation and user interaction.

Service layer must process the data coming from either the user or DB
and process it.

DAO layer should interact with the DB.

None of the layers should do anothers job and no code must leak to
another layer.

22- JSF (Java Server Faces):

Most of the airlines, insurance and banking companies are using JSF
framework. JSF +CDI is the alternative of Spring MVC + Spring

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 11/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

stack.

JSF encapsulates JSP, Servlet, AJAX calls into a very easy component
framework. We can access the server side from the client side as if the
server objects are plain Java objects. We can invoke a method of an
object as an AJAX call. This is great, really great.

JSF projects composed of an XHTML view (page) and a managed


bean that the view communicates. This managed bean is managed by
CDI. So study how to dene a simple Java object as a CDI Bean with
annotations. Also work on how to let CDI manage the lifecycle of this
managed beans with scopes such as request, session and application
scopes.

Here is another deal: Learn JSF in details with me only for $7.

https://www.udemy.com/java-server-faces/?couponCode=medium

23- Primefaces

JSF is a great framework but its look and feel (visualisation) is not
that good. Primefaces uses JSF framework underneath and
encapsulates it with really cool components. Learn it.

24- XML and JSON:

Dierent web modules or applications send data to each other with


two types: XML and JSON. You need to learn the structure of JSON
and XML objects.

Later on, you should be able to convert JSON strings to Java objects
and Java objects to JSON strings. You may study GSON library or

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 12/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Jackson library. I prefer GSON.

25- Web services

Data is the critical item of any web application, also the precious one.
You sell data, you buy data This is the modern web world.

Since database is isolated from the outside world, access to it is not


exposed to the outside world. Only the allowed portion is exposed.
This data is mostly in JSON or XML format.

This is done via web services. Web services, exposes the desired data
to 3rd party and all the requests are tracked, priced, authorised
according to your needs.

Thats why you need to learn how to create a web service for your
application.

Regardless of the language, there are 2 common web service types:


SOAP and RestFUL.

SOAP is the web service type that is using Remote Object Procedure
Call and runs on many protocols.

Restful is the web service that is designed for HTTP protocol and
HTTP verbs.

Restful web services are the modern type and used by most of the
huge companies like Facebook, Twitter and Google.

So, it is good to know how to develop a RestFUL web service by JAX-


RS specication. You may learn Spring MVC or Jersey 2.0

26- Android Development

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 13/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Mobile client development is a must-know for a full-stack developer.

In Android development, managing all the Android versions running


on a wide variety of devices is the hardest part. So you need to learn

1- Android API management. One of the hardest part in Android


programming is the dierent SDKs for dierent devices. Google
publishes new SDK (software development kits) with new features for
newer devices and for backward compatibility, publishes several
support libraries. Managing these dependencies and SDK versions
require a solid understanding.

2- User interface creation with LinearLayout and RelativeLayout and


us them in Activity objects.

3- Using Intents to start new Activity instances and passing data


between Activitys and Services.

4- How to create list views with custom adapters and ViewHolder


pattern

5- How to use AsyncTasks to execute asynchronous jobs without


interrupting main thread. AsyncTasks are use mostly for interacting
with web services.

6- How to start background tasks such as playing an MP3 or running


an upload process without interrupting the user interface.
Background jobs are really long jobs like a bluetooth connection or
MP3 playing. AsyncTasks are more limited, one-time tasks in simple
words.

7- How to schedule a task that may run periodically

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 14/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

8- How to get the result of an AsyncTask with receivers and using


IntentFilters for dispatching the results,

9- How to use Google Play services such as Google maps, Google+


login system,

10- How to interact with hardware of the mobile device(camera and


GPS), how to make

11- How to make DB operations on SQLite database

12- How to publish the application.

Here is a great course for learning Android Marshmallow from Tim


Buchalka.

27- Built tools:

Java has several third party libraries developed by several dierent


companies and teams. Using these libraries eases your jobs. So you
need to include them into your project with some really cool tools.
These tools help you include libraries, compile the code and package
your application. Even you can test some modules and deploy the
package if all the tests are passed.

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 15/16
06/03/2017 HowtobecomeanexpensiveJavadeveloperbyselflearning?

Most common tools are Maven and Gradle. Gradle can be used in
both Java web projects and Android projects.

. . .

Dont forget to join the Javathlon


community for future advices:
https://www.facebook.com/javathlon

https://blog.javathlon.com/howtobecomeanexpensivejavadeveloperbyselflearningc00503d0913e#.hxahobfc3 16/16

Вам также может понравиться