Possible to log component requests?

I setup proxy repo to route to internet repo, such as maven,npm etc.

I want to log all requests to the internet repo for audit purpose, is that possible?

Welcome to the Community Forum, Ricky!

For Repository Manager 3 you will want to change the logging level of the correct logger.

Log in to your instance and navigate to the Logging controls under the Support section in the admin view.

You want to ensure that the following logger is set to DEBUG:

Restart your instance and either use the LogViewer to retrieve the output, or look in <DATA-DIR>/log/nexus.log.

Whenever you download a component which is not currently cached in that repository, you will see a log entry similar to this one:

2020-01-10 17:09:24,330+0000 DEBUG [qtp1982288737-441] admin org.sonatype.nexus.httpclient.outbound - https://repo1.maven.org
/maven2/org.webjars.bower/swag/0.7.0/swag-0.7.0.jar > GET /maven2/org.webjars.bower/swag/0.7.0/swag-0.7.0.jar HTTP/1.1

1 Like