|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.archiva.policies.CachedFailuresPolicy
@Service(value="preDownloadPolicy#cache-failures") public class CachedFailuresPolicy
PreDownloadPolicy
to check if the requested url has failed before.
Field Summary | |
---|---|
private org.slf4j.Logger |
log
|
static String |
NO
The NO policy setting means that the the existence of old failures is not checked. |
private List<String> |
options
|
private UrlFailureCache |
urlFailureCache
|
static String |
YES
The YES policy setting means that the existence of old failures is checked, and will prevent the request from being performed against the remote repo. |
Constructor Summary | |
---|---|
CachedFailuresPolicy()
|
Method Summary | |
---|---|
void |
applyPolicy(String policySetting,
Properties request,
File localFile)
Apply the download policy. |
String |
getDefaultOption()
Get the default option for this policy. |
String |
getId()
Get the id for this policy. |
String |
getName()
Get the display name for this policy. |
List<String> |
getOptions()
Get the list of options for this policy. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private org.slf4j.Logger log
public static final String NO
public static final String YES
@Inject private UrlFailureCache urlFailureCache
private List<String> options
Constructor Detail |
---|
public CachedFailuresPolicy()
Method Detail |
---|
public void applyPolicy(String policySetting, Properties request, File localFile) throws PolicyViolationException, PolicyConfigurationException
DownloadPolicy
applyPolicy
in interface DownloadPolicy
policySetting
- the policy setting.request
- the list of request properties that the policy might use.
PolicyViolationException
- if the policy has been violated.
PolicyConfigurationException
public String getDefaultOption()
Policy
getDefaultOption
in interface Policy
public String getId()
Policy
getId
in interface Policy
public String getName()
Policy
getName
in interface Policy
public List<String> getOptions()
Policy
getOptions
in interface Policy
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |