Need to add logs for, While Create New Users and Adding them to Groups in Hippo CMS


#1

Hello Guys,

We have a requirement, at the time of Creating, Assigning them to any Groups we need to log those details for internal tracking purpose…
Kindly could you please help me out, how i can do this.

I am new to Hippo…

thanks in Advance


#2

These things are logged in the audit log (found in tomcat logs) and also in the repository in the hippo:log. If you need this data from the hippo:log you should write something to search and collate because there is more logged here and it isn’t ordered to be nice to humans.


#3

Hello Jasper,
Thanks for your reply.

I could’t see in audit logs of my local Hippo cms.
Could you please let me know if i need to add any configuration stuff for that …

Could you please guide me way to read/search hippo.log …

Regards
Ganesh


#4

This should be available by default. It’s called hippo-audit.log pre 13, or just audit.log in 13.

logging will look like:

30.01.2019 10:34:50 INFO  pool-3-thread-1 [AuditLogger.logHippoEvent:45] {"application":"cms","action":"create-user","category":"user-management","message":"created user ab","user":"admin","timestamp":1548840890027}
30.01.2019 10:35:20 INFO  pool-3-thread-1 [AuditLogger.logHippoEvent:45] {"application":"cms","action":"add-user-to-group","category":"group-management","message":"added user ab to group admin","user":"admin","timestamp":1548840920734}

#5

Hello Jasper,

Thanks for quick reply…
we are using Hippo 12.5


#6

You can find the audit log in your tomcat logs folder. If you are running with cargo this will be in
target/tomcat8x/logs/hippo-audit.log

On a server it depends on your setup, but likely still in tomcat/logs. Unless you made changes to logging configuration this is how it works.

You can also find this in the repository. In the console you will see a node hippo:log. Logging is also in here. You can use the repository servlet to query information. Or you can write a groovy script. Or you can write a custom report:

The information is all there for you.

Note that event log in the repository is (should be) regularly “cleaned”. This is enabled by default.

Your tomcat logs are cleaned according to whatever schedule you set on your servers.


#7

Hello Jasper,

I got it, thanks your time and I really appreciate your timely reply.