mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
prevent full feed fetching next time we fetch it if caching header values changed but content did not (#1037)
This commit is contained in:
@@ -182,11 +182,28 @@ public class HttpGetter {
|
||||
System.out.println(new String(result.content));
|
||||
}
|
||||
|
||||
@Getter
|
||||
public static class NotModifiedException extends Exception {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* if the value of this header changed, this is its new value
|
||||
*/
|
||||
private String newLastModifiedHeader;
|
||||
|
||||
/**
|
||||
* if the value of this header changed, this is its new value
|
||||
*/
|
||||
private String newEtagHeader;
|
||||
|
||||
public NotModifiedException(String message) {
|
||||
this(message, null, null);
|
||||
}
|
||||
|
||||
public NotModifiedException(String message, String newLastModifiedHeader, String newEtagHeader) {
|
||||
super(message);
|
||||
this.newLastModifiedHeader = newLastModifiedHeader;
|
||||
this.newEtagHeader = newEtagHeader;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user