Search Interview Questions | More than 3000 questions in repository. There are more than 900 unanswered questions. Click here and help us by providing the answer. Have a video suggestion. Click Correct / Improve and please let us know. |
|
| |||||||||||
Spring - Interview Questions and Answers for 'Mvc' - 15 question(s) found - Order By Rating | |||||||||||
| |||||||||||
Ans. Default Bean scope in auto wiring is Singleton but Yes, that can be changed by specifying the Bean scope explicitly. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  spring boot   spring mvc  autowiring  bean scope   prototype bean scope intermediate | |||||||||||
| |||||||||||
Ans. The Model/View/Controller pattern, a strategy for dividing responsibility in a GUI component. The model is the data for the component. The view is the visual presentation of the component on the screen. The controller is responsible for reacting to events by changing the model. According to the MVC pattern, these responsibilities should be handled by different objects. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  mvc  design pattern Asked in 1 Companies   rare | |||||||||||
| |||||||||||
This question is still unanswered. Can you please provide an answer. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  core interfaces of Spring mvc | |||||||||||
| |||||||||||
Ans. MVC2 | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  struts2   struts   mvc2   j2ee | |||||||||||
| |||||||||||
Ans. Spring enables developers to develop enterprise-class applications using POJOs. The benefit of using only POJOs is that you do not need an EJB container product. Spring is organized in a modular fashion. Even though the number of packages and classes are substantial, you have to worry only about ones you need and ignore the rest. Spring does not reinvent the wheel instead, it truly makes use of some of the existing technologies like several ORM frameworks, logging frameworks, JEE, Quartz and JDK timers, other view technologies. Testing an application written with Spring is simple because environment-dependent code is moved into this framework. Furthermore, by using JavaBean-style POJOs, it becomes easier to use dependency injection for injecting test data. Spring is web framework is a well-designed web MVC framework, which provides a great alternative to web frameworks such as Struts or other over engineered or less popular web frameworks. Spring provides a convenient API to translate technology-specific exceptions (thrown by JDBC, Hibernate, or JDO, for example) into consistent, unchecked exceptions. Lightweight IoC containers tend to be lightweight, especially when compared to EJB containers, for example. This is beneficial for developing and deploying applications on computers with limited memory and CPU resources. Spring provides a consistent transaction management interface that can scale down to a local transaction | |||||||||||
Sample Code for spring | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  java   spring framework   mvc   spring container   architecture   technical architect   java architect   technical lead  ioc Asked in 2 Companies basic   frequent | |||||||||||
| |||||||||||
Ans. Struts 1 actions are singleton. So all threads operates on the single action object and hence makes it thread unsafe. Struts 2 actions are not singleton and a new action object copy is created each time a new action request is made and hence its thread safe. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  java   j2ee   mvc frameworks   struts   struts1   struts2   struts 1   struts 2   architecture | |||||||||||
Try 1 Question(s) Test | |||||||||||
| |||||||||||
Ans. There are seven core modules in spring Spring MVC The Core container O/R mapping DAO Application context Aspect Oriented Programming or AOP Web module | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   spring   mvc   frameworks   web applications | |||||||||||
Recently asked in TCS , Tech Mahindra, HCL , Accenture and Fidelity. | |||||||||||
| |||||||||||
Ans. The DispatcherServlet configured in web.xml file receives the request. The DispatcherServlet finds the appropriate Controller with the help of HandlerMapping and then invokes associated Controller. Then the Controller executes the logic business logic and then returns ModeAndView object to the DispatcherServlet. The DispatcherServlet determines the view from the ModelAndView object. Then the DispatcherServlet passes the model object to the View. The View is rendered and the Dispatcher Servlet sends the output to the Servlet container. Finally Servlet Container sends the result back to the user. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   spring   mvc   frameworks   web applications   architecture Asked in 11 Companies Basic   frequent | |||||||||||
| |||||||||||
Ans. Spring configuration file is an XML file. This file contains the classes information and describes how these classes are configured and introduced to each other. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   spring   mvc   frameworks   web applications   spring configuration file Asked in 1 Companies | |||||||||||
| |||||||||||
Ans. The default scope of bean is Singleton. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   spring   mvc   frameworks   web applications   bean | |||||||||||
| |||||||||||
Ans. The Spring Framework supports following five scopes - Singleton prototype request session global-session | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   spring   mvc   frameworks   web applications   beans   beans scope   at&t  fidelity | |||||||||||
Very Frequently asked Spring question. | |||||||||||
| |||||||||||
Ans. The Spring container is able to autowire relationships between collaborating beans. This means that it is possible to automatically let Spring resolve collaborators (other beans) for your bean by inspecting the contents of the BeanFactory without using | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   spring   mvc   frameworks   web applications   autowiring   beans   at&t   ge Asked in 9 Companies   frequent | |||||||||||
Very frequently asked.Usually among first few questions. | |||||||||||
| |||||||||||
Ans. MVC is a Design Pattern that facilititates loose coupling by segregating responsibilities in a Web application 1. Controller receives the requests and handles overall control of the request 2. Model holds majority of the Business logic, and 3. View comprise of the view objects and GUI component | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  j2ee   mvc   mvc design pattern   design pattern   struts   spring   web application   web frameworks   ebay Asked in 60 Companies basic   frequent | |||||||||||
Try 1 Question(s) Test | |||||||||||
| |||||||||||
Ans. Struts 1 | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  struts   j2ee   mvc frameworks   struts1   struts2 | |||||||||||
| |||||||||||
Ans. Controller | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  spring frmaework   spring mvc   rest   webservices | |||||||||||
| |||||||||||
| |||||||||||