[Broker] INFO [main] org.springframework.web.struts.ContextLoaderPlugIn.init(218) | ContextLoaderPlugIn for Struts ActionServlet 'action, module '': initialization started
[Broker] INFO [main] org.apache.catalina.core.ApplicationContext.log(647) | Initializing WebApplicationContext for Struts ActionServlet 'action', module ''
[Broker] INFO [main] org.springframework.context.support.AbstractApplicationContext.prepareRefresh(378) | Refreshing org.springframework.web.context.support.XmlWebApplicationContext@16e334a: display name [WebApplicationContext for namespace 'action-servlet']; startup date [Mon Mar 03 11:51:01 CST 2008]; root of context hierarchy
[Broker] INFO [main] org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(293) | Loading XML bean definitions from ServletContext resource [/WEB-INF/beans.xml]
[Broker] INFO [main] org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(393) | Bean factory for application context [org.springframework.web.context.support.XmlWebApplicationContext@16e334a]: org.springframework.beans.factory.support.DefaultListableBeanFactory@1fb2ef9
[Broker] INFO [main] org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(275) | Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@1fb2ef9: defining beans [dataSource,sessionFactory,Factory,logindao,loginservice,/userLogin]; root of factory hierarchy
[Broker] INFO [main] org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(743) | Building new Hibernate SessionFactory
[Broker] INFO [main] org.springframework.web.struts.ContextLoaderPlugIn.initWebApplicationContext(298) | Using context class 'org.springframework.web.context.support.XmlWebApplicationContext' for servlet 'action'
[Broker] INFO [main] org.springframework.web.struts.ContextLoaderPlugIn.init(235) | ContextLoaderPlugIn for Struts ActionServlet 'action', module '': initialization completed in 18390 ms
[Broker] INFO [main] org.apache.catalina.core.ApplicationContext.log(647) | Initializing WebApplicationContext for Struts ActionServlet 'action', module ''
[Broker] INFO [main] org.springframework.context.support.AbstractApplicationContext.prepareRefresh(378) | Refreshing org.springframework.web.context.support.XmlWebApplicationContext@16e334a: display name [WebApplicationContext for namespace 'action-servlet']; startup date [Mon Mar 03 11:51:01 CST 2008]; root of context hierarchy
[Broker] INFO [main] org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(293) | Loading XML bean definitions from ServletContext resource [/WEB-INF/beans.xml]
[Broker] INFO [main] org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(393) | Bean factory for application context [org.springframework.web.context.support.XmlWebApplicationContext@16e334a]: org.springframework.beans.factory.support.DefaultListableBeanFactory@1fb2ef9
[Broker] INFO [main] org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(275) | Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@1fb2ef9: defining beans [dataSource,sessionFactory,Factory,logindao,loginservice,/userLogin]; root of factory hierarchy
[Broker] INFO [main] org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(743) | Building new Hibernate SessionFactory
[Broker] INFO [main] org.springframework.web.struts.ContextLoaderPlugIn.initWebApplicationContext(298) | Using context class 'org.springframework.web.context.support.XmlWebApplicationContext' for servlet 'action'
[Broker] INFO [main] org.springframework.web.struts.ContextLoaderPlugIn.init(235) | ContextLoaderPlugIn for Struts ActionServlet 'action', module '': initialization completed in 18390 ms
解决方案 »
- Spring和JPA的整合问题
- 动态规划算法来实现零件装配问题!求算法!
- tomcat下怎么发布jsp
- jsp+tomcat发布问题
- 安装SUN java System Portal Server的问题
- Java程序打包的时候如何将使用的其它Jar包也给打包进去
- 有人写过maven的模板吗?我想写个自己的项目模板,定义自已的目录结构等。不知怎么写
- 视频教程愿意和大家分享!
- 问一个EJB的简单问题!为什么调用EJB的客户端没有STUB啊??
- J2EE的小问题,急寄给
- Struts的Validator问题,比较复杂求达人解答!
- 我的第一个EJB程序,报javax.naming.NameNotFoundException错
不过疑问似乎更多了
<value>org/lostrue/model/Logintable.hbm.xml</value>
</list>中间是不是少了几行
既然使用了Spring DAO为什么不继承HibernateDaoSupport呢?这样用Spring控制session,不是更好些吗?其次:
你贴的1楼的log好像都是info信息。连告警都没有,怎么挑找问题的??最后:
思路没问题的说,只是在实现上很混乱。
//findbyId 等DAO方法。不用考虑session
public Users FindById(Long Id) {
...
}
}
其次配置时注入<!-- DAO -->
<bean id="alarmDAO" class="com.telestone.web.dao.AlarmDAO">
<property name="entityManagerFactory"
ref="entityManagerFactory" />
</bean>
呵呵,楼上的有道理,其实spring对hibernate已经进行了封装
DAO以前封装好了
session我给filter管理了