第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

maven整合的SSH,struts2無法執(zhí)行對(duì)應(yīng)action的問題(action類沒有被實(shí)例化?)

maven整合的SSH,struts2無法執(zhí)行對(duì)應(yīng)action的問題(action類沒有被實(shí)例化?)

124839 2017-02-20 19:12:49
主要跳轉(zhuǎn)頁面為404,控制臺(tái)不報(bào)錯(cuò)。。下面是index.jsp頁面點(diǎn)擊鏈接跳轉(zhuǎn)到404控制臺(tái)部分信息(我在service類和dao類中添加了”static{System.out.print("XX========")}“這句話所以控制臺(tái)有顯示)二月?20,?2017?6:32:35?下午?org.springframework.beans.factory.xml.XmlBeanDefinitionReader?loadBeanDefinitions 信息:?Loading?XML?bean?definitions?from?file?[C:\Users\k570\NeonWorkspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\SSH-1\WEB-INF\classes\applicationContext.beans.xml] 二月?20,?2017?6:32:35?下午?org.springframework.beans.factory.xml.XmlBeanDefinitionReader?loadBeanDefinitions 信息:?Loading?XML?bean?definitions?from?file?[C:\Users\k570\NeonWorkspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\SSH-1\WEB-INF\classes\applicationContext.xml] 二月?20,?2017?6:32:36?下午?org.springframework.context.support.PropertySourcesPlaceholderConfigurer?loadProperties 信息:?Loading?properties?file?from?class?path?resource?[db.properties] Dao==================================== 二月?20,?2017?6:32:36?下午?com.mchange.v2.log.MLog?<clinit> 信息:?MLog?clients?using?java?1.4+?standard?logging. 二月?20,?2017?6:32:36?下午?com.mchange.v2.c3p0.C3P0Registry?banner 信息:?Initializing?c3p0-0.9.1.2?[built?21-May-2007?15:04:56;?debug??true;?trace:?10] ERROR?StatusLogger?Log4j2?could?not?find?a?logging?implementation.?Please?add?log4j-core?to?the?classpath.?Using?SimpleLogger?to?log?to?the?console... 二月?20,?2017?6:32:39?下午?com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource?getPoolManager 信息:?Initializing?c3p0?pool...?com.mchange.v2.c3p0.ComboPooledDataSource?[?acquireIncrement?->?3,?acquireRetryAttempts?->?30,?acquireRetryDelay?->?1000,?autoCommitOnClose?->?false,?automaticTestTable?->?null,?breakAfterAcquireFailure?->?false,?checkoutTimeout?->?0,?connectionCustomizerClassName?->?null,?connectionTesterClassName?->?com.mchange.v2.c3p0.impl.DefaultConnectionTester,?dataSourceName?->?2vsidn9mp9rw8y17kco88|5854e24c,?debugUnreturnedConnectionStackTraces?->?false,?description?->?null,?driverClass?->?com.mysql.jdbc.Driver,?factoryClassLocation?->?null,?forceIgnoreUnresolvedTransactions?->?false,?identityToken?->?2vsidn9mp9rw8y17kco88|5854e24c,?idleConnectionTestPeriod?->?0,?initialPoolSize?->?5,?jdbcUrl?->?jdbc:mysql:///ssh,?maxAdministrativeTaskTime?->?0,?maxConnectionAge?->?0,?maxIdleTime?->?0,?maxIdleTimeExcessConnections?->?0,?maxPoolSize?->?10,?maxStatements?->?0,?maxStatementsPerConnection?->?0,?minPoolSize?->?3,?numHelperThreads?->?3,?numThreadsAwaitingCheckoutDefaultUser?->?0,?preferredTestQuery?->?null,?properties?->?{user=******,?password=******},?propertyCycle?->?0,?testConnectionOnCheckin?->?false,?testConnectionOnCheckout?->?false,?unreturnedConnectionTimeout?->?0,?usesTraditionalReflectiveProxies?->?false?] Mon?Feb?20?18:32:40?CST?2017?WARN:?Establishing?SSL?connection?without?server's?identity?verification?is?not?recommended.?According?to?MySQL?5.5.45+,?5.6.26+?and?5.7.6+?requirements?SSL?connection?must?be?established?by?default?if?explicit?option?isn't?set.?For?compliance?with?existing?applications?not?using?SSL?the?verifyServerCertificate?property?is?set?to?'false'.?You?need?either?to?explicitly?disable?SSL?by?setting?useSSL=false,?or?set?useSSL=true?and?provide?truststore?for?server?certificate?verification. Mon?Feb?20?18:32:40?CST?2017?WARN:?Establishing?SSL?connection?without?server's?identity?verification?is?not?recommended.?According?to?MySQL?5.5.45+,?5.6.26+?and?5.7.6+?requirements?SSL?connection?must?be?established?by?default?if?explicit?option?isn't?set.?For?compliance?with?existing?applications?not?using?SSL?the?verifyServerCertificate?property?is?set?to?'false'.?You?need?either?to?explicitly?disable?SSL?by?setting?useSSL=false,?or?set?useSSL=true?and?provide?truststore?for?server?certificate?verification. Mon?Feb?20?18:32:40?CST?2017?WARN:?Establishing?SSL?connection?without?server's?identity?verification?is?not?recommended.?According?to?MySQL?5.5.45+,?5.6.26+?and?5.7.6+?requirements?SSL?connection?must?be?established?by?default?if?explicit?option?isn't?set.?For?compliance?with?existing?applications?not?using?SSL?the?verifyServerCertificate?property?is?set?to?'false'.?You?need?either?to?explicitly?disable?SSL?by?setting?useSSL=false,?or?set?useSSL=true?and?provide?truststore?for?server?certificate?verification. Mon?Feb?20?18:32:40?CST?2017?WARN:?Establishing?SSL?connection?without?server's?identity?verification?is?not?recommended.?According?to?MySQL?5.5.45+,?5.6.26+?and?5.7.6+?requirements?SSL?connection?must?be?established?by?default?if?explicit?option?isn't?set.?For?compliance?with?existing?applications?not?using?SSL?the?verifyServerCertificate?property?is?set?to?'false'.?You?need?either?to?explicitly?disable?SSL?by?setting?useSSL=false,?or?set?useSSL=true?and?provide?truststore?for?server?certificate?verification. Mon?Feb?20?18:32:40?CST?2017?WARN:?Establishing?SSL?connection?without?server's?identity?verification?is?not?recommended.?According?to?MySQL?5.5.45+,?5.6.26+?and?5.7.6+?requirements?SSL?connection?must?be?established?by?default?if?explicit?option?isn't?set.?For?compliance?with?existing?applications?not?using?SSL?the?verifyServerCertificate?property?is?set?to?'false'.?You?need?either?to?explicitly?disable?SSL?by?setting?useSSL=false,?or?set?useSSL=true?and?provide?truststore?for?server?certificate?verification. service======================================== 二月?20,?2017?6:32:42?下午?org.springframework.web.context.ContextLoader?initWebApplicationContext 信息:?Root?WebApplicationContext:?initialization?completed?in?6972?ms 二月?20,?2017?6:32:44?下午?org.apache.coyote.AbstractProtocol?start 信息:?Starting?ProtocolHandler?[http-nio-8080] 二月?20,?2017?6:32:44?下午?org.apache.coyote.AbstractProtocol?start 信息:?Starting?ProtocolHandler?[ajp-nio-8009] 二月?20,?2017?6:32:44?下午?org.apache.catalina.startup.Catalina?start 信息:?Server?startup?in?12652?ms下面是項(xiàng)目結(jié)構(gòu)以下按照一般流程貼代碼---actions.EmployeeAction(我在這個(gè)類中初始化時(shí)向控制臺(tái)打印一句話,方法中也添加了,然而控制臺(tái)并沒有打印這個(gè)類中的任何一句話)package?actions; import?java.util.Map; import?org.apache.struts2.interceptor.RequestAware; import?com.opensymphony.xwork2.ActionSupport; import?service.EmployeeService; public?class?EmployeeAction?extends?ActionSupport?implements?RequestAware{ ????static{ ??????? ????????System.out.println("是否進(jìn)入此類?-------------------------"); ???????? ????} ????private?static?final?long?serialVersionUID?=?1L; ???? ????private?EmployeeService?employeeService; ???? ????public?void?setEmployeeService(EmployeeService?employeeService)?{ ????????this.employeeService?=?employeeService; ????} ???? ????public?String?list()?{ ????????request.put("employees",?employeeService.getAll()); ????????System.out.println("====================方法被執(zhí)行==================="); ????????return?"list"; ????} ??????? ????private?Map<String?,?Object>?request; ???? ????@Override ????public?void?setRequest(Map<String,?Object>?arg0)?{ ????????this.request?=?arg0; ????} ???? }---service.EmployeeServicepackage?service; import?java.util.List; import?dao.EmployeeDao; import?entity.Employee; public?class?EmployeeService?{ ????static{ ????????System.out.println("service========================================"); ????} ???? ????private?EmployeeDao?employeeDao; ???? ???public?void?setEmployeeDao(EmployeeDao?employeeDao)?{ ???? ???????this.employeeDao?=?employeeDao; } ???? ????public?List<Employee>?getAll()?{ ???????? ????????return?employeeDao.getAll();???? ????} }---dao.EmployeeDaopackage?dao; import?java.util.List; import?org.hibernate.Session; import?org.hibernate.SessionFactory; import?entity.Employee; public?class?EmployeeDao?{ ???? ????static{ ????????System.out.println("Dao===================================="); ????} ???? ????private?SessionFactory?sessionFactory; ????public?void?setSessionFactory(SessionFactory?sessionFactory)?{ ????????this.sessionFactory?=?sessionFactory; ????} ???? ????/**獲取session,因?yàn)榘聞?wù)所以選用getCurrentSession()方法來獲取 ?????*?@return ?????*/ ????public?Session?getSession(){ ????????return?this.sessionFactory.getCurrentSession(); ????} ???? ????public?List<Employee>?getAll()?{ ????????String?hql?=?"FROM?Employee";??????? ????????return?getSession().createQuery(hql).list();????????? ????} } //提問中有字?jǐn)?shù)限制所以在下面提問中補(bǔ)充相關(guān)配置文件代碼。。。。。。。。。。。。。。。。。。。。。。。。。。。
查看完整描述

6 回答

?
qq_意猶未盡丶_04320300

TA貢獻(xiàn)1條經(jīng)驗(yàn) 獲得超0個(gè)贊

跟我一樣 鹵煮解決了告訴我一下啊 所有配置都是OK的 就是action不執(zhí)行

查看完整回答
反對(duì) 回復(fù) 2017-04-17
?
124839

TA貢獻(xiàn)2條經(jīng)驗(yàn) 獲得超1個(gè)贊

http://img1.sycdn.imooc.com//58ad446c000100c504930765.jpg

這個(gè)小紅點(diǎn)意思是啥?

查看完整回答
反對(duì) 回復(fù) 2017-02-22
?
慕粉4075985

TA貢獻(xiàn)104條經(jīng)驗(yàn) 獲得超33個(gè)贊

你的項(xiàng)目為什么有紅叉


查看完整回答
反對(duì) 回復(fù) 2017-02-22
  • 124839
    124839
    貌似是eclipse 插件的問題。。與項(xiàng)目沒有關(guān)系。?,F(xiàn)在eclipse后臺(tái)更新了一些什么東西,現(xiàn)在不顯示紅叉。。
  • 慕粉4075985
    慕粉4075985
    這樣寫試試 <result name="list">WEB-INF/views/emp-list.jsp</result> <a href="${pageContext.request.contextPath}emp-list">List all employees </a>
  • 124839
    124839
    仍然不對(duì)的,親。。
?
慕俠7578997

TA貢獻(xiàn)5條經(jīng)驗(yàn) 獲得超1個(gè)贊

可能是你result的路徑不對(duì) 用/WEB-INF/emp_list.jsp看看

查看完整回答
反對(duì) 回復(fù) 2017-02-21
  • 124839
    124839
    這個(gè)action類沒有被實(shí)例化,可能有您說的路徑問題。不過目前action類沒有被實(shí)例化的情況下路徑是否有問題真不清楚,因?yàn)閾Q了您說的路徑也是一樣無法執(zhí)行action,頁面404。。
  • 慕俠7578997
    慕俠7578997
    applicationContext.beans.xml這個(gè)XML是不是沒包含在applicationContext里?
  • 慕俠7578997
    慕俠7578997
    你把類的get set方法加上 不然屬性是注入不了的
點(diǎn)擊展開后面2
  • 6 回答
  • 1 關(guān)注
  • 4712 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)