views:

236

answers:

10

I want to take the next step in java web development, I am hoping to get insight & feedback on: what my next steps should be and how best to take them.

While learning the basics of java web development, I put together a simple web app that performs simple accounting and financial calculations. The web app is on a single jvm, uses Tomcat, and has standard web functionality - i.e. login/logout, basic security, etc.

How can I make this web app more "enterprise ready" - distribute functionality of tiers over different servers/jvms, HA, balance-able, etc.

What do I need to know/learn? - i.e. EJB3 or Spring Framework (seems spring is better option), REST and/or SOAP, etc.

How would one recommend (books, websites, etc.) I learn the "requirements" (see preceding line)?

Thanks!

+2  A: 

A few things to consider, as food for thought:

  • How good is the error handling/logging of the application? For example, if the user tries to put in X in for a currency value, what does the application do?
  • What is configurable within the application from the user and what is in configuration files and what is in a database with regards to configuration? Do you have passwords encrypted within the application?
  • What patterns would used in building this application? Are there patterns you could see using now that you have a prototype?
  • Is this application ready to handle different currencies and languages?
  • What happens if someone leaves the screen for a few hours and tries to use a form?
  • What administrative functionality does the application have?
  • Does it handle the case where the user has JavaScript disabled?
  • What are the limitations of your application, IOW what can't it handle the way it is?
  • Have you considered trying to write a manual for the application?
JB King
+5  A: 

In my opinion, you should try different approaches for a same problem, so you could compare the pros and cons of different tools and frameworks.

For instance, try to build an application using EJB, and then the same application using Spring. Take the presentation layer of your code written with JSF and then rewrite it using Tapestry.

I think this will be very helpful to you, as you'll be able to make best decisions when choosing tools for your future developments.

Alexandre
You stated, "...try to build an application using EJB, and then the same application using Spring." Can you recommend any resources (books) that could help me learn Spring, so I can do in Spring the equivalent work of EJB3?To an extent, I've already played around with the presentation layer - I built the same component with different frameworks (Struts2, Stripes, and Wicket) to determine which one I wanted to use/learn first. Are there any in particular I MUST know?
Ari
I think this a god start: http://download.oracle.com/docs/cd/E11035_01/wls100/programming/spring.htmlAlso, I think the Spring Framework reference documentation is a good source of information. They do many comparisons with JEE to justify their choices, and even tells you when it's better to use JEE technologies instead of Spring.
Alexandre
+1  A: 

EJB or Spring? gets asked quite a lot nowadays, here's a decent related question about them.

Esko
+1  A: 

Have some real users using your application. You'll be amazed on how many "new" features/improvements can be performed in your app ( and the technologies you'll learn to satisfy those requirements ) by having real users using it.

OscarRyz
A: 

Hi Ari, I suggest that you create small java experiment projects for each new framework/library that you want to learn.

I've had good success using maven to help me quickly and consistently create java projects that I use to experiment with one technology at a time, such as Spring, Hibernate, etc. I use maven's site life cycle to record notes about what I learned and to document how to build and run each project. So, now I have 20 or so projects that I can use as baseline projects, one for each framework, to build upon.

Also, I prefer buying and reading books rather than relying on google and websites to learn new frameworks. Seems that I'm able to learn a lot faster this way.

I also suggest that you write web apps that you, yourself, would want to use. Or write a web app that solves a problem you've been having. I've found that I learn a lot more this way rather than simply copying and pasting from examples in a text book.

Hope that helps, - Dave

Dave Paroulek
Hi Dave,Did you try out Ant as well? Did you find Maven relatively easy or difficult to pick up? I too find (and prefer) reading books easier to learn, but at times I've been able to find great presentations, lectures, etc. online.Thanks,Ari
Ari
I used ant for a long time. While using ant, I tried using Maven as only a dependency manager. But if I had to do it over, I would just bite the bullet, learn Maven, and use Maven instead of ant. I found Maven to be confusing when I was just kinda-sorta using it halfway. But now, after reading the online maven book (just google for "maven book"), I find that maven is easy to understand and makes me more productive.
Dave Paroulek
A: 

Spring or Tapestry would be good options for new learnings. Does your app use any web services? If not work those in. Work with other application servers like JBoss and Weblogic and note their nuances with java. I'd also recommend learning Maven and work that into your build/deploy process.

Have fun, Mike

Mannix
By "Does your app use any web services? If not work those in." Are you asking whether my app consumes or provides web services? In either case, can you recommend any materials that would help me?Also, is Maven the way to go i.e. should I learn it over (or before) Ant?
Ari
+1  A: 

I would suggest the following books/tutorials are a must for every Java developer:

  • Manning: Spring in Action - 2nd edition
  • Manning: Java Persistence with Hibernate
  • Core JavaServer Faces
  • Adobe Flex ( Adobe website video tutorials )
  • Effective Java

Apart from the standard technologies above you must be familiar with

  • Different testing frameworks , JUnit is a must
  • Build tools like ANT and Maven

Also you can build small projects by downloading trial versions of MyEclipse or Flex Builder.

Priyabrata Hota
A: 

You could vastly reduce the time taken to build your apps by learning some Test-Driven Development.

Try learning JUnit - it's becoming a core skill now, even in unagile shops.

If you're focussing on the web, try out Selenium - which has a Java controller to drive your tests from Java test cases.

After investing a bit of time in TDD will pay off no matter which frameworks or apps you work on. If you learn to test drive your code, you'll end up with smaller, cleaner code and less debugging.

cartoonfox
I'm in the process of learning JUnit; I've become proficient, but not quite where I want to be with it.I briefly looked at the selenium site, seems useful; I'll have to investigate further.
Ari
It might be worth looking at Steve Freeman's new book (The co-author of JMock..) http://www.growing-object-oriented-software.com/
cartoonfox
A: 

You might look at AppFuse, which is a bundle of Java things together.

Or, you might take a look at a few more technologies to play with and add in:

  1. Version Control - SVN
  2. Tools - Ant or Maven
  3. Framework - Spring, Seam, Struts
  4. ORM - Hibernate or iBatis
  5. Test Driven Development - JUnit, Emma
  6. Continuous Integration - Hudson

I'd also read the Pragmatic Programmer and/or Code Complete.

Dean J
A: 

Allow me to state that "enterprise"-ready does not necessarily imply scale-out solutions, many, many enterprise Java applications are running on larger systems requiring long-running-systems skill of their own.

I recommend mastering the Java language and runtime, understanding how bytecodes and loading traverse the JVM vs. focus on any given framework.

Speaking of frameworks and if you really have the time, try recreating an application framework yourself. Try and re-invent the wheel. IMO it is an excellent lesson in why frameworks themselves exist and teaches one to employ the features instead of always trying to work around them.

One more thing, never forget the database. I don't care what that looks like Oracle, MySQL or NoSQL, but become also an equal master at the data store.

Xepoch
In my question, I intend you wouldn't happen to know of a shortcut? :-)
Ari
Like I said, take your thoughts (app distribution) and try creating the necessary glue from scratch, don't use an existing framework. Hands-down the best way to learn the the ins-and-outs of such things. Also, tiering your apps is one of many ways to "scale," but not the only, with massively-cored platforms here and on the horizon also understand how to scale within your own JVM.
Xepoch