Stefaan, Matthew,
I hate "works for me responses", so apologies in advance. However, we are
seeing artifacts automatically removed according to our repository
retention settings in our deployment and I wanted to share
possibly-relevant information.
We've been using Archiva version 2.2.3 in a docker container for over a
year now and haven't had any retention-related problems. Here are the parts
of our configuration that may be relevant.
1. We have dedicated "snapshots" and "releases" repositories. Only
snapshots are allowed in the "snapshots" repository, and only "releases" in
the releases repository.
2. In each repository we have retention policies, and each repository is
configured to be scanned.
3. The "repository-purge" consumer is enabled.
Also, FWIW, I'm pretty sure the code that applies the retention policy is
in the "repository-purge" consumer, and the out-most class for the feature
is found here:
https://github.com/apache/archiva/blob/9351c66bc89c65357ba72bb84982951919cbc0c4/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumer.java
Best,
Terence
On Fri, Oct 19, 2018 at 7:59 AM Matthew Broadhead
Post by Matthew Broadheadhttps://github.com/apache/archiva/blob/9351c66bc89c65357ba72bb84982951919cbc0c4/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/java/org/apache/archiva/scheduler/repository/ArchivaRepositoryScanningTaskExecutor.java#L181
seems that it hasn't been implemented?
Post by Matthew Broadheadyes i have activated the "repository-purge" consumer under Repository
scanning -> Consumers. maybe i also need to activate the
"validate-checksums" consumer as that is the only one not enabled
Cron Expression 0 0,30 * * * ?
Days Older 30
Retention Count 2
Delete Released Snapshots is checked
i was going to upgrade to 2.2.3 but if yours is not working either
then there is not much point
i wonder if there is any way to trigger it from the command line?
Post by Stefaan DutryAccording to my understanding it should be through the
repository-purge consumer. (This is located under Administration >
repository scanning > Consumers)
Then on the repository configuration itself there are settings like
"Delete Released Snapshots" and "retention count" and "days older"
Unfortunately the automatic purge isn't happening on our systems either.
(our version is 2.2.3)
http://archiva.apache.org/docs/2.2.0/adminguide/repositories.html
* delete released snapshots
* repository purge by days older
* repository purge by retention count
http://archiva.apache.org/docs/2.2.0/adminguide/consumers.html
* repository-purge
But this is what's specified in the link you provided
Regards,
Stefaan Dutry
Post by Jay VyasHey Matt: some of us are definetly here. Archiva saved me when I
couldnât pay for nexus so, Iâd definetly say there are a few others
in that boat. Ufortubately nobody has responded yet. Next step if
necessary would be filing a JIrA issue on the Apache organization
for archiva if nobody is able to help on the thread.
On Oct 19, 2018, at 4:51 AM, Matthew Broadhead
sorry to chase but is anyone still monitoring this list? are we
supposed to move to sonatype nexus oss? i thought apache created
maven?
Post by Matthew Broadheadi am using 2.2.0 and i have looked through all the settings but i
don't understand how to automatically delete old snapshots.
i followed this
https://stackoverflow.com/questions/12315461/how-to-configure-maven-or-apache-archiva-that-it-keeps-only-n-builds-of-an-snaps