You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Paul Benedict <pb...@apache.org> on 2008/12/01 06:03:55 UTC

Re: FW: Migratring to struts 1.2.7 from struts1.0b

I don't think you should modify the Action. That's going give you
headaches as you continue to upgrade. A better approach is to subclass
the Controller and make the change you need.

Paul

On Wed, Nov 26, 2008 at 3:37 AM, Rajil <ra...@appliedcommerce.com> wrote:
> Hi;
>
> I solved the problem.
>
> It's because of struts1.2.7 doesn't have perform method.  And the action
> class returns with null when it doesn't find execute method in it's
> inherited class.
>
> I have modified struts action class to call perform method instead of
> execute method.
>
> Mr. Paul, Is this right approach?  I modified this class to not to change my
> 1000s of classes for to have execute method instead of perform.  I simply
> changed struts org.apache.struts.action.Action class.
>
> Ya I know, I won't be able to use execute method now-onwards, isn't it?
>
> Is there any other drawback or problem?  Let me know if any..
>
>
> -----Original Message-----
> From: Rajil [mailto:rajil@appliedcommerce.com]
> Sent: Wednesday, November 26, 2008 10:45 AM
> To: 'Struts Users Mailing List'
> Subject: RE: Migratring to struts 1.2.7 from struts1.0b
>
>
> Thanks for your valuable time Paul.
>
> Actually I solved this issue by deleting "EnumerateTeg" from my existing tag
> library.
>
> But now I am getting another problem, please see if you can guide.
>
> Struts 1.0 was using struts-template.tld and new version that I am using
> "1.2.7" this library is replace by struts-tiles.tld.
>
> Now, in web.xml I pointed struts-template.tld to struts-tiles.tld. Moreover,
> I have both the Tag Libraries available in my project.
>
> Now I am getting some problem; I don't know why this is happening.
>
> I have redirects defined in my struts-config.xml.
> e.g.
>
> <action path="/redirect" type="com.applied.fincrm.utils.RedirectAction"
> input="" name="null" scope="request">
> <forward name="reportLimit" path="/protected/withMenu.jsp?self=repL.jsp"/>
> <forward ...
> </action>
>
> Now, when I write
>
> http://localhost:8055/fin/redirect.do?target=reportLimit
>
> This is not rendering the page and no errors in logs.  It shows blank page.
>
> But when I call this URL explicitly;
>
> http://localhost:8055/fin/protected/withMenu.jsp?self=repL.jsp
>
> It displays the page.
>
> Simply, It is not redirecting to the page requested.  I think there can be
> problem with ActionForward.  "Whereas this was running under struts 1.0"
>
> Can you guide please.
>
>
>
> -----Original Message-----
> From: paulus.benedictus@gmail.com [mailto:paulus.benedictus@gmail.com] On
> Behalf Of Paul Benedict
> Sent: Wednesday, November 26, 2008 4:28 AM
> To: Struts Users Mailing List
> Subject: Re: Migratring to struts 1.2.7 from struts1.0b
>
> Sounds like you have an old tag library reference sticking around. Try
> deleting any TLD in your webapp root.
>
> On Tue, Nov 25, 2008 at 3:32 AM, Rajil <ra...@appliedcommerce.com> wrote:
>> Hi All;
>>
>>
>>
>> I am using struts beta version 1.0 in my application.  I am migrating this
>> application to struts v1.2.7.
>>
>>
>>
>> I have corrected problems like error.isEmpty instead of errors.empty()
> etc.
>> in my existing application.  And classes are compiled very well.
>>
>>
>>
>> Now, I am facing problem with JSP.  I am not able to run the application.
>> It shows some error like:
>>
>>
>>
>> org.apache.jasper.JasperException: Failed to load or instantiate
>> TagExtraInfo class: org.apache.struts.taglib.EnumerateTei
>>
>>
> org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.
>> java:51)
>>
>>
> org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409
>> )
>>
>>
> org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:281
>> )
>>
>>
> org.apache.jasper.compiler.TagLibraryInfoImpl.createTagInfo(TagLibraryInfoIm
>> pl.java:423)
>>
>>
> org.apache.jasper.compiler.TagLibraryInfoImpl.parseTLD(TagLibraryInfoImpl.ja
>> va:249)
>>
>>
> org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java
>> :163)
>>
>> org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:424)
>>        org.apache.jasper.compiler.Parser.parseDirective(Parser.java:493)
>>        org.apache.jasper.compiler.Parser.parseElements(Parser.java:1557)
>>        org.apache.jasper.compiler.Parser.parse(Parser.java:127)
>>
>>
> org.apache.jasper.compiler.ParserController.doParse(ParserController.java:21
>> 2)
>>
>>
> org.apache.jasper.compiler.ParserController.parse(ParserController.java:101)
>>        org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:156)
>>        org.apache.jasper.compiler.Compiler.compile(Compiler.java:296)
>>        org.apache.jasper.compiler.Compiler.compile(Compiler.java:277)
>>        org.apache.jasper.compiler.Compiler.compile(Compiler.java:265)
>>
>>
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:5
>> 64)
>>
>>
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:3
>> 02)
>>
>> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
>>        org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
>>        javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
>>
>> org.securityfilter.filter.SecurityFilter.doFilter(SecurityFilter.java:188)
>>
>> root cause
>>
>> java.lang.ClassNotFoundException: org.apache.struts.taglib.EnumerateTei
>>
>>
> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
>> a:1363)
>>
>>
> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
>> a:1209)
>>
>>
> org.apache.jasper.compiler.TagLibraryInfoImpl.createTagInfo(TagLibraryInfoIm
>> pl.java:420)
>>
>>
> org.apache.jasper.compiler.TagLibraryInfoImpl.parseTLD(TagLibraryInfoImpl.ja
>> va:249)
>>
>>
> org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java
>> :163)
>>
>> org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:424)
>>        org.apache.jasper.compiler.Parser.parseDirective(Parser.java:493)
>>        org.apache.jasper.compiler.Parser.parseElements(Parser.java:1557)
>>        org.apache.jasper.compiler.Parser.parse(Parser.java:127)
>>
>>
> org.apache.jasper.compiler.ParserController.doParse(ParserController.java:21
>> 2)
>>
>>
> org.apache.jasper.compiler.ParserController.parse(ParserController.java:101)
>>        org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:156)
>>        org.apache.jasper.compiler.Compiler.compile(Compiler.java:296)
>>        org.apache.jasper.compiler.Compiler.compile(Compiler.java:277)
>>        org.apache.jasper.compiler.Compiler.compile(Compiler.java:265)
>>
>>
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:5
>> 64)
>>
>>
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:3
>> 02)
>>
>> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
>>        org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
>>        javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
>>
>> org.securityfilter.filter.SecurityFilter.doFilter(SecurityFilter.java:188)
>>
>>
>>
>>
>>
>> Is there any change in TagLibrary also?  Do I have to replace my tag
>> libraries and their reference in web.xml file ?  Do I need to change the
> JSP
>> files also?
>>
>>
>>
>> Please suggest..
>>
>>
>>
>> regards,
>>
>> Rajil Davda
>>
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
> __________ NOD32 3641 (20081126) Information __________
>
> This message was checked by NOD32 antivirus system.
> http://www.eset.com
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org