سؤال

Each artifact uploaded to Maven Central has a last modified time associated with it. You can see an example of this by drilling into an artifact's details on search.maven.org.

How do I retrieve an artifact's last modified time using Aether?

I am retrieving this information purely for human consumption (i.e. "How long ago did this project make a release? Is it being actively maintained?").

هل كانت مفيدة؟

المحلول

One way to retrieve this information (though not officially supported) is to construct the Artifact's URI and issue an HTTP HEAD to retrieve the Last-Modified header.

I'm not aware of any official API to do this (suggestions welcome!)

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top