• Exceptions,  Interview Questions,  Learn Struts,  Struts 1,  Struts 2

    org.apache.jasper.JasperException: Unable to read TLD “META-INF/tlds/struts-tiles.tld” from JAR file org.apache.jasper.JasperException: Failed to load or instantiate

    All of sudden scenarios come over where struts-tiles.xml or struts component missing from struts.jar and it is present into jar, it usually come under circumstances when migration of server took place. Issue description: org.apache.jasper.JasperException: Unable to read  TLD “META-INF/tlds/struts-tiles.tld” from JAR file <struts.jar> org.apache.jasper.JasperException: Failed to load or instantiate or files usually present struts.xml are not caught by application server at runtime. I would recommend you to please go through the following steps to resolve the issue: Step1: In case Application server is not able to render/called classes or xml and throw errors, it means two same classes or component come accross within two jars, same can be here as Tomcat and struts.jar…

    Comments Off on org.apache.jasper.JasperException: Unable to read TLD “META-INF/tlds/struts-tiles.tld” from JAR file org.apache.jasper.JasperException: Failed to load or instantiate
  • ActionForm,  Learn Struts,  Struts 1,  Struts Components

    Need for ActionForm not to be an interface?

    We have ActionForm in aour Struts application which is a class file and not an interface, what will happen in case if we implement it through Interface, There are few reasons why an Action Form should not an interface. Adding a new method in interface (in case new version of struts is released) will break earlier application’s form bean. While in case of base class one can add new method as default implementation which doesn’t break earlier applications to use new version, its a simple extensiblity issue while making ActionForm as Interface. In case Action Form is being an interface, struts developers would be required to use their business objects…

    Comments Off on Need for ActionForm not to be an interface?
  • Controler,  Interview Questions,  Learn Struts,  Struts 1

    What is ActionServlet?

    ActionServlet class act as the “controller” component in the Model-View-Controller (MVC) design pattern for an applications which is commonly called as “Model 2” architecture. Application may have one instance of this servlet class which is used to receive and processes all requests that change the state of a client’s interaction with the application. The servlet delegates the handling of a request to a RequestProcessor class object. The RequestProcessor is used to process request and it selects and invokes an Action class to perform the requested business logic. Action classes can change the state of the application’s interaction with the client by updating or creating JavaBeans that are stored as request…

    Comments Off on What is ActionServlet?
  • Interview Questions,  Learn Struts,  Struts 1,  Struts 2

    Interview Questions on struts 1 and struts 2

    The interview questions asked to me in my various interview, Please be prepared in case you are having one: 1.) What is difference between struts 1 and struts 2?2.) How is the MVC design pattern used in Struts framework?3.) What is ActionServlet?4.) What is RequestProcessor, and how to create your own RequestProcessor?5.) How you will make available any Message Resources Definitions file to the Struts Framework Environment?6.) Is Struts Thread safe?7.) What is workflow of Struts application?8.) How to use vo,dao and dto design patterns in struts framework?9.) Can we change location for struts-config.xml?10.) What are different types of Actions we have in Struts?11.) What is DynaActionForm, and what is…

    Comments Off on Interview Questions on struts 1 and struts 2
  • Action,  Controler,  Interview Questions,  Learn Struts,  Struts 1,  Struts 2,  Struts Components

    What is Action Class?

    An Action class in the struts application extends Struts ‘org.apache.struts.action.Action” Class. Action class acts as wrapper around the business logic and provides an inteface to the application’s Model layer. It acts as glue between the View and Model layer. It also transfers the data from the view layer to the specific business process layer and finally returns the procssed data from business layer to the view layer. An Action works as an adapter between the contents of an incoming HTTP request and the business logic that corresponds to it. Then the struts controller (ActionServlet) slects an appropriate Action and creates an instance if necessary, and finally calls execute method. To…

    Comments Off on What is Action Class?