On Thu, Nov 13, 2008 at 3:44 AM, James Abley <[EMAIL PROTECTED]> wrote:
> You're pulling down Atom feeds that have an html DOCTYPE? Are you sure > that they're valid Atom feeds? What does the feedvalidator [1] say? > > Cheers, > > James > > [1] http://www.feedvalidator.org/ Thanks, James. Your suggestion made me realize that the URL was incorrect. Now I have the correct Atom URL and I'm getting an error in the processing. Please see the code block and error below: for (int i = 0; i < uris.length; ++i) { String uri = (String) uris[i]; ClientResponse resp = client.get(uri); if (resp.getType() == ResponseType.SUCCESS) { Document<Feed> doc = resp.getDocument(); Feed feed = doc.getRoot(); // error occurs here LOG.info(feed.getTitle()); for (Entry entry : feed.getEntries()) { LOG.info("\t" + entry.getTitle()); } } else { System.out.println("Failure"); } } Exception in thread "main" java.lang.ClassCastException: org.apache.abdera.parser.stax.FOMExtensibleElement at com.sonatype.feedeater.FeedEater.grabUris(FeedEater.java:53) at com.sonatype.feedeater.FeedEater.run(FeedEater.java:41) at com.sonatype.feedeater.FeedEater.main(FeedEater.java:34) This could very well be due to my lack of knowledge of Abdera and Atom feeds in general. Any suggestions are appreciated. Bruce -- perl -e 'print unpack("u30","D0G)[EMAIL PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*" );' Apache ActiveMQ - http://activemq.org/ Apache Camel - http://activemq.org/camel/ Apache ServiceMix - http://servicemix.org/ Blog: http://bruceblog.org/
