- 浏览: 1490053 次
- 性别:
- 来自: 杭州
文章分类
- 全部博客 (525)
- SEO (16)
- JAVA-EE-Hibernate (6)
- JAVA-EE-Struts (29)
- JAVA-EE-Spring (15)
- Linux (37)
- JAVA-SE (29)
- NetWork (1)
- CMS (14)
- Semantic Research (3)
- RIA-Flex (0)
- Ajax-Extjs (4)
- Ajax-Jquery (1)
- www.godaddy.com (0)
- SSH (34)
- JavaScript (6)
- SoftwareEngineer (9)
- CMMI (0)
- IDE-Myeclipse (3)
- PHP (1)
- Algorithm (3)
- C/C++ (18)
- Concept&Items (2)
- Useful WebSite (1)
- ApacheServer (2)
- CodeReading (1)
- Socket (2)
- UML (10)
- PowerDesigner (1)
- Repository (19)
- MySQL (3)
- SqlServer (0)
- Society (1)
- Tomcat (7)
- WebService (5)
- JBoss (1)
- FCKeditor (1)
- PS/DW/CD/FW (0)
- DesignPattern (11)
- WebSite_Security (1)
- WordPress (5)
- WebConstruction (3)
- XML|XSD (7)
- Android (0)
- Project-In-Action (9)
- DatabaseDesign (3)
- taglib (7)
- DIV+CSS (10)
- Silverlight (52)
- JSON (7)
- VC++ (8)
- C# (8)
- LINQ (1)
- WCF&SOA (5)
- .NET (20)
- SOA (1)
- Mashup (2)
- RegEx (6)
- Psychology (5)
- Stock (1)
- Google (2)
- Interview (4)
- HTML5 (1)
- Marketing (4)
- Vaadin (2)
- Agile (2)
- Apache-common (6)
- ANTLR (0)
- REST (1)
- HtmlAnalysis (18)
- csv-export (3)
- Nucth (3)
- Xpath (1)
- Velocity (6)
- ASP.NET (9)
- Product (2)
- CSS (1)
最新评论
-
lt26w:
理解成门面模式应该比较容易明白吧
FacadePattern-Java代码实例讲解 -
lt26w:
看下面的例子比较明白.
FacadePattern-Java代码实例讲解 -
javaloverkehui:
这也叫文档,别逗我行吗,也就自己看看。
HtmlCleaner API -
SE_XiaoFeng:
至少也应该写个注释吧。
HtmlCleaner API -
jfzshandong:
...
org.springframework.web.filter.CharacterEncodingFilter 配置
在使用SSH添加 <listener> <listener-class>org.springframework.web.context.C
- 博客分类:
- JAVA-EE-Spring
在使用SSH添加
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
tomcat在启动的时候发生如下错误:
2008-9-28 11:13:01 org.apache.catalina.core.StandardContext start
严重: Error listenerStart
2008-9-28 11:13:01 org.apache.catalina.core.StandardContext start
严重: Context [/xxfire] startup failed due to previous errors
错误分析:
错误触发在web.xml中定义
- < context-param >
- < param-name > contextConfigLocation </ param-name >
- < param-value > /WEB-INF/context/ApplicationContext-*.xml </ param-value >
- </ context-param >
- < SPAN style = "COLOR: #000000" > < listener >
- < listener-class > < SPAN style = "BACKGROUND-COLOR: #ff6600" > org.springframework.web.context.ContextLoaderListener </ SPAN > </ listener-class >
- </ listener > </ SPAN >
- < context-param >
- < param-name > contextConfigLocation </ param-name >
- < param-value > /WEB-INF/context/ApplicationContext-*.xml </ param-value >
- </ context-param >
- < span style = "color: rgb(0, 0, 0);" > < listener >
- < listener-class > < span style = "background-color: rgb(255, 102, 0);" > org.springframework.web.context.ContextLoaderListener </ span > </ listener-class >
- </ listener > </ span >
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>/WEB-INF/context/ApplicationContext-*.xml</param-value>
</context-param>
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
检查spring配置管理xml文件。发现错误产生在:
- < bean id = "dataSource" class =" < SPAN style=" COLOR : #000000; BACKGROUND-COLOR: #ff6600" > org.apache.commons.dbcp.BasicDataSource </ SPAN > " >
- < property name = "driverClassName" value = "oracle.jdbc.driver.OracleDriver" > </ property >
- < property name = "url" value = "jdbc:oracle:thin:@localhost:1521:orcl" > </ property >
- < property name = "username" value = "sys8" > </ property >
- < property name = "password" value = "sys8" > </ property >
- </ bean >
- < bean id = "dataSource" class =" < span style=" color : rgb(0, 0, 0); background-color: rgb(255, 102, 0);" > org.apache.commons.dbcp.BasicDataSource </ span > " >
- < property name = "driverClassName" value = "oracle.jdbc.driver.OracleDriver" > </ property >
- < property name = "url" value = "jdbc:oracle:thin:@localhost:1521:orcl" > </ property >
- < property name = "username" value = "sys8" > </ property >
- < property name = "password" value = "sys8" > </ property >
- </ bean >
<bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource
">
<property name="driverClassName" value="oracle.jdbc.driver.OracleDriver"></property>
<property name="url" value="jdbc:oracle:thin:@localhost:1521:orcl"></property>
<property name="username" value="sys8"></property>
<property name="password" value="sys8"></property>
</bean>
上面所示的代码中,红色代码是产生错误的根源,在spring管理Hibernate的dataSource是用的是:
- <SPAN style= "COLOR: #000000" >org.springframework.jdbc.datasource.DriverManagerDataSource</SPAN>
- <span style= "color: rgb(0, 0, 0);" >org.springframework.jdbc.datasource.DriverManagerDataSource</span>
org.springframework.jdbc.datasource.DriverManagerDataSource
解决:
- < bean id = "dataSource" class =" < SPAN style=" BACKGROUND -COLOR: #ff6600" > org.springframework.jdbc.datasource.DriverManagerDataSource </ SPAN > " >
- < property name = "driverClassName" value = "oracle.jdbc.driver.OracleDriver" > </ property >
- < property name = "url" value = "jdbc:oracle:thin:@localhost:1521:orcl" > </ property >
- < property name = "username" value = "sys8" > </ property >
- < property name = "password" value = "sys8" > </ property >
- </ bean >
<script type="text/javascript"><!-- google_ad_client = "pub-4348265167276910"; /* 468x60, 个人博客 */ google_ad_slot = "2046406163"; google_ad_width = 468; google_ad_height = 60; //--> </script><script src="http://pagead2.googlesyndication.com/pagead/show_ads.js" type="text/javascript"> </script><script src="http://pagead2.googlesyndication.com/pagead/expansion_embed.js"></script><script src="http://googleads.g.doubleclick.net/pagead/test_domain.js"></script><script>google_protectAndRun("ads_core.google_render_ad", google_handleError, google_render_ad);</script>
发表评论
-
找不到 org.springframework.test.AbstractTransactionalDataSourceSpringContextTests;
2010-03-15 13:21 3925import or ... -
Spring三种注入IOC注入方式
2010-03-10 09:46 6610Type1 接口注入 我们常常借助接口来将调用者与实现者分离 ... -
Spring中常用的hql查询方法(getHibernateTemplate())
2009-12-09 16:35 988Spring中常用的hql查询方法(getHibernateT ... -
Spring源码分析-配置文件加载流程
2009-12-07 15:04 3317Spring配置文件加载流程 Spring配置文件 ... -
读Spring源代码之按图索骥(一)Context创建与配置文件加载
2009-12-07 13:57 1512Spring 和 Struts在web.xml中增加的配置 ... -
读Spring源代码之按图索骥(一)Context创建与配置文件加载
2009-12-07 13:56 1051Spring 和 Struts在web.xml中增加的配置 ... -
HTTP Status 404(The requested resource is not available)
2009-12-04 21:08 39167但是SSH中404不一定是以下错误! 是配置问题 HTTP S ... -
'dataSource': no matching editors or conversion strategy found
2009-12-04 19:42 3558the datasource property is look ... -
tomcat启动时出现的 严重: Error listenerStart
2009-12-04 16:15 1257最近看《WebWork.Spring.Hibernate 整 ... -
严重: Error filterStart-楼主竟然不给解决方案 = =
2009-12-04 16:14 2595今天在eclipse+myeclipse+tomcat5 ... -
org.springframework.web.filter.CharacterEncodingFilter 配置
2009-12-04 16:13 13760web.xml文件 <?xml version=&qu ... -
Spring2.0的包的说明
2009-12-04 16:12 1091Spring 压缩包目录说明 ... -
startup failed due to previous errors
2009-12-04 14:20 2576关键字: 异常,tomcat启动出错 ,xfire ,spri ... -
ApplicationContext.xml
2009-12-03 16:22 1162<?xml version="1.0" ...
相关推荐
在web.Xml中<context-param> <param-name>contextConfigLocation</param-name> ... <listener-class>org.springframework.web.context.request.RequestContextListener</listener-class> </listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <!-- Listener log4jConfigLocation --> <listener> <listener-class>org.springframework.web....
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <servlet> <servlet-name>test</servlet-name> <servlet-class>org.springframework.web.servlet....
<listener-class>org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap</listener-class> </listener> <servlet> <servlet-name>Resteasy</servlet-name> <servlet-class>org.jboss.resteasy....
org.springframework.web.context.ContextLoaderListener </listener-class> </listener> <filter> <filter-name>encodingFilter</filter-name> <filter-class> org.springframework.web.filter....
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> <!-- 默认找的文件名 --> </listener> <!-- Context Configuration locations for Spring XML files --> <context...
spring使用logback的扩展,使用起来非常方便。在web.xml中配置: ... <listener-class>ch.qos.logback.ext.spring.web.LogbackConfigListener</listener-class> </listener> 即可加载logback配置,使用logback。
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <!-- 利用spring监听 编码设置 --> <filter> <filter-name>SpringCharacterEncodingFilter</...
<listener-class>org.springframework.web.util.IntrospectorCleanupListener</listener-class> </listener> <servlet> <servlet-name>CXFService</servlet-name> <servlet-class>org.apache.cxf.transport...
<bean class="org.springframework.web.servlet.mvc.annotation. AnnotationMethodHandlerAdapter"/> <!-- ③:对模型视图名称的解析,即在模型视图名称添加前后缀 --> <bean class="org.springframework.web....
spring/applicationContext.xml </param-value> </context-param> <listener> <listener-class> org.springframework.web.context.ContextLoaderListener </listener-class> </listener> ApplicationContext * * * *...
</listener-class> </listener> <welcome-file-list> <welcome-file>index.jsp</welcome-file> </welcome-file-list> </web-app> 5 cas client 2.0 proxy 配置说明 proxy web.xml <?xml version="1.0" ...
监控器需要的jar,需在web.xml中配置<filter> <filter-name>monitoring</filter-name> <filter-class>net.bull.javamelody.MonitoringFilter</filter-class> </filter> <filter-mapping> <filter-name>...
<filter-class>org.jasig.cas.client.session.SingleSignOutFilter</filter-class> </filter> <filter-mapping> <filter-name>CAS Single Sign Out Filter</filter-name> <url-pattern>/*</url-pattern> </...
<listener-class>org.springframework.web.util.Log4jConfigListener</listener-class> </listener> <!-- 字符集 过滤器 --> <filter> <filter-name>CharacterEncodingFilter</filter-name> <filter-class...
<listener-class>test.ListenerDemo</listener-class> </listener> <!--定义了Web应用程序中会话的超时时限--> <session-config> <session-timeout>10</session-timeout> </session-config>
一 使用Axis和XFire发布Web Service 1.1 准备工作 Axis主页: http://ws.apache.org/ Axis下载:http://archive.apache.org/dist/ws/ XFire主页:http://xfire.codehaus.org/ XFire下载:...
proxool.0.9.1基础上做了修改。 改jar名称为:proxool-0.9.1.1... <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> 4.修正了proxool在多线程环境下的的错误。
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> 在struts.xml中配置对象创建工具为spring <constant name="struts.objectFactory" value="spring" />
<listener-class>net.bull.javamelody.SessionListener</listener-class> </listener> 2、需监控的web工程引入依赖jar包 jira-javamelody.jar jrobin-1.5.9.1.jar 3、如果您的web项目有SpringSecurity,修改...