In this day and age where Drupal 8 is all the rage and while contemplating an end-of-life Drupal 6 Ubercart Store upgrade to Drupal 7 or 8, I wondered if Ubercart was still a relevant alternative? Because if it was, then Ubercart 6.x store owners wishing to upgrade would not have just one but two options to choose from, two chances to find the right fit.
My initial thought was, let's go with the flow and migrate to Drupal Commerce. The main reason behind my sheepish logic: Commerce is the de facto go-to e-commerce platform.
Then, another side of me argued that Commerce's dominance is somewhat artificial and really stems from the fact that commerce-talk dominates the techno buzz channels, grabbing most of the spotlight and in so doing is casting other potential solutions in the gloomy shadows of quasi-oblivion...
In this article, I will share my experience about a recent project for a small town hockey association which, for the past 5 years, has been relying on a Drupal 6 Ubercart 2.x website to automate seasonal registrations for its 350 hockey players. With Drupal 6 now defunct (EOL) and no security team* to provide the required assurance that credit card transactions would be safe, there was little choice but to upgrade at least to Drupal 7 before registration could start.
* It is a fact that Drupal's own security team is no longer watching over Drupal 6 core and modules. That's the way it is in Drupal land: only the two latest versions of the software are supported. I.e. Drupal 8 and Drupal 7 at the time of writing of this article. But lately, vendors have emerged and are now selling maintenance plans that extend this security watch for Drupal 6. So if you don't want or can't afford to upgrade, perhaps you should subscribe to this kind of intermediate plan ( see the Drupal 6 Long Term Support project page). Note though that common sense dictates that you will want to upgrade sooner or later.
I had a few Commerce projects under my belt, so Commerce felt more comfortable. By comparison, my initial experience with Ubercart was dating back to early 2010. Since the release of Drupal 7, I had done very little Ubercart development i.e. I had spent most of my Ubercart time on maintenance. More importantly, I had zero experience with the Drupal 7 version of Ubercart. I honestly didn't think much of it.
So on the one hand, migrating to Commerce seemed like the right thing to do. But as I often like to say, Commerce is a Drupal within Drupal: no matter how you slice it, the learning curve remains pretty steep. Although it's deceptively easy to reach the 80% mark of one's requirements with the Commerce Kickstart distribution, dealing with the last 20% (customizations) can be enormously time consuming if you're new to Commerce. As always, the devil is in the details.
On the other hand, because Ubercart is built with a shrink-wrapped approach (not so for Commerce which is more like Lego without the nifty illustrated how-to), it could conceivably be easier to go the Ubercart way. At least that's what I thought; or was it what I was hoping for considering that registrations were due to start in just two weeks time?
In the end, I knew there were risks on both sides of the fence. What I needed to do was to somehow figure out how big these risks were and how much time they could potentially cost me. After searching and reading some more about Ubercart migrations, I came to the uncomfortable conclusion that Ubercart, although riskier, represented the shortest route to a successful upgrade, riskier because of the unknown surrounding the upgrade process.It cannot always be crystal clear, right? Sometimes, you just have to try and see, follow your instincts and hope for the best. Worst case scenario, I figured I could rewind and start over with plan B.
One question remained: Drupal 7 or Drupal 8 ? Seeing that what mattered most to the project was a short timeline to delivery and keeping costs down without compromising the end result, considering also that at the time, Ubercart 8.x was still in alpha and Drupal 8 was just a little over six months old, Drupal 7 was the obvious answer.
OK, so Drupal 7 + Ubercart 3.x
Where do I start ? How do I upgrade from Drupal 6 to Drupal 7 ? How do I upgrade from Ubercart 2.x to 3.x ?
For me, the common answer to the first two questions has been the Drupal-to-Drupal data migration module (aka Migrate d2d) which requires a D7 installation with all the replicated content types and fields to capture the incoming data from the D6 database. So I set out to do just that and decided I would first try to migrate the products.
24 hours later
Gotcha! "Ubercart does not work with the migrate module" writes one of the Ubercart maintainers in the issue queue. I should have RTFM.
The choice of word makes a difference here - you don't migrate from Ubercart 6.x-2.x to 7.x-3.x, nope, you upgrade. In order to migrate (a possible but different process), you need 2 installations: a Drupal 6 and a Drupal 7. To upgrade, you only need the existing Drupal 6 code-base; well, a backup copy, just to be safe. And the way to do it is nicely spelled out with plenty of details in the UPGRADE.txt file which comes with every Drupal 7 installation. Yep, right there under our nose. But does it work? I have heard some nasty stories about this process.
This document describes how to:
- Update your Drupal site from one minor 7.x version to another minor 7.x version; for example, from 7.8 to 7.9, or from 7.6 to 7.10.
- Upgrade your Drupal site's major version from 6.x to 7.x.
Again, note the choice of words: update and upgrade have different meanings in drupal-speak. For the present use case, detailed instructions start halfway down UPGRADE.txt, under the heading: MAJOR VERSION UPGRADE.
Meticulously follow the 19 step process. At the end, you should be on the right track and on your way. That's not the end of your working day though, sorry. At this point you should have a basic working vanilla Drupal 7 though. I have to admit I was excited to have made it that far without too much trouble and too many errors even with the 253 pending updates that were required when I ran update.php.
From here on, one needs to replace all D6 modules with their D7 equivalent or successor. And since every website is different, upgrading your installation from D6 to D7 will have specific requirements, though generally speaking, the process is the same. But, if you properly performed step #7 of the Major version upgrade (i.e. disabling non-core modules and uninstalling modules you know you won't need or don't exist anymore in Drupal 7) you should be in pretty good shape.
Note that it is not really possible to upgrade your Drupal 6 theme per se. It will have to be converted or rebuilt or replaced by a new one.
Two weeks later
I can now say without the shadow of a doubt that Ubercart is still relevant, very much so in fact. Especially for existing Drupal 6 Ubercart websites that badly need to upgrade on a limited budget and a tight timeline.
The best advice I can give is GO SLOWLY and take your time, don't rush anything. Work with a backup of you site (that is obvious, right?) and make frequent backups during the upgrade process so you can revert if you need to. Be nice to your database, try to keep it as clean as possible. If not, you are more likely to run into issues later on - not fun.
Also, remember search engines are you best friends when you hit a snag (Google, DuckDuckGo, etc.). Start by typing "Drupal 7" and then just add the keywords that describe your specific need.
Summer is over
In the end, I was able to launch the hockey association's new Drupal 7 website in time for registrations and securely process credit card payments (PayPal Website Payment Pro). I'm really happy to report that it all went super well, beyond my expectations in fact. So kudos to the maintainers of Ubercart 7.x for the relatively smooth transition!
Last weekend, the whole town was out celebrating the end of summer with concerts, candy floss and hot dogs. During the festivities I met a few hockey parents on the streets and they told me that they really liked the website's new look (plain firebrick Bartik is perfect for a Red Wings town) and were pleasantly surprised that the new system recognized them, correctly displayed all their past information and that registration was a cinch.
While Ubercart is still an option, I'd posit that the default choice for any new site should be Drupal Commerce. Not only is Commerce (in my experience) a much more flexible platform to build on, it's also much more widely deployed. If you compare https://www.drupal.org/project/usage/commerce to https://www.drupal.org/project/usage/ubercart you'll find that Commerce has twice the users on Drupal 7, and is growing, while Ubercart is declining.
Drupal should be ashamed, how stupid it is not to have an easy way to upgrade.
I won't upgrade to useless drupal 7 to face the same problems when drupal 7 will reach EOL, because I do not trust anymore drupal which is just the perfect CMS to use if you want to have problems during major upgrades. RI-DI-CU-LOUS.
I understand your frustration. I've had my shares of downward spins with Drupal. But like I said, with a cool head and a proper method, upgrading from UC6 to UC7 is almost easy :-) Give yourself a breather and then start by reading UPGRADE.txt 3 to 5 times until you can visualize every step. Then start on a fresh backup of your D6, slowly, one step at a time. This is not a 100 meter race. It's more like a 10,000 meter race, so pace yourself. You can do it!