This week's giveaway is in the Beginning Java forum.
We're giving away four copies of Bad Programming Practices 101 (e-book) and have Karl Beecher on-line!
See this thread for details.
Win a copy of Bad Programming Practices 101 (e-book) this week in the Beginning Java forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

struggling with embedded tomcat, grails and spring faces/jsf2  RSS feed

Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i'm a closet grails developer, however i've been having a huge problem trying to get grails 2.01/3 STS rout trip dev, and embedded tomcat to work - and i really need some help

essentially i've built a grails plugin that tries to add the springfaces /jsf2 with the grails stuff.

This all works for me ( i wanted to have a play with prime faces ) if i generate a WAR and import that WAR into tomcat manually (outside of eclipse STS)

if i try and do a run-app in eclipse and try and access /app/home (simple hello facelet/layout i cut and paste from the spring webflow/primafaces demo) i get an error indicating that faces hasnt initialised properly - this fails with mojarra 2.1.7, and myfaces 2.1.7 - i've kept with myfaces as i was getting more error text

This works absolutely ok with a standard alone WAR export and import manually into tomcat v7. but as soon as i try to run in embedded mode (grails dev mode in eclipse STS) and access faces resources (its ok with ordinary grails gsps) i get this. Cant get anyone to give me any pointers/help on what this might be - but it means i cant really mix primefaces/jsf2 with grails in ordinary dev mode which is a real bummer. If i can crack this i can havea go at writing a JSF 2 plugin for others - existing grails jsf2 plugin doesnt work under grails v2 (and hasnt been played with for 2 years )

really need some help on how to resolve this. heres the error i get accessing my simple facelet

this is generated web.xml output from the doWithWebDescriptor closure in the plugin project [a grails project under STS doesnt come with web.xml in the project skeletons - its generated on the fly by grails but you can interact with it which i have done here to add the faces servlet and springmvc servlet for the facelet.

in order to try and see my own debug code, i have extended the myfaces servlet which is a delagating impl from my apache (i saw stuff in google about the some issues and this would fix it - it didnet for me )

my grails ivy dependency list looks like this

the fact that it works outside of STS eclipse dev mode, but fails with embedded mode - suggests to me that its something screwy in the grails packaging for dev mode.

cant get any help so far from the grails user forum.

also posted about this on the code ranch jsf forum with no response (see jsf forum post )

wondered if anyone in tomcat forums might take a guess at what why embedded mode working would fail this way

thanks in advance

I've got no option but to sell you all for scientific experiments. Or a tiny ad:
Why should you try IntelliJ IDEA ?
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!