johnlemon
johnlemon

Reputation: 21449

Staging vs Testing server for PHP

What is the difference between a staging and testing server ?

Upvotes: 11

Views: 5053

Answers (4)

Abdullah Jobayer
Abdullah Jobayer

Reputation: 21

  • Dev: Development (Developer works)
  • Test: Testing (Tester/QA works)
  • Staging: User Acceptance Test/Load Test/Performance Test
  • Production: Live

Upvotes: 1

GordonM
GordonM

Reputation: 31730

A testing server will differ from the live environment in a number of ways. It may be configured to display a lot of error information with error_reporting set to report all or most errors and display_errors on. It will probably also have some kind of debugging module like XDebug installed.

The staging server is a machine that is configured to be much closer to the live environment. It will have display errors turned off and won't have any debugging modules installed.

The reason for doing this is that code has a nasty habit of working great on the test/development environment and then spectacularly failing to work when it goes live. If this happens when you deploy your code it can knock your website off line until you find and resolve the issue. The staging server is a way of trying to keep such disruptions to a minimum.

Upvotes: 4

Moses
Moses

Reputation: 9163

Testing (development) is the first server where you do all of the initial development for the site. Every change you make (and your archives) should all start in Testing.

Staging is a direct mirror of Live, and should simulate what the website will look like when you push everything live. Staging exists as a catch-all for any mistakes you might have made if you simply pushed your site Live from Testing. For example, moving from Testing to Staging will give you a clear indicator of whether or not you forgot to move something (like a stylesheet or image).

Upvotes: 0

Pascal MARTIN
Pascal MARTIN

Reputation: 400912

For me, a staging environment is one kind of testing environment.

The main point of the staging environment (servers, software and all) is that it's supposed to be quite close to the production environment :

  • same versions of software
  • same running daemons
  • same kind of physical servers
  • if using several servers in production, then have more than one server in staging -- to test load-balancing, for instance.
  • some real data (maybe a subset of your production data)

Basically, the staging environment should allow one to check if the application works in a production-like situation.


As for "testing" environments, I usually use this word for more than one kind of environments :

  • development machines : in a way, it's a testing platform, as developers have to unit-test their developments
  • automated-testing servers, with continuous integration
  • staging environment

Note that the first two environments will generally have more debugging /profiling / analysis tools that what you'll have on your production (and, so, staging) servers.

Upvotes: 22

Related Questions