https://bz.apache.org/bugzilla/show_bug.cgi?id=63249

--- Comment #5 from AnhT <anu...@163.com> ---
(In reply to AnhT from comment #3)
> Hi, Mark Thomas. Thank you very much for your prompt response. 
> There are other 6 inconsistent logging practices shown below, and I think
> the ERROR level is more appropriate to them.
> ============StandardService.java===================
> full path: tomcat\java\org\apache\catalina\core\StandardService.java
> log line num: 137; 144; 149; 155
> 
> 132         if (getState().isAvailable()) {
> 133             if (this.engine != null) {
> 134                 try {
> 135                     this.engine.start();
> 136                 } catch (LifecycleException e) {
> 137                    
> log.warn(sm.getString("standardService.engine.startFailed"), e);
> 138                 }
> 139             }
> 140             // Restart MapperListener to pick up new engine.
> 141             try {
> 142                 mapperListener.stop();
> 143             } catch (LifecycleException e) {
> 144             
> log.warn(sm.getString("standardService.mapperListener.stopFailed"), e);
> 145             }
> 146             try {
> 147                 mapperListener.start();
> 148             } catch (LifecycleException e) {
> 149            
> log.warn(sm.getString("standardService.mapperListener.startFailed"), e);
> 150             }
> 151             if (oldEngine != null) {
> 152                 try {
> 153                     oldEngine.stop();
> 154                 } catch (LifecycleException e) {
> 155                    
> log.warn(sm.getString("standardService.engine.stopFailed"), e);
> 156                 }
> 157             }
> 158         }
> 
> ============HostConfig.java===================
> full path: tomcat\java\org\apache\catalina\startup\HostConfig.java
> log line num: 1414
> 
> 1396         Context context = (Context) host.findChild(app.name);
> 1397         if (context.getState().isAvailable()) {
> 1398             if (fileToRemove != null && newDocBase != null) {
> 1399                 context.addLifecycleListener(
> 1400                         new
> ExpandedDirectoryRemovalListener(fileToRemove, newDocBase));
> 1401             }
> 1402             // Reload catches and logs exceptions
> 1403             context.reload();
> 1404         } else {
> 1405             // If the context was not started (for example an error
> 1406             // in web.xml) we'll still get to try to start
> 1407             if (fileToRemove != null && newDocBase != null) {
> 1408                 ExpandWar.delete(fileToRemove);
> 1409                 context.setDocBase(newDocBase);
> 1410             }
> 1411             try {
> 1412                 context.start();
> 1413             } catch (Exception e) {
> 1414                 log.warn(sm.getString
> 1415                          ("hostConfig.context.restart", app.name), e);
> 1416             }
> 1417         }
> 
> =============LifecycleBase.java=======================
> full path: tomcat\java\org\apache\catalina\util\LifecycleBase.java
> log line num: 296
> 
> 290         if (LifecycleState.FAILED.equals(state)) {
> 291             try {
> 292                 // Triggers clean-up
> 293                 stop();
> 294             } catch (LifecycleException e) {
> 295                 // Just log. Still want to destroy.
> 296                 log.warn(sm.getString(
> 297                         "lifecycleBase.destroyStopFail", toString()), e);
> 298             }
> 299         }

I present the details in Comment 4. Please ignore this comment.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to