Search code examples
javaoracle10gweblogic-10.xjava-ee-5

Java EE 5 Development Environment


I've got a client who already has some applications in production and therefore has already made some decisions about what their production environment will be for this next project:

  • Sun iPlanet 6.1 SP7 (w/ apache)
  • JDK 1.6
  • Oracle Weblogic 10 MP3
  • Oracle 10g
  • 1024-bit SSL

They also have some corporate standards for web apps:

  • Tomcat
  • Struts
  • Compatibility with Safari, Firefox, IE6, IE7

I'm also told that this app will likely not need a full on Java EE 5 environment (probably only a web container), but will need to communicate with one hosted on a separate weblogic instance via client EJB's etc as well as perform various web service calls to other corporate services.

I've been given the task to make some decisions about what our development and test environments will look like for this new team (small, probably 2 or 3 people including me, but may grow over the coming months). I want to create one where people can use the IDE they love and have a good development experience on localhost, but still have a smooth path to deployment in a test environment, and then again to the production environment. My thinking is that on local workstations http is fine but the integration test server should look exactly like the production server, and all traffic should be https to make sure we are getting an accurate portrayal of what prod will be.

Knowing that devs local workstations will be highly varied and may be running Mac OS X 10.6 (Snow Leopard) or Windows 7 on their local workstations, but a common test server would also need to be spec'd out: what technology stack would give us a nice smooth path from local development, through test, and into production?

EDIT: Sorry, when I say technology stack I mean for example Ant + JBoss + Tomcat + Oracle XE vs. Maven + Geronimo + Derby. Basically a list of the concrete specification implementations that we will need to install on each development machine and the test server that gives us a flexible dev environment, and a smooth transition to test and production environments.

EDIT2: It's probably worth mentioning that this app, if it needs to persist any information at all (which I am assuming will be the case), whatever it is will definitely not be complicated. In all likelihood it will be something akin to a rudimentary product database.


Solution

  • I would go for:

    1. Hudson for nightly builds (or for every checkin)
    2. Mercurial or Subversion for source control (works great on both Windows and Mac)
    3. Spring, Spring, Spring. Yes I am serious, Spring solves many more problems than just dependency injection; like security, batch processing, transactions handling, system integration.
    4. EclipseLink for ORM. It's many advanced features (that Hibernate lacks) have often saved me (like decent Stored procedure support).
    5. A light weight container like Jetty, Tomcat or Resin. You are going to commit teamicide if you use heavy slow stuff like Geronimo or JBoss.
    6. DeltaWalker for merge/diff tool (again works on all platforms).
    7. If you are going to use advanced database features then go for OracleXE (and SQLDeveloper). Both are nice tools. If not then something light like H2 or Derby is fine.
    8. JUnit (or TestNG) and Mockito for unit testing/mocking.
    9. Please don't use Struts. Seriously, at least go with Struts2 or preferably something like JSF2, Stripes or GWT.
    10. A decent bugtracker like, JTrac, RedMine or FogBugz
    11. Selenium for integration testing
    12. Sonar for code quality

    If you are going to use different IDEs then Maven might be a good idea, since it allows each IDE to be configured from the pom.xml (works great in IntelliJ/NetBeans). But the best advice I can give you is this.

    • Go with what you already know and have experience with. You do not transit from Struts to JSF2 overnight.
    • Get the best tools you can get, seriously free stuff is not always the way to go (although it often is).

    Happy hacking