7

I have the WTP 3.1 plugin installed and have also installed the Glassfish v3 plugin. I am able to register my server.

When I create a dynamic web project, I can see that the maximum dynamic web module version available is 2.5. I then choose the default configuration for Glassfish v3 but, when I look at it JSF, it is not selected by default. When I select it, the maximum version available is 1.2.

I want to use JSF with facelets - does Eclipse support this? I can't seem to find anything helpful on the Eclipse WTP site.

4 Answers 4

7

Java EE 6 / JSF 2.0 is relatively new. Most tools are already ready, but Eclipse has to catch up it yet.

The status as far:

  • IntelliJ Ultimate Edition was early in this. Unfortunately not freeware. Note: the free Community Edition doesn't provide tools for much of Java EE, let alone JSF.

  • Netbeans 6.8 came a bit later almost full Java EE 6 support, including JSF 2.0.

  • Eclipse for Java EE planned to support Facelets in Galileo, but it was cancelled and postponed to the successor Helios which is currently in one of its latest Release Candidate stages been released at 24 July 2010. Helios for Java EE will ship with full fledged Java EE 6 support, including JSF 2.0.

As of now, it just works fine in Eclipse Ganymede/Galileo when you select JSF 1.2 and uses JSF 2.0 libraries. You'll only miss some code assistance which may be useful for JSF 2.0, but you can write code as good yourself.

3
  • 1
    To be precise, NetBeans 6.8 doesn't provide CDI support so it doesn't "fully" support Java EE 6. But NB 6.9 does. NB 6.9 also introduces Code completion for JSF tag attribute values. See the Java EE section in the release notes. +1 anyway. May 5, 2010 at 1:32
  • Fixed, thanks. The release notes by the way also say that it's available as patch for 6.8 as well.
    – BalusC
    May 5, 2010 at 1:38
  • So it looks like Net Beans is probably the best way to go now. I am currently using Net Beans 6.8 - in general is ok but seems a bit buggy when used for JSF 2.0 development - sometimes you need to restart the IDE for some random reason. Am using it on windows though, maybe it would be better on linux.
    – Shane
    May 6, 2010 at 5:02
2

Use Eclipse with JBoss Tools Plugin. It has support for JSF2 and CDI.

http://in.relation.to/14750.lace

1

Note, that you can do JSF 2.0 development in Eclipse, but not with as much tool support as might come later.

You can always edit xhtml files directly as XML-files (and have the namespaces registered), and have Glassfish deployments. I've done that, with stock Eclipse 3.5.2 Java EE edition, and the Glassfish plugin.

0

Have a read on http://weblogs.java.net/blog/2009/05/18/using-ide-write-jsf-20-app

It describe in details on how to setup your eclipse for jsf 2.0 development.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.