WMF Projects/Upgrade Payments Infrastructure

Feature justification
Current payment server is not scaling

User requirements
Be able to serve 100% of our banners with 1click donations at a 3% (best banner) + 2% (variance window)

Specification
Upgrade payments server with the following
 * APC
 * Squid
 * LVS
 * Memcache

Software design document
Our goal is to allow for Squid caching of the credit card gateway form and its variants to reduce server load. In order to support this, the software that supports the forms (DonationInterface/payflowpro_gateway extension) will require some rearchitecting.

At the moment, various data bits used for tracking, preventing CSRF, etc. are stored in hidden form fields in the credit card form. In order to prevent dynamic data from appearing in the form (making it uncacheable), we will store almost all of this data inside the user's session variable, which will be instantiated/populated by an AJAX call when the form loads. We will also use Javascript to inject a hidden form field with a token for CSRF-prevention, also retrieved via the AJAX call. In order to achieve this, we will build an API extension for DonationInterface/payflowpro_gateway.

Test plan
Use Apache Bench (ab) to determine page load times for the various forms under different load scenarios, with different scaling configurations, compare results to baseline (no LVS/squid/APC) results to determine efficacy.

User interface design docs
None needed yet

Schedule

 * 10/8 - Test APC
 * 10/15 - Test SQUID
 * 10/22 (or 10/29) - Test LVS+Memcache

Hardware Orders

 * Upgrade main payments box to 6core version RT #274

Community management plan
None needed