If you provide a jar with 100 modules that can be enabled/disabled
then don't provide the manifest entry and resort to providing modules
via tapestry.modules system property...

> Searching the mailing list archives I've found this thread with a solution
> for disabling the autoloading of given modules:
> http://tapestry.1045711.n5.nabble.com/T5-disable-loading-specified-module-td2431110.html

This solution doesn't look like it will work in the current codebase.
If you disable default modules (via the MANIFEST) you are also
disabling tapestry.modules (see line 138 of TapestryAppInitializer and
line 80 of IOCUtilities). That seems like a defect to me, and probably
got in as part of a refactoring.

There is a context parameter that you can use to add modules after
you've disabled auto loading. tapestry.MODE-modules, where mode is
defined by the system property tapestry.execution-mode (defaults to
production)

I don't think I've ever seen this documented, or felt the need to use it.

Josh


On Thu, Jan 6, 2011 at 7:23 AM, Thiago H. de Paula Figueiredo
<thiag...@gmail.com> wrote:
> On Thu, 06 Jan 2011 13:07:34 -0200, Joel Halbert <j...@su3analytics.com>
> wrote:
>
>>> why cant you take the jar from the classpath?
>>
>> This is what I have done, but it strikes me as quite a blunt instrument
>> to use for configuring an application. Does it really mean you need a
>> jar per service, if the user of the jar might want to selectively enable
>> some of the services but not others?
>
> One JAR can have as many modules as you want, so you don't need one JAR per
> service. And Tapestry-IoC doesn't offer any way of selectively enable or
> disable services provided by a module. IMHO I don't miss this feature at
> all.
>
> Searching the mailing list archives I've found this thread with a solution
> for disabling the autoloading of given modules:
> http://tapestry.1045711.n5.nabble.com/T5-disable-loading-specified-module-td2431110.html
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and
> instructor
> Owner, Ars Machina Tecnologia da Informação Ltda.
> http://www.arsmachina.com.br
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to