Auditing (was Re: usage of InventoryStatus.DELETED )

Heiko W.Rupp hrupp at redhat.com
Tue Mar 15 08:58:12 UTC 2011


Am 14.03.2011 um 22:09 schrieb Jay Shaughnessy:
> And specifically to this case, I don't think we should complicate the 
> code bending over backwards to keep some nominally important audit.  I 
> do think the simple addition of a global audit table would be useful 
> going forward and could relieve us of some pain points.

Auditing could be as easy as sending a "log event" (*) to the
audit subsystem from what ever subsystem that has to report
something important. The audit subsystem would then append
this to a table. 
Table contents could be displayed in one RHQ page (with pagination)
and old entries would be purged after some time. If a longer audit
is needed, external scripts need to copy the audit log to a secondary
medium (we could provide a hook just before deletion to trigger 
such a script).

The Log event (and thus the table) format would (at least) contain:

- timestamp
- user triggering the event (string)
- subsystem sending the event
- subsystem specific data (e.g. resource id)
- message describing the event


Sending the event from the subsystem should be done
asynchronous (e.g. via JMS) and within its own transaction
so that the rollback of the original Tx does not roll back
the audit event.

Implementing this should not be too hard. Actually
this could be a great community job, as it does for the
start not require to hack in existing subsystems, but 
would allow to build in parallel and then gradually
extend the log event sending into the existing subsystems.

  Heiko




More information about the rhq-devel mailing list