Re: problems with Tapestry IgnoredPaths
Hi, Sagara Have you ever wondering your AppModule is working for other function? Like bind() or so. I did make a mistake that I define tapestry filter as following: tapestry org.apache.tapestry5.TapestryFilter But using AppModule as class name, which should be TapestryModule. Hope it works Allex J. Sagara Gunathunga ??: Hi Andreas, Thanks for the help , I'm also use same environment T5.0.14 with axis2, I try to use various pattern including your suggestion , but not works for me . Also I notice that regard less of url pattern contributeIgnoredPathsFilte method is not call by T5 any time, I think problem is there . if you can please post your AppModule and web.xml files ? Thanks , On Tue, Oct 28, 2008 at 5:00 AM, Andreas Pursian <[EMAIL PROTECTED]> wrote: Hi Sagara, try to add /* at the end of your filter path like this public static void contributeIgnoredPathsFilter(Configuration configuration) { configuration.add("/services/.*"); } At least this works for me with t5.0.14 and axis2. cheers andreas Sagara Gunathunga wrote: Hi, We are using Tapestry 5.0.14 for our project , and there is a requirement to expose some Web services using Axis on same application , so I put my Axis servlet/mapping under web.xml file but when I try to access the services it does not work, as a example when I try to access http://localhost:8080/services/MyService?wsdl it directed to Tapestry not to Axis . Than I try to use *contributeIgnoredPathsFilter* method as follows public static void contributeIgnoredPathsFilter(Configuration configuration) { System.out.println("...calling contributeIgnoredPathsFilter"); configuration.add("/services"); } This also not worked and I observed that contributeIgnoredPathsFilter not call by the Tapestry . Is there any way to resolve this ..? thanks , Sagara Gunathunga Blog - ssagara.blogspot.com Web - http://sagaras.awardspace.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problems with Tapestry IgnoredPaths
Hi Andreas, Thanks for the help , I'm also use same environment T5.0.14 with axis2, I try to use various pattern including your suggestion , but not works for me . Also I notice that regard less of url pattern contributeIgnoredPathsFilte method is not call by T5 any time, I think problem is there . if you can please post your AppModule and web.xml files ? Thanks , On Tue, Oct 28, 2008 at 5:00 AM, Andreas Pursian <[EMAIL PROTECTED]> wrote: > Hi Sagara, > > try to add /* at the end of your filter path like this > > public static void contributeIgnoredPathsFilter(Configuration > configuration) >{ > configuration.add("/services/.*"); >} > > At least this works for me with t5.0.14 and axis2. > > cheers andreas > > > Sagara Gunathunga wrote: > >> Hi, >> We are using Tapestry 5.0.14 for our project , and there is a requirement >> to expose some Web services using Axis on same application , so I put >> my >> Axis servlet/mapping under web.xml file but when I try to access the >> services it does not work, as a example when I try to access >> http://localhost:8080/services/MyService?wsdl it directed to Tapestry >> not >> to Axis . >> >> Than I try to use *contributeIgnoredPathsFilter* method as follows >> >> public static void contributeIgnoredPathsFilter(Configuration >> configuration) >>{ >>System.out.println("...calling >> contributeIgnoredPathsFilter"); >>configuration.add("/services"); >>} >> >> This also not worked and I observed that contributeIgnoredPathsFilter not >> call by the Tapestry . >> >> Is there any way to resolve this ..? >> >> >> >> >> thanks , >> >> Sagara Gunathunga >> >> Blog - ssagara.blogspot.com >> Web - http://sagaras.awardspace.com/ >> >> > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Sagara Gunathunga Blog - ssagara.blogspot.com Web - http://sagaras.awardspace.com/
Re: problems with Tapestry IgnoredPaths
Hi Sagara, try to add /* at the end of your filter path like this public static void contributeIgnoredPathsFilter(Configuration configuration) { configuration.add("/services/.*"); } At least this works for me with t5.0.14 and axis2. cheers andreas Sagara Gunathunga wrote: Hi, We are using Tapestry 5.0.14 for our project , and there is a requirement to expose some Web services using Axis on same application , so I put my Axis servlet/mapping under web.xml file but when I try to access the services it does not work, as a example when I try to access http://localhost:8080/services/MyService?wsdl it directed to Tapestry not to Axis . Than I try to use *contributeIgnoredPathsFilter* method as follows public static void contributeIgnoredPathsFilter(Configuration configuration) { System.out.println("...calling contributeIgnoredPathsFilter"); configuration.add("/services"); } This also not worked and I observed that contributeIgnoredPathsFilter not call by the Tapestry . Is there any way to resolve this ..? thanks , Sagara Gunathunga Blog - ssagara.blogspot.com Web - http://sagaras.awardspace.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problems with Tapestry IgnoredPaths
HI, I tried with static modifier but cant see any success , I'm wonder why this *contributeIgnoredPathsFilter *not call by Tapestry , Is there any different way to ignore paths in Tapestry 5.0.14 .? may be Howard have an idea about this ? Thanks, On Mon, Oct 27, 2008 at 5:48 PM, Thiago H. de Paula Figueiredo < [EMAIL PROTECTED]> wrote: > Em Mon, 27 Oct 2008 09:13:39 -0300, Sagara Gunathunga < > [EMAIL PROTECTED]> escreveu: > > Hi, >> > > Hi! > > Well, I can't see anything wrong with your code. As a desperate measure, > make all methods in your AppModule static. Anyway, it is a good practice. > > > -- > Thiago H. de Paula Figueiredo > Independent Java consultant, developer, and instructor > Consultor, desenvolvedor e instrutor em Java > http://www.arsmachina.com.br/thiago > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Sagara Gunathunga Blog - ssagara.blogspot.com Web - http://sagaras.awardspace.com/
Re: problems with Tapestry IgnoredPaths
I think that problem is that IgnoredPathsFilter doesn't actually filter the context path. I think changing the Tapestry filter mapping in web.xml to something other than /* would be a best option in your case. On Mon, Oct 27, 2008 at 12:13 PM, Sagara Gunathunga < [EMAIL PROTECTED]> wrote: > Hi, > Thiago, thanks for your quick reply , here is my AppModule > > public class AppModule { >public static void bind(ServiceBinder binder) { >// binder.bind(MyServiceInterface.class, MyServiceImpl.class); > >// Make bind() calls on the binder object to define most IoC > services. >// Use service builder methods (example below) when the > implementation >// is provided inline, or requires more initialization than simply >// invoking the constructor. >} > >public static void contributeApplicationDefaults( >MappedConfiguration configuration) { >// Contributions to ApplicationDefaults will override any > contributions >// to >// FactoryDefaults (with the same key). Here we're restricting the >// supported >// locales to just "en" (English). As you add localised message > catalogs >// and other assets, >// you can extend this list of locales (it's a comma separated > series of >// locale names; >// the first locale name is the default when there's no reasonable >// match). > >configuration.add(SymbolConstants.SUPPORTED_LOCALES, "en"); > >// The factory default is true but during the early stages of an >// application >// overriding to false is a good idea. In addition, this is often >// overridden >// on the command line as -Dtapestry.production-mode=false >configuration.add(SymbolConstants.PRODUCTION_MODE, "false"); >} > > >public RequestFilter buildTimingFilter(final Logger log) { >return new RequestFilter() { >public boolean service(Request request, Response response, >RequestHandler handler) throws IOException { >long startTime = System.currentTimeMillis(); > >try { >// The responsibility of a filter is to invoke the >// corresponding method >// in the handler. When you chain multiple filters > together, >// each filter >// received a handler that is a bridge to the next > filter. > >return handler.service(request, response); >} finally { >long elapsed = System.currentTimeMillis() - startTime; > >log.info(String.format("Request time: %d ms", > elapsed)); >} >} >}; >} > > >public void contributeRequestHandler( >OrderedConfiguration configuration, >@InjectService("TimingFilter") RequestFilter filter) { >// Each contribution to an ordered configuration has a name, When >// necessary, you may >// set constraints to precisely control the invocation order of the >// contributed filter >// within the pipeline. > >configuration.add("Timing", filter); > } > >public static void contributeIgnoredPathsFilter( >Configuration configuration) { >System.out.println("...calling > contributeIgnoredPathsFilter"); >configuration.add("/services"); >} > > } > > > > and also this is part of my Web.xml settings .. > > >payfone > > > org.apache.tapestry5.spring.TapestrySpringFilter > > > > AcegiFilterChainProxy > /* > > > > >payfone >/* > > > >AxisServlet > > org.apache.axis2.transport.http.AxisServlet >1 > > > >AxisServlet >/services/* > > > > Thanks , > > > On Mon, Oct 27, 2008 at 5:33 PM, Thiago H. de Paula Figueiredo < > [EMAIL PROTECTED]> wrote: > > > Could you post you AppModule please? > > > > Em Mon, 27 Oct 2008 09:00:40 -0300, Sagara Gunathunga < > > [EMAIL PROTECTED]> escreveu: > > > > > > Hi, > >> We are using Tapestry 5.0.14 for our project , and there is a > requirement > >> to expose some Web services using Axis on same application , so I put > >> my > >> Axis servlet/mapping under web.xml file but when I try to access the > >> services it does not work, as a example when I try to access > >> http://localhost:8080/services/MyService?wsdl it directed to Tapestry > >> not > >> to Axis . > >> > >> Than I try to use *contributeIgnoredPathsFilter* method as follows > >> > >> public static void contributeIgnoredPathsFilter(Configuration > >> configuration) > >>{ > >>System.out.println("...calling > >> contributeIgnoredPathsFilter"); > >>configuration.add("/services"); > >>} > >> > >> This also not worked and I observed that contributeIgnoredPathsFilter > not > >> call by the Ta
Re: problems with Tapestry IgnoredPaths
Em Mon, 27 Oct 2008 09:13:39 -0300, Sagara Gunathunga <[EMAIL PROTECTED]> escreveu: Hi, Hi! Well, I can't see anything wrong with your code. As a desperate measure, make all methods in your AppModule static. Anyway, it is a good practice. -- Thiago H. de Paula Figueiredo Independent Java consultant, developer, and instructor Consultor, desenvolvedor e instrutor em Java http://www.arsmachina.com.br/thiago - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problems with Tapestry IgnoredPaths
Hi, Thiago, thanks for your quick reply , here is my AppModule public class AppModule { public static void bind(ServiceBinder binder) { // binder.bind(MyServiceInterface.class, MyServiceImpl.class); // Make bind() calls on the binder object to define most IoC services. // Use service builder methods (example below) when the implementation // is provided inline, or requires more initialization than simply // invoking the constructor. } public static void contributeApplicationDefaults( MappedConfiguration configuration) { // Contributions to ApplicationDefaults will override any contributions // to // FactoryDefaults (with the same key). Here we're restricting the // supported // locales to just "en" (English). As you add localised message catalogs // and other assets, // you can extend this list of locales (it's a comma separated series of // locale names; // the first locale name is the default when there's no reasonable // match). configuration.add(SymbolConstants.SUPPORTED_LOCALES, "en"); // The factory default is true but during the early stages of an // application // overriding to false is a good idea. In addition, this is often // overridden // on the command line as -Dtapestry.production-mode=false configuration.add(SymbolConstants.PRODUCTION_MODE, "false"); } public RequestFilter buildTimingFilter(final Logger log) { return new RequestFilter() { public boolean service(Request request, Response response, RequestHandler handler) throws IOException { long startTime = System.currentTimeMillis(); try { // The responsibility of a filter is to invoke the // corresponding method // in the handler. When you chain multiple filters together, // each filter // received a handler that is a bridge to the next filter. return handler.service(request, response); } finally { long elapsed = System.currentTimeMillis() - startTime; log.info(String.format("Request time: %d ms", elapsed)); } } }; } public void contributeRequestHandler( OrderedConfiguration configuration, @InjectService("TimingFilter") RequestFilter filter) { // Each contribution to an ordered configuration has a name, When // necessary, you may // set constraints to precisely control the invocation order of the // contributed filter // within the pipeline. configuration.add("Timing", filter); } public static void contributeIgnoredPathsFilter( Configuration configuration) { System.out.println("...calling contributeIgnoredPathsFilter"); configuration.add("/services"); } } and also this is part of my Web.xml settings .. payfone org.apache.tapestry5.spring.TapestrySpringFilter AcegiFilterChainProxy /* payfone /* AxisServlet org.apache.axis2.transport.http.AxisServlet 1 AxisServlet /services/* Thanks , On Mon, Oct 27, 2008 at 5:33 PM, Thiago H. de Paula Figueiredo < [EMAIL PROTECTED]> wrote: > Could you post you AppModule please? > > Em Mon, 27 Oct 2008 09:00:40 -0300, Sagara Gunathunga < > [EMAIL PROTECTED]> escreveu: > > > Hi, >> We are using Tapestry 5.0.14 for our project , and there is a requirement >> to expose some Web services using Axis on same application , so I put >> my >> Axis servlet/mapping under web.xml file but when I try to access the >> services it does not work, as a example when I try to access >> http://localhost:8080/services/MyService?wsdl it directed to Tapestry >> not >> to Axis . >> >> Than I try to use *contributeIgnoredPathsFilter* method as follows >> >> public static void contributeIgnoredPathsFilter(Configuration >> configuration) >>{ >>System.out.println("...calling >> contributeIgnoredPathsFilter"); >>configuration.add("/services"); >>} >> >> This also not worked and I observed that contributeIgnoredPathsFilter not >> call by the Tapestry . >> >> Is there any way to resolve this ..? >> >> >> >> >> thanks , >> >> Sagara Gunathunga >> >> Blog - ssagara.blogspot.com >> Web - http://sagaras.awardspace.com/ >> > > > > -- > Thiago H. de Paula Figueiredo > Independent Java consultant, developer, and instructor > Consultor, desenvolvedor e instrutor em Java > http://www.arsmachina.com.br/thiago > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional
Re: problems with Tapestry IgnoredPaths
Could you post you AppModule please? Em Mon, 27 Oct 2008 09:00:40 -0300, Sagara Gunathunga <[EMAIL PROTECTED]> escreveu: Hi, We are using Tapestry 5.0.14 for our project , and there is a requirement to expose some Web services using Axis on same application , so I put my Axis servlet/mapping under web.xml file but when I try to access the services it does not work, as a example when I try to access http://localhost:8080/services/MyService?wsdl it directed to Tapestry not to Axis . Than I try to use *contributeIgnoredPathsFilter* method as follows public static void contributeIgnoredPathsFilter(Configuration configuration) { System.out.println("...calling contributeIgnoredPathsFilter"); configuration.add("/services"); } This also not worked and I observed that contributeIgnoredPathsFilter not call by the Tapestry . Is there any way to resolve this ..? thanks , Sagara Gunathunga Blog - ssagara.blogspot.com Web - http://sagaras.awardspace.com/ -- Thiago H. de Paula Figueiredo Independent Java consultant, developer, and instructor Consultor, desenvolvedor e instrutor em Java http://www.arsmachina.com.br/thiago - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
problems with Tapestry IgnoredPaths
Hi, We are using Tapestry 5.0.14 for our project , and there is a requirement to expose some Web services using Axis on same application , so I put my Axis servlet/mapping under web.xml file but when I try to access the services it does not work, as a example when I try to access http://localhost:8080/services/MyService?wsdl it directed to Tapestry not to Axis . Than I try to use *contributeIgnoredPathsFilter* method as follows public static void contributeIgnoredPathsFilter(Configuration configuration) { System.out.println("...calling contributeIgnoredPathsFilter"); configuration.add("/services"); } This also not worked and I observed that contributeIgnoredPathsFilter not call by the Tapestry . Is there any way to resolve this ..? thanks , Sagara Gunathunga Blog - ssagara.blogspot.com Web - http://sagaras.awardspace.com/