NY Post & Page Six 2020 Migrated sites from VIP Classic to VIP Go 2021 A/B tests and rollout of the 2021 NY Post redesign 2023 Launched the redesign of Page Six as a child theme
“monolith” architecture • Gutenberg block editor with custom blocks • WP VIPʼs mu-plugins have many performance tweaks to support enterprise usage • Persistent object cache - memcached • Reliable Cron System with Automatticʼs Cron Control plugin • CDN for images to deliver them quickly from servers close to the userʼs location • Robust Page Cache to serve up pre-built HTML to the majority of users.
integrations often hook in on admin actions. For example, when posts are saved or updated, using the wp_after_insert_post hook. • Scheduled cron jobs update data from external sources. • To optimize performance, API data is stored in the object cache, minimizing the need for repeated external requests • Rewrite rules are updated via a CLI command • Analytics, comments, and membership functionalities are powered by external third parties, leveraging JavaScript HTTP calls and scripts instead of backend calls to WordPress.
SearchPress Indexes content in Elasticsearch ES WP Query Offloads query to Elasticsearch https://github.com/alleyinteractive/searchpress https://github.com/alleyinteractive/es-wp-query ES_WP_Query
Elasticsearch to get the Post IDs Elasticsearch DSL Elasticsearch Cluster Post ID Post ID Post ID Post ID … Complex Query: Metro Snowstorm Posts with Video
Elasticsearch into a highly efficient post__in query to retrieve the full WP_Post objects from the database. es-wp-query/class-es-wp-query-shoehorn.php Post ID Post ID Post ID Post ID …
plugin prevents site downtime when external resources are unavailable. 2. Stress Reduction: Remote Backstop alleviates the load on a stressed resource by serving cached responses. 3. User Experience: End users are unaffected, unaware of any issues, due to the seamless fallback mechanism.
Get more posts than needed and exclude posts in PHP. • Solution 2 Disable Getting All Found Rows ◦ If Pagination isnʼt necessary, set 'no_found_rows' => true • Solution 3 Optimize Query Parameters ◦ 'ignore_sticky_posts' => true ◦ 'suppress_filters' => false • Solution 4 Offload to Elasticsearch and Cache Results • Solution 5 Avoid Unnecessary Queries ◦ Whenever possible, avoid running the query entirely. Sometimes, plugins add unnecessary functionality that can be disabled to improve performance.
foundation for building enterprise solutions that scale effectively. Weʼve relied on several key principles to achieve this scalability: • Leveraging Elasticsearch to enhance WP Query performance and offload complex queries. • Utilizing Object Cache to efficiently store data from queries and external APIs, reducing load times. • Adhering to the principle of ‘No Frontend Database Writes,ʼ ensuring data integrity and performance. • Identifying bottlenecks using tools like New Relic and Query Monitor to pinpoint and resolve performance issues. • Applying common solutions such as query optimizations and caching strategies to further boost efficiency.