myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alan <omegaobj...@gmail.com>
Subject Re: Need help getting started with GlassFish, MyFaces, and Trinidad
Date Tue, 19 Oct 2010 04:27:02 GMT
On Mon, Oct 18, 2010 at 12:53 PM, Jakob Korherr <jakob.korherr@gmail.com>wrote:

>
> You need to have myfaces-api and myfaces-impl dependencies in your
> project like this:
>
>
OK, thanks to Jakob's hints I got MyFaces-2 running under GlassFish.  One
thing that is essential (I am putting it here for reference) is the format
of the sun-web.xml entry has to be:

  <property name="useMyFaces" value="true"/>

Also you have to set:

    <class-loader delegate="false"/>

I encountered something very disturbing when experimenting with this.  In
many cases something actually over-writes the sun-web.xml file when I try to
run the application.  It seems to happen somewhere in the deployment
process.  I don't know if this is a bug in netbeans or the MyFaces servlet
is doing something.  Has anyone else seen this?

Another thing I discovered is that when using MyFaces, the CDI services no
longer work for managed beans.  You have to use the
@java.faces.bean.ManagedBean annotation. The @javax.enterprise.inject.Model
annotation will not work.  This is sort of a show-stopper for me since I
have a fair amount of code that uses CDI now and I read that the faces
annotations may end up deprecated.  Is there any workaround on this or any
word if this is going to be fixed?

Thanks for all the help.

Regards,

A.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message