在使用Eclipse 创建第一个 Servlet之后,并且配置好了tomcat,然后Run on server的之后,提示标题所示错误:

警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:SecondServlet' did not find a matching property.  
 
bing之后,有人提到如下操作方法:

解决办法:

1、在server控制台内,在服务器上点右键--属性

2、general选项卡中点switch location

这时,location变为:/servers/tomcat6.0 server at localhost.server

3、在project explore中找到tomcat项目--Tomcat v6.0 Server at localhost.server  这个文件 ,双击打开

4、在最下面的server option里选中publis module context to separate xml file.保存。(保存时要先停止服务器)   
 
但是设置好之后发现还是存在该问题。
 
然后在stackoverflow上有人说了,这个根本不是问题,不用管。

This is not an error. This is a warning. The difference is pretty huge. This particular warning basically means that the <Context> element in Tomcat's server.xml contains an unknown attribute source and that Tomcat doesn't know what to do with this attribute and therefore will ignore it.

Eclipse WTP adds a custom attribute source to the project related <Context> element in the server.xml of Tomcat which identifies the source of the context (the actual project in the workspace which is deployed to the particular server). This way Eclipse can correlate the deployed webapplication with an project in the workspace. Since Tomcat version 6.0.16, any unspecified XML tags and attributes in the server.xml will produce a warning during Tomcat's startup, even though there is no DTD nor XSD for server.xml.

Just ignore it. Your web project is fine. It should run fine. This issue is completely unrelated to JSF.  
 
最后发现确实这个问题可以不用管,我的站点无法访问的问题是因为我的eclipse没有设置为自动编译,也就是代码没有编译我就开始运行了,手动编译一下之后就好了,傻x了吧
 
 

从0开始学Java——eclipse下运行servlet程序警告:Setting property 'source' to 'org.eclipse.jst.jee.server:类名' did not find a matching property.的更多相关文章

  1. 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:JsonBlog' did not find a matching property.

    这个问题困扰很久了,逛了很多论坛,终于得以解决 我的控制台错误如下: 五月 , :: 下午 org.apache.catalina.startup.VersionLoggerListener log ...

  2. 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:esignmanage' did not find a matching property.解决

    1.开发环境: 环境:myeclipse2015+tomcat7+win10 2.异常: 偶尔在部署项目的时候回发现tomcat7部署后配置文件按照路径居然找不到自己的项目.httP://localh ...

  3. 警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:fhcq-oa' did not find a matching property.

    当你在使用Eclipse运行web项目时,你可能会看到控制台出现: 警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Settin ...

  4. 配置servers时,错误:Setting property 'source' to 'org.eclipse.jst.jee.server:hczm' did not find a matching property

    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.e ...

  5. Eclipse报错:Setting property 'source' to 'org.eclipse.jst.jee.server:xx' did not find a matching property

    Shell代码   警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to ' ...

  6. 警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:Weixin' did not find a matching property.

    警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclips ...

  7. Tomcat_异常_01_Setting property 'source' to 'org.eclipse.jst.jee.server:AWeiXin_QiYe_Demo' did not find a matching property

    关于解决方法: 1.解决Setting property 'source' to 'org.eclipse.jst.jee.server的问题 2.eclipse中server location为灰色 ...

  8. 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:20160928' did not find a matching property

    控制台看到如下警告: 症状原因: 在eclipse配置好的tomcat服务器上双击,打开tomcat服务器的配置界面.按如下操作配置服务器:在Server Options勾上的选项,会在你部署web项 ...

  9. Setting property 'source' to 'org.eclipse.jst.jee.server:web' did not find a matching property原因

    这个问题困扰了好久,虽然只是tomcat的一个警告,但强迫症让我总觉得不舒服,搜索了好多文章才找到知乎上一篇处理的最好的.另外:能找谷哥,尽量不要度娘,太浪费时间. 具体操作如下: 默认情况下,ser ...

随机推荐

  1. js检测浏览器型号

    公司要求做内部统计,要求监控客服玩游戏使用的浏览器的型号,是火狐的.谷歌的.还是IE的等等. [code lang="javascript"] /**** * 目前识别范围 * M ...

  2. Stack与Heap的区别

    申明:这里所说的栈和堆是程序内存管理中的栈和堆,而不是数据结构里的栈和堆. (1)保存的内容不同:栈里保存的是局部变量,而堆里保存的是动态申请的变量. (2)栈里的内存系统自动申请和释放,程序执行出申 ...

  3. Handler、Looper、MessageQueue、Thread源码分析

    关于这几个之间的关系以及源码分析的文章应该挺多的了,不过既然学习了,还是觉得整理下,印象更深刻点,嗯,如果有错误的地方欢迎反馈. 转载请注明出处:http://www.cnblogs.com/John ...

  4. Effective Java 26 Favor generic types

    Use generic types to replace the object declaration Add one or more type parameters to its declarati ...

  5. mysql,sql server,oracle 唯一索引字段是否允许出现多个 null 值?

    最近一个项目,涉及到sql server 2008,因为业务需求,希望建立一个唯一索引,但是发现在sql server中,唯一索引字段不能出现多个null值,下面是报错信息: CREATE UNIQU ...

  6. js追加元素,以及元素位置

    function setShow(val_param,text){ var ul = document.getElementById("copyhere"); //<li&g ...

  7. DW与DM

    DW组成部分简介 DW的组成部分有:针对数据源的分析.数据的ETL.数据的存储结构,元数据管理等. 数据源分析 主要是分析要抽取哪些数据,如何抽取(全量还是增量)?它的更新周期是怎么样的?它的数据质量 ...

  8. ssis trainning

    1. 防止包打开后hang住,可以使用delay validation=false. 2.2008R2 configuration 起作用的优先级? 一是des ign time. 二是运行的时候指定 ...

  9. Half Wavelength Dipole Antenna

    Reference : 1. wikipedia The dipole antenna is the simplest and most widely used class of antenna.It ...

  10. runv kill 流程分析

    1.runv/kill.go Action: func(context *cli.Context) 该函数做的工作很简单,就是通过grpc客户端,发送一个grpc请求而已,如下: c.Signal(n ...