Hi, Well done! Let us know if there are any problems with this shared usage.
On Thu, Jun 14, 2012 at 4:57 AM, Илья Нарыжный <[email protected]> wrote: > Finally I did it! > As jboss module I created 2 modules: wicket and wicketstuff. Configuration: > > <?xml version="1.0" encoding="UTF-8"?> > <module xmlns="urn:jboss:module:1.0" name="org.apache.wicket"> > <resources> > <resource-root path="wicket-core-1.5.7.jar"/> > <resource-root path="wicket-request-1.5.7.jar"/> > <resource-root path="wicket-auth-roles-1.5.7.jar"/> > <resource-root path="wicket-extensions-1.5.7.jar"/> > <resource-root path="wicket-datetime-1.5.7.jar"/> > <resource-root path="wicket-util-1.5.7.jar"/> > </resources> > <dependencies> > <module name="org.apache.commons.collections"/> > <module name="javaee.api"/> > <module name="org.jboss.logging"/> > <module name="org.jboss.as.web"/> > <module name="org.slf4j"/> > </dependencies> > </module> > > and > > <?xml version="1.0" encoding="UTF-8"?> > <module xmlns="urn:jboss:module:1.0" name="org.wicketstuff"> > <resources> > <resource-root path="wicketstuff-autocomplete-tagit-1.5.5.jar"/> > <resource-root path="wicketstuff-tinymce-1.5.5.jar"/> > <resource-root path="jazzy-0.5.2-rtext-1.4.1.jar"/> > </resources> > <dependencies> > <module name="org.apache.commons.collections"/> > <module name="org.apache.wicket"/> > <module name="org.slf4j"/> > <!--<module name="org.springframework" export="true"/>--> > </dependencies> > </module> > > But I found that wicketstuff-anotation can't be organized as a module > because in class org.wicketstuff.config.MatchingResources in method > getClass page class is constructed in current classloader. I would > like to recommend to rewrite this class in a way when classloader for > corresponding initial application is used. File an issue in WicketStuff issue tracker. Send a Pull Request with the fix too ;-) > > Thanks, > > Ilia > > 2012/6/13 Martin Grigorov <[email protected]>: >> Good point! >> https://issues.apache.org/jira/browse/WICKET-4604 >> >> On Wed, Jun 13, 2012 at 9:31 AM, Igor Vaynberg <[email protected]> >> wrote: >>> we have to be sure we do not use any static fields anywhere in the >>> code...it's not just the singletons that break this use case. eg we do not >>> want caches to be shared across applications because it's not performant >>> and can result in cross application object leakage. >>> >>> -igor >>> >>> On Tuesday, June 12, 2012, Martin Grigorov wrote: >>> >>>> Hi, >>>> >>>> Wicket uses ThreadLocal for the Application, Session and RequestCycle. >>>> There are no JVM singletons. >>>> >>>> Some people are against putting jars in the shared lib folder. I >>>> personally see the benefit and I'd do it if I need to >>>> If you use shared jars then make sure that none of the applications >>>> provide these jars or another version of them because in this case you >>>> will see some ClassLoader related problems, e.g.: ClassCastException: >>>> o.a.w.Session class is not o.a.w.Session. >>>> >>>> On Tue, Jun 12, 2012 at 11:04 PM, Martin Sachs >>>> <[email protected]<javascript:;>> >>>> wrote: >>>> > Hello, >>>> > >>>> > i think that is in general not a good idea. If you deploy the wicket-lib >>>> > outside the war and run multiple Wicket-Applications, then you could not >>>> use >>>> > all applications, because wicket stores (as far as i know) e.g. the >>>> > application instance in a static field. There is one application per >>>> > WAR-deployment with wicket, but if you use the libs from ear/lib or >>>> modules >>>> > there will be only one application. >>>> > >>>> > best >>>> > Martin >>>> > >>>> > Илья Нарыжный schrieb: >>>> > >>>> >> Hello, >>>> >> >>>> >> I have several projects which use wicket and various wicket sun-modules. >>>> >> Every project (*.ear file) took about 10Mb and about 8Mb is for wicket >>>> >> libraries. >>>> >> Recently I have move my projects to Jboss AS 7 and now I'm thinking >>>> >> about putting all wicket related jars to <JBOSS_HOME>/modules. >>>> >> >>>> >> Have anyone tried that? Do you have some suggestions for Jboss module >>>> >> structure for this? >>>> >> It will be great to have >>>> >> >>>> >> IMPLICIT( >>>> https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments >>>> ) >>>> >> deploy of wicket related jars to the project. >>>> >> >>>> >> Thanks, >>>> >> >>>> >> Ilia >>>> >> >>>> >> --------------------------------------------------------------------- >>>> >> To unsubscribe, e-mail: >>>> >> [email protected]<javascript:;> >>>> >> For additional commands, e-mail: >>>> >> [email protected]<javascript:;> >>>> >> >>>> >> >>>> >> >>>> > >>>> > >>>> > >>>> > --------------------------------------------------------------------- >>>> > To unsubscribe, e-mail: [email protected]<javascript:;> >>>> > For additional commands, e-mail: >>>> > [email protected]<javascript:;> >>>> > >>>> >>>> >>>> >>>> -- >>>> Martin Grigorov >>>> jWeekend >>>> Training, Consulting, Development >>>> http://jWeekend.com >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe, e-mail: [email protected] <javascript:;> >>>> For additional commands, e-mail: [email protected]<javascript:;> >>>> >>>> >> >> >> >> -- >> Martin Grigorov >> jWeekend >> Training, Consulting, Development >> http://jWeekend.com >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
