Make it possible to limit the size of artifacts in a repository
Improved the error message.
@@ -133,7 +133,9 @@ public class ArtifactOperationsValidator
if (artifactMaxSize > 0 && uploadedFile.getSize() > artifactMaxSize)
{
- throw new ArtifactResolutionException("The size of the artifact exceeds the maximum size accepted by this repository (${size}/${artifactMaxSize}).");
+ throw new ArtifactResolutionException("The size of the artifact exceeds the maximum size accepted by "+
+ "this repository (" + uploadedFile.getSize() + "/" +
+ artifactMaxSize + ").");
}
}
