FeedIoBundle was the new rss-atom-bundle

Two years ago, I announced the future replacement of rss-atom-bundle in favor of FeedIoBundle. The goal was to get a cleaner code based on feed-io and new features like an user interface to handle feeds, without causing any trouble for rss-atom-bundle’s users. The result was not what I expected : forms made FeedIoBundle much harder to maintain than rss-atom-bundle and almost nobody adopted FeedIoBundle. Besides, rss-atom-bundle’s community is still growing, with some of these people opening new issues and even sometimes submitting pull requests. As a consequence, I drop FeedIoBundle in order to focus on rss-atom-bundle and feed-io.

This isn’t a problem for me to take this kind of decision. I tried something that didn’t work and now it’s just time to put an end to it. No matter how much time I spent on programming FeedIoBundle, it was worth the effort as I grabbed some knowledge thanks to this project.

So now the package will be tagged as “abandoned” on Packagist and all users are encouraged to use feed-io or rss-atom-bundle.

Advertisements

feed-io-bundle 3.0 to support Symfony 3.0

Edit : the bundle is no longer supported, see this announcement

I recently released version 3.0 of feed-io-bundle. Symfony 3.0 introduced a backward compatibility break in forms support, so it became impossible to maintain a code base compatible with both versions.

Symfony 2.x support

I created a branch called release/2.x to maintain feed-io-bundle version 2. It will last until the end of the Symfony 2.x official support. This branch will be used for bug fixes only, all the new features will be committed to the master branch.

feed-io-bundle v2.1.1 is out

Edit : the bundle is no longer supported, see this announcement

I recently released version 2.1.1 of feed-io-bundle. This is a major release as it introduces a web interface made to manage feeds and their content which you can try live here : http://feedio-demo.herokuapp.com/.

It’s also official : feed-io-bundle replaces rss-atom-bundle. If you’re starting a new Symfony project, I highly recommend you to use feed-io-bundle instead of rss-atom-bundle. feed-io-bundle will be upgraded regularly with new features and fixes among compatibility with Symfony.

Rss-atom-bundle’s support

rss-atom-bundle is not condemned to disappear immediately, I will provide a “passive support” until it’s not used anymore. By passive support, I mean taking care of open issues and pull requests until the end. So if you already have a project depending on rss-atom-bundle you don’t have to be afraid of this announcement, I’ll always be able to help.

Coming next

I’m working on two things by now :
– Symfony 3 compatibility
– the ability to analyse feed’s quality with feed-io

feed-io 1.0.0 : a PHP library built to serve and consume Atom/RSS feeds

feed-io has now finished its beta stage and is ready to be used in production environment. This library is 100 % pure PHP and depends only on PSR-2 for logging specifications. It also suggests Guzzle to consume external feeds, and if you don’t like this choice you’re free to write your own HTTP client and use it with feed-io.

features

Features are already listed in this previous post

To make it short, feed-io is able to serve and consume RSS / Atom news feeds with a strong OOP approach. It is flexible and you can use it to extend standard formats or to create your own if you need to.

design

feed-io is designed to be easily understood by anyone who wants to use it. It provides a façade to help you with the most common operations, but if you need more flexibility you can use the core classes.

FeedIo

This class is the facade, it provides methods to use feed-io’s main features.


$feedIo = new \FeedIo\FeedIo($client, $logger);

$result = $feedIo->read('https://debril.org/feed.atom');

echo 'feed title : ' . $result->getFeed()->getTitle() . PHP_EOL;

foreach( $result->getFeed() as $item ) {
    echo 'item title : ' . $item->getTitle() . PHP_EOL;
}

Result

This is the result of a read operation. It contains :

– the Feed instance
– Date and time of the request
– value of the ‘modifiedSince’ header sent throught the request
– the raw response
– the DOM document
– URL of the feed

So if you need to check something around the feed, it’s in the result.

StandardAbstract

Main standards are RSS, Atom and RDF and each of them are represented by a class extending StandardAbstract. A StandardAbstract instance is used for both parsing and formatting feeds using its RuleSet instances (one for the feed and one for the items).

So if you need to support a new format, it’s there. Just create a class extending StandardAbstract, implement the format’s specifications using the abstract methods and add it to feed-io. That’s it !

RuleSet and RuleAbstract

A RuleSet owns at least one rule (the default which is OptionalField). Each rule must be a RuleAbstract instance able to parse and format a DomElement according to its specifications. For instance, the Media class handles enclosure tags.

Each rule can be added to a ruleset instance at any time before parsing or formatting feeds.

FeedInterface

This interface defines the behaviour of a class containing the feed itself. It extends ArrayIterator and ItemInterface.

Feed

This is the FeedInterface implementation provided by feed-io. Feel free to extend it or to implement your own.

ItemInterface

Defines the behaviour of a class containing an item of the feed. It exposes methods to handle medias and  optional elements. It extends NodeInterface which is the lowest level of abstraction and exposes methods to get and set most common attributes like the title and the URL of an item.

Item

ItemInterface implementation provided by feed-io.

what’s coming next

Now that feed-io has been released in its first stable version, I will focus on FeedIoBundle to make it production ready before the end of June. So you can expect a first beta really soon.

FeedIoBundle is the new rss-atom-bundle

Edit : the bundle is no longer supported, see this announcement

I Recently forked rss-atom-bundle into a fresh new repository on GitHub. I said in my previous post that a 2.0 release of rss-atom-bundle will be released this year and will be maintained until the end of the 3.x branch of Symfony. Well, this is going to happen but rss-atom-bundle 2.x will be released under the name of FeedIoBundle in a different Git repository. And I built the new repository with the old one’s history, so yes this is a fork.

Motivations for the fork

The fork wasn’t mandatory but it is convenient for both users and developers. I decided to fork for the following reasons :

  • the bundle will not carry the core classes anymore. It will be a Bundle made to integrate feed-io’s features into a Symfony project.
  • 1.x branches and 2.x will be completely different, it’s already impossible to merge them.
  • the underlying library is called feed-io, it’s easier to understand FeedIoBundle is its Symfony dedicated bundle. Not the same for rss-atom-bundle.
  • interfaces are so different from each other that accidentally upgrading from 1.5 to 2.x would be a real mess for the user.
Compatibility and maintenance

FeedIoBundle will be compatible with Symfony 2.6 and above, including the 3.x branch. The compatibility board is now as follow :

  • rss-atom-bundle 1.4.x : Symfony < 2.6
  • rss-atom-bundle 1.5.x : Symfony < 3.x
  • FeedIoBundle 1.x : Symfony 2.6+ / 3.x ?

As you can see, FeedIoBundle will be compatible with 3.x and maybe with 2.6 depending on the framework’s evolution.

rss-atom-bundle is still supported until the end of Symfony 2 as I mentioned in the previous post.

Choice between rss-atom-bundle and FeedIoBundle

For now, FeedIoBundle is not stable enough to be used in a project. So if you are starting a new project with Symfony 2, use rss-atom-bundle. If your application is bound to Symfony 3, this is worth taking the risk to use FeedIoBundle as it may become stable before Symfony 3.

When FeedIoBundle will gain its first stable release, the choice will depend on your situation. For new applications, use FeedIoBundle. For existing projects, you may want to migrate from rss-atom-bundle if you need to upgrade to Symfony 3 or if you’re interested in new features provided by FeedIoBundle.

Choosing feed-io

You also can choose to use feed-io directly into your application whether it’s built with Symfony or another framework. I highly recommend this if you only need to consume external feeds or if the project is not a Symfony application.

feed-io is mature enough to be used in a production environment, meanwhile its documentation is not ready to show you how. This is one of the main steps remaining before the 1.0.0 release

What’s next

Most of the features of rss-atom-bundle will be supported by FeedIoBundle soon. Then, I will come across every issues opened in the first bundle to check if FeedIoBundle doesn’t regress.

The first release is to be expected before beginning of the summer.