src/csip/Config.java
@@ -213,7 +213,7 @@ |
|
/* |
Number of timeouts before giving up on trying to write to accesslog |
- If this number of reached no further attempt is made. |
+ If this number is reached no further attempt is made. |
*/ |
put("csip.accesslog.postgres.retry", "10"); |
|
@@ -1103,7 +1103,7 @@ |
|
SessionLogger l = new SessionLogger(null, "PostgresAccessLog", ""); |
DateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS"); |
- int timeout = getInt("csip.accesslog.postgres.timeout", 2); |
+ int timeout = getInt("csip.accesslog.postgres.timeout", 3); |
int retry = getInt("csip.accesslog.postgres.retry", 10); |
|
|
@@ -1127,6 +1127,7 @@ |
@Override |
public synchronized void log(String suid, String service_url, String req_ip, String node_ip, String req_time, String status, int duration) { |
if (retry == 0) { |
+ LOG.info("accesslog retry max reached."); |
return; |
} |
try (Connection c = Binaries.getConnection(jdbc_session_id, l)) { |
@@ -1142,6 +1143,7 @@ |
+ node_ip + "');"); |
} |
} catch (SQLTimeoutException to) { |
+ LOG.info("accesslog timeout " + to.getMessage()); |
retry--; |
} catch (SQLException | ServiceException ex) { |
l.log(Level.SEVERE, null, ex); |