30

I've been learning Spring and I'm really liking what I'm learning, but feel ill-equipped to do anything at the moment. I know Java really well, I'm ok at ant, but I don't know anything about: J2EE, JSP, Servlets, Tomcat, Maven, Hibernate, JPA, and I've never made any kind of website using Java (I've made lots of applications in Java, but all websites I've made were using PHP).

Should I cement some of my knowledge of the "basics" or should I keep slogging away at Spring?

ZoFreX
  • 8,812
  • 5
  • 31
  • 51
  • 2
    One thing you must know is that JSF is better than spring... You should really learn how java web applications work in essence, and then go for JSF. –  Oct 14 '11 at 16:50
  • 7
    comparing JSF to spring is not the first thing I'd do. They are complementary technologies – Bozho Oct 14 '11 at 16:54
  • May be different aspects & concepts of Web Enterprise Application. – jmj Oct 14 '11 at 17:01
  • 2
    @djaqeel "Better" is subjective, depends on the nature of what you need, and arguable. Telling someone that without any context or discussion is irresponsible. – Dave Newton Oct 14 '11 at 18:18
  • 4
    @djaqeel: Comparing JSF with Spring is indeed pretty off. JSF is a component based MVC framework and Spring is a **huge** framework with a lot of subframeworks. Even when you intend to compare JSF to Spring **MVC**, it would still be off. Spring MVC is a request based MVC framework, not a component based one. Each has its own (dis)advantages. See also http://stackoverflow.com/questions/4421839/what-is-the-need-of-jsf-when-ui-can-be-achieved-from-css-html-javascript-jquery – BalusC Oct 14 '11 at 18:27
  • 2
    @BalusC Thanks a lot, and thanks to others who commented on my comment. Agreed to BalusC. But wait...my comment is NOT irresponsible since it brought up your comments :D :) –  Oct 15 '11 at 13:18

4 Answers4

16

Spring is a monster. It all depends on what part of Spring you are interested in. A good starting point would be the Dependency Injection container, which requires none of the technologies that you are unfamiliar with (the ones from your question).

If you are interested in learning Spring MVC (which it sounds like you might be based on the technologies you mention), I would recommend learning the basics in these (again from your question):

  1. Servlets
  2. JSP
  3. Tomcat (or another web application container)

For Spring MVC I would also look at the idea of RESTful web services.

You can find a (likely) comprehensive list of Spring projects at this link.

nicholas.hauschild
  • 42,483
  • 9
  • 127
  • 120
  • 4
    I can't add a new answer so I'm tagging onto the top one. Since I asked this question two years ago, things have changed a LOT in Spring land. If someone asked me this question today, I would tell them to check out Spring Boot and its associated documentation - you need absolutely no prior Java web framework experience to dive in and start learning. (Obviously you may need to learn things as you go on, but you can at least get started with no prior knowledge) – ZoFreX Dec 06 '13 at 17:13
10

I would recommend three things:

  • Lots of Reading => Spring Documentation in a Single Page

  • Lots of Coding => You can start off by getting an example Spring / Hibernate project. And then use Spring Tool Suite, which includes many interactive tutorials, and template projects that just work without any coding at all.

  • Find a Spring User Group next to the place you live. If there is no such group => create one!

It is totally ok that you don't know JSP / Servlets / Tomcat / J(2)EE / etc. Extremely smart people who, for example, write Linux kernel (which is a lot more complex) may not know it as well. The beauty of Spring is that going through it, and reading about best patterns and approaches you'll get all the above. No need to learn J(2)EE separately. Spring is J(2)EE of today.

tolitius
  • 22,149
  • 6
  • 70
  • 81
  • That said, today's JEE is really quite nice, and may be all you need for a wide range of problems. It's no longer possible to dismiss it as we once could. – Dave Newton Oct 14 '11 at 18:20
  • @DaveNewton, today's JEE is playing constant catchup with Spring, and it is still well behind. The only thing that is _nicer_ is EJB 3.0, but only _than_ EJB 2.0 and EJB 1.0 – tolitius Oct 14 '11 at 18:27
  • You're stating opinion as fact. Bottom line is that a lot of the reasons Spring was created are no longer an issue, and a lot of applications simply don't need the additional libraries. – Dave Newton Oct 14 '11 at 21:09
2

For a good enterprise developer, I would recommend

a) very very good core java ( including collections, jdbc , threads) b) servlets

Then I think you can start diving into spring.

java_mouse
  • 2,069
  • 4
  • 21
  • 30
0

If you want to accomplish something quickly to start with, definitely look at JSPs. A JSP is basically an HTML document with some special <% %> tags where you can just shovel in java. It's really entertaining, although nothing you'd want to use for a large-scale application.

andronikus
  • 4,125
  • 2
  • 29
  • 46