commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Cooper <>
Subject Re: chains problems persists
Date Fri, 08 Apr 2005 16:11:41 GMT
On Apr 8, 2005 7:10 AM, Vinicius Caldeira Carvalho
<> wrote:
> Well I guess I tried everthing. From debuging the source code to read
> the entire javadoc. I've just downloaded the latest nightly build from
> chains, tried to understand both apps bundle within it. And as far as I
> know I'm not very stupid.
> So I tried everthing, and I can say that The only way to put it to work
> is through the old config style:
> <context-param>
>   <param-name>org.apache.commons.chain.CONFIG_WEB_RESOURCE</param-name>
>   <param-value>/WEB-INF/catalog.xml</param-value>
> </context-param>
> <context-param>
>     <param-name>org.apache.commons.chain.CONFIG_ATTR</param-name>
>     <param-value>catalog</param-value>
> </context-param>
> Otherwise the listener will *not* register my catalog with the context.
> Well unless a magic happens, cuz on the ChainListener code there's no
> code indicating that. Also I'd like to know how to use that
> CatalogFactory, I did not find any way to initialize it. And trying to
> use a ConfigCatalogRule as my rule-set throws an invocationtargetexception.
> Craig, dude I'm sorry I really didn't know who you are. Thanks for
> struts  ;)
> But guys, are you all using commons chains? How could this simple tasks
> be done? I really don't see how to register my catalog with my
> webcontext in other way besides the old depracated one...

I am using Commons Chain, yes, and all I have in my web.xml is this:

  <!-- Chain listener configuration  -->

Then I access the catalog (I'm using the default catalog) like this:

  Catalog catalog = CatalogFactory.getInstance().getCatalog();

As simple as can be, and it all works just fine. :-)

Martin Cooper

> Thanks all
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message