In my application context I have defined properties file:
<context:property-placeholder location="classpath:application.properties" />
I want to get value of the property defined in that file on JSP page. Is there a way to do that in the way
${something.myProperty}?
...
I have a web app running Spring 3.0 and using Spring-MVC. I have a few controllers set up like this:
@Controller
@RequestMapping("/admin")
@SessionAttributes({"clientLogin", "selectTab", "user", "redirectUrl"})
public class AdminController {
...
}
@Controller
@SessionAttributes({"clientLogin", "selectTab", "user", "redirectUrl"})
publi...
Hi all,
I'm currently in the process of migrating an application from Spring 2.5.6 to Spring 3.0.4 and Spring Security 3.0.2 and I was wondering if there was some kind of execution flow for both of these framework so that developpers could know what is being called before what.
For those of you who are doing this kind of migration, I ca...
Hi,
I am using Glassfish 3.0 with Spring Security 3.0 and exposed one of my EJBs as webservice using JAX-WS 2.0 annotation. I have generated WSDL and other portable artifacts and can access the webservice using a WS-client.
Using JAAS I can make the webservice secured with "HTTP Basic Authentication" (using jdbc realm).
But using Spring...
Consider the following classes' structure:
BaseDAO with methods to crest PreparedStatement and get connection from pool
AccountDAO extends BaseDAO to work with Account table via JDBC. This class is singleton
AccountService witch calls methods of AccountDAO like this:
AccountDAO.getInstance().login(name, password).
AccountDAO is a Spr...
I seem to have a memory leak, one of the culprits seems to be the ConnectionProperty, whether it is String, Int or Boolean ones. e.g.:'com.mysql.jdbc.ConnectionPropertiesImpl$BooleanConnectionProperty', millions seem to be staying around and not being GC'd.
Here are my settings for the DB, Session Factory, Hibernate and Pooling etc..:
...
I have a Spring MVC (3) Controller and I trying to put in the annotations but failed Heres my code outline
@Controller
public class SpringController{
@RequestMapping("/welcome")
public String myHandler(@RequestParam("id" String id)){
//My RequestParm is able to do the job of request.getParameter("id")
HttpSession session = request...
We have multiple modules (e.g. master data module, physical module, derivative module, risk module etc) having one war for each of them. Since master data module will be used by all other modules, we can put dependency of mdm jar in all other modules. All modules other than master data requires some functionality from each other. We don'...
Is it possible to create a factory or proxy that can decide if thread is running in (Web)Request or background-process (ie. scheduler) and then depending on that information, it creates a session bean or a prototype bean?
Example (pseudo Spring config :)
<bean id="userInfoSession" scope="session" />
<bean id="userInfoStatic" scope="pro...
I am new to Spring MVC, need guidance
My jsp is like :
<form:form name="form1" method="post" action="input.htm?method=getHealth">
.......
<td >
<form:select path="envList">
<form:options items="${envList}"/>
</form:select>
</td>
My .java is like:
public class InputController extends MultiActionController {
public ModelAndView ge...
I need to create a variable number of these based on a configuration value, the intention is to have multiple consumers where each corresponds to a physical resource that can only be used by one thing at a time to process the message.
...
Is Concurrent method access in singleton class thread safe?
I am using Spring framework (MVC) with the default scope as Singleton.
For example, if the controller of my web application is a Singleton class, are the methods declared to access Model/Business/DB classes thread safe, if accessed by multiple threads at the same time? How abo...
I am interested in having a web configuration/admin page for a website.
Is it more common to store a websites
configuration in a database, xml, or
.properties files?
What does the data model (classes)
usually look like?
If stored in a file, is concurrent
access typically handled and how?
Are there any good examples for a
generic site a...
I am using Spring MVC for my web application and I am integrating Velocity for templating my emails.
I am getting the following 500 error when It attempts to send my email.
org.apache.velocity.exception.ResourceNotFoundException:
Unable to find resource '/WEB-INF/velocity/registrationEmail.vm'
I am aware of what this means and what ...
I have the following class defined as a bean:
@Repository("userDao")
public class UserDao extends JdoDaoSupport implements IUserDao {...}
The class JdoDaoSupport requires a persistenceManagerFactory injected into it.
I've declared the persistenceManagerFactory bean in XML, how do I inject it to my superclass using annotations?
JdoDa...
I need a readable tutorial on working with Flex+BlazeDS+Spring+GAE (storing more than one table in GAE Datastore). Is there any such?
...
I record a history of all changes to some entities and am about to implement a mechanism similar to Envers to take care of this automatically. My question is whether to use Hibernate interceptors or their event system?
It seems like interceptors is a little simpler and does all I need. And Hibernate's own documentation suggests using ...
I am able to display the SPRING_SECURITY_LAST_EXCEPTION.message ("Bad Credentials") when a user tries to log in with incorrect credentials.
My login jsp currently uses the following code:
<c:if test="${not empty SPRING_SECURITY_LAST_EXCEPTION.message}">
<c:out value="${SPRING_SECURITY_LAST_EXCEPTION.message}" />
...
Hi,
I am trying to deploy an .ear to Glassfish v3. The .ear is a "Spring" application made up of two modules:
domain.jar (entities, persistence)
service.jar (business logic with spring bean config).
I'm creating the .ear with Maven ear plugin and the resultant dir structure of the .ear is as follows:
/APP-INF/lib/domain.jar;servic...
Trying to deploy Spring's mvc-basic in Equinox container.
Brief error (full below):
org.springframework.beans.factory.parsing.BeanDefinitionParsingException: Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://www.springframework.org/schema/context]
Offending resource: ServletContext resou...