简体   繁体   中英

What is the best way to handle updates to an ecommerce website?

I have an e-commerce website (Magento) I will be publishing soon. My current setup consists of a development, staging, and production site each with their own database. Pushing from development to staging is easy but what about from staging to live where there's constantly new customers and orders being created? Do I go the Apple route and post a "Inventory being updated" message. Any insights?

Thanks

Update: I guess I wasn't clear enough on my actual question. For those of you managing larger e-commerce websites, do you bring the site down momentarily for updates or is there another method, common or otherwise, that I am overlooking?

Magento already has a Maintenance Mode should you need it. More discussion about it is here .

Generally all your changes will probably be custom modules, and each module has it's own version and set of applicable install/upgrade scripts. Whenever you increase the version number in a module's config.xml file Magento automatically finds and runs the corresponding upgrade script. If all your database changes are made via that script then you have nothing to worry about.
This is how I expect my staging-to-production sites to work and only very rarely do I need to make any other changes in the admin, exceptions are things like adjusting links in CMS content. I never copy data directly from the staging database.
More discussion about this is here .

Your idea is a pretty good one, providing the interactive bits of the site are disabled - if you are uploading code/modifying databases then you don't want to introduce new data in that time due to the errors you might get.

Another way would be to schedule a cron job (or simply wait till 12AM and do it manually) to upload/change all the things you want uploaded/changed.

I can't really think of anything else right now - does magento have a way of disabling-while-updating?

Thanks,

James

In this case you should have upgrade plan in what times and dates the upgrades are allowed and during the update/upgrade maintenance mode should be on with correct http headers 503 Service Unavailable so search spiders/bots would understand the situation is temporary.

the way you display the maintenance mode is up to you. I'd suggest a rewrite rule to redirect all requests that are not from developers ip's to be redirected to maintenance page. So you still could use and perform the upgrades or setting changes yourself while others see the maintenance page

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM