Strabon

changeset 258:a4e7e9fc4d10

do not use e.getStackTrace() in log.error(), use just "e" as 2nd arg or append "e.getMessage()"
author Babis Nikolaou <charnik@di.uoa.gr>
date Wed Jun 06 13:14:15 2012 +0300 (2012-06-06)
parents ccd300595dc7
children e0f2f9edb017
files endpoint/src/main/java/eu/earthobservatory/org/StrabonEndpoint/QueryBean.java runtime/src/main/java/eu/earthobservatory/runtime/postgis/Strabon.java
line diff
     1.1 --- a/endpoint/src/main/java/eu/earthobservatory/org/StrabonEndpoint/QueryBean.java	Wed Jun 06 13:08:54 2012 +0300
     1.2 +++ b/endpoint/src/main/java/eu/earthobservatory/org/StrabonEndpoint/QueryBean.java	Wed Jun 06 13:14:15 2012 +0300
     1.3 @@ -266,7 +266,7 @@
     1.4  				//FileUtils.forceDeleteOnExit(new File((String) context.getRealPath("/") + "/../ROOT/tmp/" + temp + ".kml"));
     1.5  
     1.6  			} catch(IOException e) {
     1.7 -				logger.error("[StrabonEndpoint.QueryBean] " + e.getStackTrace());
     1.8 +				logger.error("[StrabonEndpoint.QueryBean] Error during querying.", e);
     1.9  			}
    1.10  
    1.11  			//response.setDateHeader("Expires", 0);			
     2.1 --- a/runtime/src/main/java/eu/earthobservatory/runtime/postgis/Strabon.java	Wed Jun 06 13:08:54 2012 +0300
     2.2 +++ b/runtime/src/main/java/eu/earthobservatory/runtime/postgis/Strabon.java	Wed Jun 06 13:14:15 2012 +0300
     2.3 @@ -47,10 +47,10 @@
     2.4  			st.close();
     2.5  			conn.close();
     2.6  		} catch (SQLException e) {
     2.7 -			logger.error("SQL Exception occured. Connection URL is <"+url+">.", e.getStackTrace());
     2.8 +			logger.error("[Strabon.checkAndDeleteLock] SQL Exception occured. Connection URL is <"+url+">: " + e.getMessage());
     2.9  			throw e;
    2.10  		} catch (ClassNotFoundException e) {
    2.11 -			logger.error("Could not load postgres jdbc driver.", e.getStackTrace());
    2.12 +			logger.error("[Strabon.checkAndDeleteLock] Could not load postgres jdbc driver: " + e.getMessage());
    2.13  			throw e;
    2.14  		}
    2.15  	}