Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error: No configuration found for the specified action

 
Nash Wembley
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am encountering the following on submit of JSP page.

No configuration found for the specified action: '/ACFWeb/acf/breakFixDataAssetSearchResults' in namespace: '/jsp'

This is what I am doing:
  • I have a JSP page say JSP1 which is in namespace "acf" and this page is one of the results of action class Action1. On submit of JSP1 I try to load JSP2. The "submit" javascript function of JSP1 has the following line of code.



  • JSP2 i.e. dataassetbreakFix.jsp gets loaded.
  • Now on submit of JSP2, I am unable to invoke the action class for rendering another page JSP3 and the aforementioned error is displayed in the server log. Below is the Javascript Submit function of JSP2




  • Please note that:
  • All JSP's are inside the folder named "jsp"
  • There is only one namespace i.e. "acf".
  • There is no action class associated with JSP2 and therefore is invoked directly by JSP1


  • My Struts.xml file:


    What is going wrong here? Why the Struts framework keeps looking for non-existing namespace "jsp" when actually all actions classes are within "acf" namespace.
     
    David Newton
    Author
    Rancher
    Posts: 12617
    IntelliJ IDE Ruby
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Probably because you're directly accessing a JSP (considered a poor practice, especially when it's trivial to avoid it) so it's messing up the link. Without the JSP code it's impossible to help beyond a guess.

    Directly accessing JSPs in a Struts 2 app breaks the encapsulation offered by the framework--is there any particular reason you're doing it?
     
    Nash Wembley
    Greenhorn
    Posts: 7
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Thanks for your reply David. Yes what you said did come to my mind. I thought Struts would figure out by itself & this strategy looked pretty harmless to me. I simply wanted to avoid having another Action class in order to render JSP2. Maybe I was thinking that by directly accessing JSP2 the request would be processed faster.

    I still feel the framework shouldn't be so stringent and should give us developers some flexibility for such scenarios.

    Anyways I will try to stick to the norm.
     
    David Newton
    Author
    Rancher
    Posts: 12617
    IntelliJ IDE Ruby
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    For me the safety and regularity of this:far outweighs the "overhead" of calling an empty action (pretty cheap in Java).
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic