How to track when new projects are created and who they are created by

81 views
Skip to first unread message

David Shrum

unread,
Nov 8, 2019, 8:52:16 AM11/8/19
to Repo and Gerrit Discussion
We are using Gerrit 2.14.7 and would like to keep an audit trail as new projects are created.  For the newly created projects, we would also like to log who the projects are created by.  One option is that stream-events provides the project-created event that includes the project name.  Is there any other information available or information on who created the project?

Luca Milanesio

unread,
Nov 8, 2019, 9:06:32 AM11/8/19
to David Shrum, Luca Milanesio, Repo and Gerrit Discussion

On 8 Nov 2019, at 13:52, David Shrum <dshr...@gmail.com> wrote:

We are using Gerrit 2.14.7 and would like to keep an audit trail as new projects are created.  For the newly created projects, we would also like to log who the projects are created by.  One option is that stream-events provides the project-created event that includes the project name.  Is there any other information available or information on who created the project?

Why don't you use the audit plugin (see [1]) which is explicitly designed to capture and trace this type of information?

HTH

Luca.



--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/db869ddd-1af6-4ecd-8844-af125690e69e%40googlegroups.com.

Ray Pelkey

unread,
Nov 11, 2019, 2:38:23 PM11/11/19
to Repo and Gerrit Discussion
Hi Luca,  to further this a bit, David and are looking at this to see how we may be able to utilize.  Thanks for the suggestion.

It's installed in our test env. and we can see what is written to the error_log, so that's a start.

We'd like to set write audit events to a separate log file

The audit configuration can be defined in the main gerrit.config in a specific section dedicated to the audit-sl4j plugin.

gerrit.audit-sl4j.format : Output format of the audit record. Can be set to either JSON or CSV. By default, CSV.

gerrit.audit-sl4j.logName : Write audit to a separate log name under Gerrit logs directory. By default, audit records are put into the error_log.


at the moment not finding the right combination of entries in the gerrit.config that will enable audits to go to a dedicated file.

I'd have thought something like:
   [audit-sl4j]
           logName = audit_log

would do it, but it doesn't seem to.  also tried a few different combinations

   [auditsl4j]
           logName = audit_log


   [audit]
           logName = audit_log

no luck so far, all data still goes to the error_log

are you perhaps able to advise on this?

thanks in advance.
/Ray
On Friday, November 8, 2019 at 9:06:32 AM UTC-5, lucamilanesio wrote:


On 8 Nov 2019, at 13:52, David Shrum <dshr...@gmail.com> wrote:

We are using Gerrit 2.14.7 and would like to keep an audit trail as new projects are created.  For the newly created projects, we would also like to log who the projects are created by.  One option is that stream-events provides the project-created event that includes the project name.  Is there any other information available or information on who created the project?

Why don't you use the audit plugin (see [1]) which is explicitly designed to capture and trace this type of information?

HTH

Luca.



--
--
To unsubscribe, email rep...@googlegroups.com

More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-d...@googlegroups.com.

Ray Pelkey

unread,
Nov 11, 2019, 2:51:00 PM11/11/19
to Repo and Gerrit Discussion
oh I also found this:

[plugins "audit-sl4j"]
        logName = audit_log

from one of your other threads, but nothing changes.
Reply all
Reply to author
Forward
0 new messages