Deploying the JEE6 Archetype

DZone 's Guide to

Deploying the JEE6 Archetype

· Java Zone ·
Free Resource

Well, the good news is it is possible to get the new Weld archetype to work. The bad news is, the process, at least to me, is a treatise on why the Balkanized Java ‘platform‘ is actually like a schizoid portrait in madness. And it‘s nobody‘s fault. I am deeply impressed by all the great stuff that the Red Hat team has pumped out in the past 5–6 years, but it‘s not enough. Why? Read on. Maybe it is enough for you.

Here‘s the simple recap:

  1. Generated the project.
  2. Tried to deploy on Glassfish and got spurious error, found out the logger classnotfounds were the real problem.
  3. Commented out the solder dependency and was able to get to the Hello World screen.

That was where I was as of the last post.


  1. Went back and could not believe I got the logger errors again.
  2. Double, triple checked that the solder dep was commented out in the pom.
  3. That there were no imports of the loggers.
  4. Did clean
  5. Removed and readded the app
  6. Restarted eclipse
  7. (Yeah does remind you of Windoze doesn‘t it?)
  8. Gave up on that.

Choices were:

  1. Go back to 3.0 and the original project.
  2. Go make an empty project and add the JEE6 dependencies.
  3. Try JBoss 6.

I opted for #3. Then:

  1. Downloaded JBoss-6.0.0.Final.
  2. Dropped in /usr/local, made a softlink to /usr/local/jboss6.
  3. Installed the JBoss Tools.
  4. Added it in the Servers view.
  5. Generated a new project from the archetype.
  6. Went to deploy.
  7. Got an error: data source was not found (JNDI).
  8. Read the readme a whole bunch of times. Found some disturbing things: a. it is written to have you deploy from the command line and b. it kept mentioning the need to deploy the default-ds.xml file. Who deploys resources files?

Then suddenly, the light came on: I am getting an error because of the heinous m2Eclipse nonsense about adding the filter on the resource files. Sure enough, there they were, then I went to deploy again (inside eclipse) and it didn‘t work, but for a new reason: the logger! Again! It was saying that the injection was ambiguous. OMG.

I gave up on that and went to the command line and got it to deploy. So the redux: gotta use JBoss and from the command line. Is that where I want to be after 15 years? Um, no. Sorry. Go ahead and flame me now for saying so.


From http://www.jroller.com/robwilliams/entry/deploying_the_jee6_archetype


Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}