ranger-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mad...@apache.org
Subject git commit: ARGUS-56: When DB audit log is configured for asynchronous, events are not flushed to DB until batch-size number of events (100 by default) are logged.
Date Mon, 15 Sep 2014 20:40:41 GMT
Repository: incubator-argus
Updated Branches:
  refs/heads/master bf6402e3a -> 6fdad49d1


ARGUS-56: When DB audit log is configured for asynchronous, events are
not flushed to DB until batch-size number of events (100 by default) are
logged.

This condition is only for the first flush to DB. After the first
commit, asynchronous logger flushes to DB at the sooner of the following
conditions:
- batch-size number of events are logged
- max-flush-interval is reached


Project: http://git-wip-us.apache.org/repos/asf/incubator-argus/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-argus/commit/6fdad49d
Tree: http://git-wip-us.apache.org/repos/asf/incubator-argus/tree/6fdad49d
Diff: http://git-wip-us.apache.org/repos/asf/incubator-argus/diff/6fdad49d

Branch: refs/heads/master
Commit: 6fdad49d14470697b6156a01775f3f29960bc554
Parents: bf6402e
Author: mneethiraj <mneethiraj@hortonworks.com>
Authored: Mon Sep 15 13:20:02 2014 -0700
Committer: mneethiraj <mneethiraj@hortonworks.com>
Committed: Mon Sep 15 13:20:02 2014 -0700

----------------------------------------------------------------------
 .../src/main/java/com/xasecure/audit/provider/DbAuditProvider.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/6fdad49d/agents-audit/src/main/java/com/xasecure/audit/provider/DbAuditProvider.java
----------------------------------------------------------------------
diff --git a/agents-audit/src/main/java/com/xasecure/audit/provider/DbAuditProvider.java b/agents-audit/src/main/java/com/xasecure/audit/provider/DbAuditProvider.java
index 2106d0a..3add646 100644
--- a/agents-audit/src/main/java/com/xasecure/audit/provider/DbAuditProvider.java
+++ b/agents-audit/src/main/java/com/xasecure/audit/provider/DbAuditProvider.java
@@ -45,7 +45,7 @@ public class DbAuditProvider implements AuditProvider {
 	private DaoManager          daoManager;
 	
 	private int                 mCommitBatchSize  = 1;
-	private long                mLastCommitTime   = 0;
+	private long                mLastCommitTime   = System.currentTimeMillis();
 	private ArrayList<AuditEventBase> mUncommitted = new ArrayList<AuditEventBase>();
 	private Map<String, String> mDbProperties;
 


Mime
View raw message