[errai-dev] Errai 3 and JBoss 7 (packaging)

Jonathan Fuerth jfuerth at redhat.com
Fri Mar 8 14:27:22 EST 2013


On 2013-03-08, at 11:16 AM, Eric Wittmann wrote:

> Do you guys have any docs or examples illustrating which of the myriad 
> of JARs in Errai (and transitives) need to be included in the WAR when 
> packaging for JBoss 7?  I'd like to slim down the WAR if I can - for 
> example: which of the Errai JARs are client-side only?

Yes, all of our demos and archetypes include a profile for building an AS7-deployable .war file (the profile also works for EAP6 and OpenShift). You can just build like this:

    % mvn package -Pjboss7

If you're rolling your own pom.xml (or not using Maven for your project), the best way to glean this information would be to create a project from one of our archetypes, then use `mvn dependency:tree -Pjboss7` to see what's marked as "provided" rather than "compile."

Having said all this, we've been brainstorming better ways to organize all of this: the demos, the archetypes, and the dependency scopes for different deployment scenarios. So far, we have more questions than answers. If you (or anyone else) has ideas, let's discuss it on the mailing list!

> Also, when I start up my app in JBoss 7 (on both my Windows and Linux 
> machines), I get a bunch of exceptions on startup that look like this:
> 
>  https://gist.github.com/EricWittmann/cfdfbc8aa0865b4ab9fb
> 
> This doesn't happen for all JARs in the WAR.  Perhaps only the ones with 
> an ErraiApp.properties file?  Here's the full list of JARs that cause 
> the exception:
> 
>  https://gist.github.com/EricWittmann/d9dc538aeb8e039dd7a8

Correct, this will happen for each .jar that has an ErraiApp.properties. The cause is that Mike recently factored out JBoss 7 support code into its own module that you'll have to depend on when deploying to AS7/EAP6/OpenShift. The module is org.jboss.errai:errai-jboss-as-support:3.0-SNAPSHOT.

> Interestingly, everything seems to still work.

You'll probably find that dynamic marshalling doesn't work properly when you get those errors at deployment time.

> Help on both issues appreciated.  :)

Our pleasure!

-Jonathan


More information about the errai-dev mailing list