private static String load(List<SyndEntry> entries, String url, String watermark, int limit) throws IOException, FeedException {
String lastWatermark = null;
SyndFeedInput feedInput = new SyndFeedInput();
SyndFeed feed = feedInput.build(new XmlReader(new URL(url)));
int max = limit > 0 ? Math.min(feed.getEntries().size(), limit) : feed.getEntries().size();
for (int i = 0; i < max; ++i) {
SyndEntry entry = (SyndEntry) feed.getEntries().get(i);