You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Mike Kienenberger <mk...@gmail.com> on 2005/10/03 18:46:38 UTC

Jenia4Faces popup and myfaces: container or Myfaces path config problem?

This is mostly directed at Werner now that he's a committer and since
he's hit a similar error with Jenia4Faces popups and documented it on
the wiki.  :)   But maybe someone else more familiar with web
containers and/or myfaces configuration loading can comment.

There's something wrong with the path configuration when using Jetty
5.1.3 and MyFaces (nightlies included).

It's unclear to me whether it's a MyFaces path configuration issue or
a web container (Jetty 5.1.3 issue).  I'm guessing the former since
Werner's posted error differs from mine, implying a different
container.

The relevent snippet from
jenia4faces-popup.jar:META-INF/faces-config.xml looks like this:
==================
<!ENTITY popup SYSTEM "jenia-popup-config.xml">
]>
<faces-config xmlns="http://java.sun.com/JSF/Configuration">
    &popup;	
</faces-config>
==================
And "jenia-popup-config.xml" exists as
jenia4faces-popup.jar:META-INF/jenia-popup-config.xml

I posted the same issue to the jenia4Face mailing list at this
location, but we haven't come up with a solution, and it's not really
a jenia4Faces issue.

https://sourceforge.net/forum/forum.php?thread_id=1360538&forum_id=488135

Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
Ah Mike I almost forgot, if it is just for the launcher...
you could give the free Exadel version a testrun, it is not perfect
and Exadel in some areas is pretty buggy, but for plain Tomcat launching
it is ok as it is...
You might get the same launcher results by using the WTP, upon the whole
launcher infrastructure of Exadel seems to be based.



Mike Kienenberger wrote:
> Thanks for taking a look, Werner!
> 
> I've had a couple of other Jetty issues (like no listeners in tld
> files), so it doesn't come as a complete surprise.  On the other hand,
> the ease of using JettyLauncher under Eclipse over the tomcat sysdeo
> launcher will probably keep working with jetty for a while longer.  
> Guess it's time to file some bug reports on jetty :)
> 
> On 10/3/05, Werner Punz <we...@gmx.at> wrote:
> 


Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Mike Kienenberger <mk...@gmail.com>.
On 10/3/05, Werner Punz <we...@gmx.at> wrote:
> Are there any other benefits of jetty over tomcat except for the launcher
> (I have MyEclipse and Exadel handling this problem to a satisfying degree)

I'm not sure if there are any significant benefits other than the
launcher.    The launcher lets me configuration run instances just
like any other kind of run instance.   It's trivial to customize,
maintain, and run multiple instances of various applications at the
same time.

With the sysdeo launcher, I had to keep modifying the Tomcat
server.xml file, and having multiple configurations was painful.

Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
Mike Kienenberger wrote:
> Thanks for taking a look, Werner!
> 
> I've had a couple of other Jetty issues (like no listeners in tld
> files), so it doesn't come as a complete surprise.  On the other hand,
> the ease of using JettyLauncher under Eclipse over the tomcat sysdeo
> launcher will probably keep working with jetty for a while longer.  
> Guess it's time to file some bug reports on jetty :)
> 
> On 10/3/05, Werner Punz <we...@gmx.at> wrote:
Actually it might be resolved with jetty 5.1.4
(see my other post regarding this issue)
Are there any other benefits of jetty over tomcat except for the launcher

(I have MyEclipse and Exadel handling this problem to a satisfying degree)


Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Mike Kienenberger <mk...@gmail.com>.
Thanks for taking a look, Werner!

I've had a couple of other Jetty issues (like no listeners in tld
files), so it doesn't come as a complete surprise.  On the other hand,
the ease of using JettyLauncher under Eclipse over the tomcat sysdeo
launcher will probably keep working with jetty for a while longer.  
Guess it's time to file some bug reports on jetty :)

On 10/3/05, Werner Punz <we...@gmx.at> wrote:
> Hi Mike, I gave it a testrun,
> just dumped the jenia jsps and the jena4faces into the latest
> 1.1.1sandbox build, added the missing web.xml entries,
> added the jsps css and the images and started it and gave the jsps from
> jenia a testrun, worked out of the box
> on a plain tomcat in the 1.1.1x myfaces sandbox for me...
>
> the problem probably is jetty related respectively related to the jetty classloader.
> Tomcat usually loads the classes from the WEB-INF/lib first and if not found from
> the tomcat itself, this is also how the later servlet specs to my knowlegde
> want the servlet runners classloader to behave.
>
> Jetty might break this...
>
> Werner
>
>
>
>
> Mike Kienenberger wrote:
> > This is mostly directed at Werner now that he's a committer and since
> > he's hit a similar error with Jenia4Faces popups and documented it on
> > the wiki.  :)   But maybe someone else more familiar with web
> > containers and/or myfaces configuration loading can comment.
> >
> > There's something wrong with the path configuration when using Jetty
> > 5.1.3 and MyFaces (nightlies included).
> >
> > It's unclear to me whether it's a MyFaces path configuration issue or
> > a web container (Jetty 5.1.3 issue).  I'm guessing the former since
> > Werner's posted error differs from mine, implying a different
> > container.
> >
>
>

Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
Hi Mike, I gave it a testrun,
just dumped the jenia jsps and the jena4faces into the latest
1.1.1sandbox build, added the missing web.xml entries,
added the jsps css and the images and started it and gave the jsps from
jenia a testrun, worked out of the box
on a plain tomcat in the 1.1.1x myfaces sandbox for me...

the problem probably is jetty related respectively related to the jetty classloader.
Tomcat usually loads the classes from the WEB-INF/lib first and if not found from
the tomcat itself, this is also how the later servlet specs to my knowlegde
want the servlet runners classloader to behave.

Jetty might break this...

Werner




Mike Kienenberger wrote:
> This is mostly directed at Werner now that he's a committer and since
> he's hit a similar error with Jenia4Faces popups and documented it on
> the wiki.  :)   But maybe someone else more familiar with web
> containers and/or myfaces configuration loading can comment.
> 
> There's something wrong with the path configuration when using Jetty
> 5.1.3 and MyFaces (nightlies included).
> 
> It's unclear to me whether it's a MyFaces path configuration issue or
> a web container (Jetty 5.1.3 issue).  I'm guessing the former since
> Werner's posted error differs from mine, implying a different
> container.
> 


Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
In that case, try to switch to springs own JSF variable resolver
mechanism, but i rather doubt it will change things.
The problem seems to be knee deep in the xml loading
mechanisms provided by spring itself :-(.
Probably a problematic resource loading mechanism.
As I said the best thing probably would be to contact
Spring people, to my knowledge they are a very friendly and helpful bunch.

I have to admit I have not used Spring in combination with Jenia yet,
or Jenia extensively at all.

If I can find time I may look into this issue on the weekend.
You sort of raised my interest there ;-)

Werner


Mike Kienenberger wrote:
> Actually, I've been using the jsf-spring.jar integration since I
> started using JSF.
> It's possible it's really a jsf-spring issue rather than a spring
> issue as well, I suppose.
> I guess I need to write a simple example that adds and removes those
> pieces and figure out at what point it breaks.
> 
> Just haven't had time to do more than an hour or so of investigation
> into it each day.
> 
> At least I've now eliminated the container and MyFaces.
> 
> As always, thanks for your help.
> 
> On 10/4/05, Werner Punz <we...@gmx.at> wrote:


Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Mike Kienenberger <mk...@gmail.com>.
Actually, I've been using the jsf-spring.jar integration since I
started using JSF.
It's possible it's really a jsf-spring issue rather than a spring
issue as well, I suppose.
I guess I need to write a simple example that adds and removes those
pieces and figure out at what point it breaks.

Just haven't had time to do more than an hour or so of investigation
into it each day.

At least I've now eliminated the container and MyFaces.

As always, thanks for your help.

On 10/4/05, Werner Punz <we...@gmx.at> wrote:
> It seems like an entity resolver or servlet contect resolve issue, the loader of this
> class seems to fail to load the xml file:
>
> All I can say mike, is push this down the spring mailing list and check for answers
> it definitely is somewhere on the spring side...
>
> I assume you use the spring internal jsf-spring bindings, all I can say is,
> do not use them
> they are too limited in my experience, go for the
>
> http://jsf-spring.sourceforge.net/
>
> library
>
> you can find config files for that stuff ripped straight out of my last project
> here:
> http://wiki.apache.org/myfaces/JSF_Spring_Config
>
> they are for myfaces 1.0.9 but should be easy to alter for 1.1.x
>
> The reason why I think it might help is that the lib might use
> a different loading mechanism for the xml config files.
>
> Werner
>
>
> Mike Kienenberger wrote:
> > Well, that'd really be good news.   I had read the release notes for
> > 5.1.4 and even 5.1.5 rc1, but there no mention of a fix.
> >
> > I'm still seeing the same behavior under 5.1.5rc1, so the problem is
> > possibly in Spring.   I've tried running it directly in jetty skipping
> > the JettyLauncher, and also see the same problem, so if you had it
> > running under 5.1.4, I don't see any other option than to blame
> > Spring.   In fact, I'm getting the same error under Tomcat 5.0.30 as
> > well.   That seems to rule out a container issue.
> >
> > java.io.FileNotFoundException: Could not open ServletContext resource
> > [/jenia-popup-config.xml]
> >       at org.springframework.web.context.support.ServletContextResource.getInputStream(ServletContextResource.java:92)
> >       at org.springframework.context.support.ResourceEntityResolver.resolveEntity(ResourceEntityResolver.java:84)
> >       at org.apache.xerces.util.EntityResolverWrapper.resolveEntity(Unknown Source)
> >
> >
> >
> > On 10/3/05, Werner Punz <we...@gmx.at> wrote:
> >
> >>Mike bad news, actually not really,
> >>I also gave jetty 5.1.4 a testrun, I got the same
> >>results as in Tomcat, apparently the jenia popup demo nowadays uses
> >>myfaces as their base jsf implementation.
> >>
> >>Your problems might be resolved by upgrading to a later jetty.
> >>
> >>
> >>Werner
> >>
> >>
> >>Mike Kienenberger wrote:
> >>
> >>>This is mostly directed at Werner now that he's a committer and since
> >>>he's hit a similar error with Jenia4Faces popups and documented it on
> >>>the wiki.  :)   But maybe someone else more familiar with web
> >>>containers and/or myfaces configuration loading can comment.
> >>>
> >>>There's something wrong with the path configuration when using Jetty
> >>>5.1.3 and MyFaces (nightlies included).
> >>>
> >>>It's unclear to me whether it's a MyFaces path configuration issue or
> >>>a web container (Jetty 5.1.3 issue).  I'm guessing the former since
> >>>Werner's posted error differs from mine, implying a different
> >>>container.
> >>>
> >>>The relevent snippet from
> >>>jenia4faces-popup.jar:META-INF/faces-config.xml looks like this:
> >>>==================
> >>><!ENTITY popup SYSTEM "jenia-popup-config.xml">
> >>>]>
> >>><faces-config xmlns="http://java.sun.com/JSF/Configuration">
> >>>    &popup;
> >>></faces-config>
> >>>==================
> >>>And "jenia-popup-config.xml" exists as
> >>>jenia4faces-popup.jar:META-INF/jenia-popup-config.xml
> >>>
> >>>I posted the same issue to the jenia4Face mailing list at this
> >>>location, but we haven't come up with a solution, and it's not really
> >>>a jenia4Faces issue.
> >>>
> >>>https://sourceforge.net/forum/forum.php?thread_id=1360538&forum_id=488135
> >>>
> >>
> >>
> >
>
>

Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
It seems like an entity resolver or servlet contect resolve issue, the loader of this
class seems to fail to load the xml file:

All I can say mike, is push this down the spring mailing list and check for answers
it definitely is somewhere on the spring side...

I assume you use the spring internal jsf-spring bindings, all I can say is,
do not use them
they are too limited in my experience, go for the

http://jsf-spring.sourceforge.net/

library

you can find config files for that stuff ripped straight out of my last project
here:
http://wiki.apache.org/myfaces/JSF_Spring_Config

they are for myfaces 1.0.9 but should be easy to alter for 1.1.x

The reason why I think it might help is that the lib might use
a different loading mechanism for the xml config files.

Werner


Mike Kienenberger wrote:
> Well, that'd really be good news.   I had read the release notes for
> 5.1.4 and even 5.1.5 rc1, but there no mention of a fix.
> 
> I'm still seeing the same behavior under 5.1.5rc1, so the problem is
> possibly in Spring.   I've tried running it directly in jetty skipping
> the JettyLauncher, and also see the same problem, so if you had it
> running under 5.1.4, I don't see any other option than to blame
> Spring.   In fact, I'm getting the same error under Tomcat 5.0.30 as
> well.   That seems to rule out a container issue.
> 
> java.io.FileNotFoundException: Could not open ServletContext resource
> [/jenia-popup-config.xml]
> 	at org.springframework.web.context.support.ServletContextResource.getInputStream(ServletContextResource.java:92)
> 	at org.springframework.context.support.ResourceEntityResolver.resolveEntity(ResourceEntityResolver.java:84)
> 	at org.apache.xerces.util.EntityResolverWrapper.resolveEntity(Unknown Source)
> 
> 
> 
> On 10/3/05, Werner Punz <we...@gmx.at> wrote:
> 
>>Mike bad news, actually not really,
>>I also gave jetty 5.1.4 a testrun, I got the same
>>results as in Tomcat, apparently the jenia popup demo nowadays uses
>>myfaces as their base jsf implementation.
>>
>>Your problems might be resolved by upgrading to a later jetty.
>>
>>
>>Werner
>>
>>
>>Mike Kienenberger wrote:
>>
>>>This is mostly directed at Werner now that he's a committer and since
>>>he's hit a similar error with Jenia4Faces popups and documented it on
>>>the wiki.  :)   But maybe someone else more familiar with web
>>>containers and/or myfaces configuration loading can comment.
>>>
>>>There's something wrong with the path configuration when using Jetty
>>>5.1.3 and MyFaces (nightlies included).
>>>
>>>It's unclear to me whether it's a MyFaces path configuration issue or
>>>a web container (Jetty 5.1.3 issue).  I'm guessing the former since
>>>Werner's posted error differs from mine, implying a different
>>>container.
>>>
>>>The relevent snippet from
>>>jenia4faces-popup.jar:META-INF/faces-config.xml looks like this:
>>>==================
>>><!ENTITY popup SYSTEM "jenia-popup-config.xml">
>>>]>
>>><faces-config xmlns="http://java.sun.com/JSF/Configuration">
>>>    &popup;
>>></faces-config>
>>>==================
>>>And "jenia-popup-config.xml" exists as
>>>jenia4faces-popup.jar:META-INF/jenia-popup-config.xml
>>>
>>>I posted the same issue to the jenia4Face mailing list at this
>>>location, but we haven't come up with a solution, and it's not really
>>>a jenia4Faces issue.
>>>
>>>https://sourceforge.net/forum/forum.php?thread_id=1360538&forum_id=488135
>>>
>>
>>
> 


Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Mike Kienenberger <mk...@gmail.com>.
Well, that'd really be good news.   I had read the release notes for
5.1.4 and even 5.1.5 rc1, but there no mention of a fix.

I'm still seeing the same behavior under 5.1.5rc1, so the problem is
possibly in Spring.   I've tried running it directly in jetty skipping
the JettyLauncher, and also see the same problem, so if you had it
running under 5.1.4, I don't see any other option than to blame
Spring.   In fact, I'm getting the same error under Tomcat 5.0.30 as
well.   That seems to rule out a container issue.

java.io.FileNotFoundException: Could not open ServletContext resource
[/jenia-popup-config.xml]
	at org.springframework.web.context.support.ServletContextResource.getInputStream(ServletContextResource.java:92)
	at org.springframework.context.support.ResourceEntityResolver.resolveEntity(ResourceEntityResolver.java:84)
	at org.apache.xerces.util.EntityResolverWrapper.resolveEntity(Unknown Source)



On 10/3/05, Werner Punz <we...@gmx.at> wrote:
> Mike bad news, actually not really,
> I also gave jetty 5.1.4 a testrun, I got the same
> results as in Tomcat, apparently the jenia popup demo nowadays uses
> myfaces as their base jsf implementation.
>
> Your problems might be resolved by upgrading to a later jetty.
>
>
> Werner
>
>
> Mike Kienenberger wrote:
> > This is mostly directed at Werner now that he's a committer and since
> > he's hit a similar error with Jenia4Faces popups and documented it on
> > the wiki.  :)   But maybe someone else more familiar with web
> > containers and/or myfaces configuration loading can comment.
> >
> > There's something wrong with the path configuration when using Jetty
> > 5.1.3 and MyFaces (nightlies included).
> >
> > It's unclear to me whether it's a MyFaces path configuration issue or
> > a web container (Jetty 5.1.3 issue).  I'm guessing the former since
> > Werner's posted error differs from mine, implying a different
> > container.
> >
> > The relevent snippet from
> > jenia4faces-popup.jar:META-INF/faces-config.xml looks like this:
> > ==================
> > <!ENTITY popup SYSTEM "jenia-popup-config.xml">
> > ]>
> > <faces-config xmlns="http://java.sun.com/JSF/Configuration">
> >     &popup;
> > </faces-config>
> > ==================
> > And "jenia-popup-config.xml" exists as
> > jenia4faces-popup.jar:META-INF/jenia-popup-config.xml
> >
> > I posted the same issue to the jenia4Face mailing list at this
> > location, but we haven't come up with a solution, and it's not really
> > a jenia4Faces issue.
> >
> > https://sourceforge.net/forum/forum.php?thread_id=1360538&forum_id=488135
> >
>
>

Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
Mike bad news, actually not really,
I also gave jetty 5.1.4 a testrun, I got the same
results as in Tomcat, apparently the jenia popup demo nowadays uses
myfaces as their base jsf implementation.

Your problems might be resolved by upgrading to a later jetty.


Werner


Mike Kienenberger wrote:
> This is mostly directed at Werner now that he's a committer and since
> he's hit a similar error with Jenia4Faces popups and documented it on
> the wiki.  :)   But maybe someone else more familiar with web
> containers and/or myfaces configuration loading can comment.
> 
> There's something wrong with the path configuration when using Jetty
> 5.1.3 and MyFaces (nightlies included).
> 
> It's unclear to me whether it's a MyFaces path configuration issue or
> a web container (Jetty 5.1.3 issue).  I'm guessing the former since
> Werner's posted error differs from mine, implying a different
> container.
> 
> The relevent snippet from
> jenia4faces-popup.jar:META-INF/faces-config.xml looks like this:
> ==================
> <!ENTITY popup SYSTEM "jenia-popup-config.xml">
> ]>
> <faces-config xmlns="http://java.sun.com/JSF/Configuration">
>     &popup;	
> </faces-config>
> ==================
> And "jenia-popup-config.xml" exists as
> jenia4faces-popup.jar:META-INF/jenia-popup-config.xml
> 
> I posted the same issue to the jenia4Face mailing list at this
> location, but we haven't come up with a solution, and it's not really
> a jenia4Faces issue.
> 
> https://sourceforge.net/forum/forum.php?thread_id=1360538&forum_id=488135
> 


Re: Jenia4Faces popup and myfaces: container or Myfaces path config problem?

Posted by Werner Punz <we...@gmx.at>.
Hi Mike

Actually good address, but wrong person I only added the last change
to this page, which is that it should work now with myfaces out of the box
now (this info was from the jenia site).

the original entry is from: AlekseiValikov


But I will give jenia a shot later tonigt, I am interested in it anyway ;-)

Werner



Mike Kienenberger wrote:
> This is mostly directed at Werner now that he's a committer and since
> he's hit a similar error with Jenia4Faces popups and documented it on
> the wiki.  :)   But maybe someone else more familiar with web
> containers and/or myfaces configuration loading can comment.
> 
> There's something wrong with the path configuration when using Jetty
> 5.1.3 and MyFaces (nightlies included).
> 
> It's unclear to me whether it's a MyFaces path configuration issue or
> a web container (Jetty 5.1.3 issue).  I'm guessing the former since
> Werner's posted error differs from mine, implying a different
> container.
> 
> The relevent snippet from
> jenia4faces-popup.jar:META-INF/faces-config.xml looks like this:
> ==================
> <!ENTITY popup SYSTEM "jenia-popup-config.xml">
> ]>
> <faces-config xmlns="http://java.sun.com/JSF/Configuration">
>     &popup;	
> </faces-config>
> ==================
> And "jenia-popup-config.xml" exists as
> jenia4faces-popup.jar:META-INF/jenia-popup-config.xml
> 
> I posted the same issue to the jenia4Face mailing list at this
> location, but we haven't come up with a solution, and it's not really
> a jenia4Faces issue.
> 
> https://sourceforge.net/forum/forum.php?thread_id=1360538&forum_id=488135
>