Weblogic deployment of web project code named null obtaining project issues

EDITORIAL

I met once, a long time to forget, or a good memory as bad written, write about it .Windows deployed to get the project under the name written deployed to Tomcat and Weblogic under Linux this problem before.

Key Code

java code

= webname Request.getSession () GetServletContext () getContextPath ();.. 
log.error ( "Web item name with a slash to the ================ Weblogic:" + webname); 

webname = webName.substring (. 1 , webName.length ()); 
log.error ( "project Web without the slash ================ Weblogic name : "+ webname); 

String rootPath = the this . .getClass () the getResource (" /. ".) getPath () the replaceAll (" ^ \\ / "," " ); 
log.error ( " ====== ========== Weblogic the rootPath is: "+ rootPath);

Console output (which is deploying Windows system to output content Tomcat under, Weblogic inconvenient to log posted)

Console 
[ 2019-10-09 09:05:23] [ERROR] [org.jeecgframework.web.system.controller.core.LoginController: 896] ================ web project name with a slash under Weblogic is: / jeecg 
[ 2019-10-09 09:05:23] [ERROR] [org.jeecgframework.web.system.controller.core.LoginController: 899] ===== =========== Web project name without a slash at Weblogic is: jeecg 
[ 2019-10-09 09:05:23] [ERROR] [org.jeecgframework.web.system.controller. core.LoginController: 903] ================ Weblogic the rootPath as: H: / cqyyt / jeecg / target / jeecg / WEB-INF / classes /

 

thank

Guess you like

Origin www.cnblogs.com/yadongliang/p/11639949.html