Peer reviewed by @boonebgorges
NefisYemekTarifleri.com is the largest Turkish recipe sharing platform in the world. It has more than 290,000 recipes that reach millions of users every single day. NefisYemekTarifleri is a unique platform that uses WordPress and BuddyPress for all its applications — desktop, mobile web, Android, iOS, and AndroidTV.
- 290k+ recipes,
~500new recipes from different authors per day
~2.2M+registered users with
~2.6Mxprofile_data, 24M+ usermeta
~4Mnative apps download,
~100TBCDN BW usage per month
- 3M+ BuddyPress activities and
- 300k+ search requests per day
BuddyPress for a Growing User Base
NefisYemekTarifleri.com is turning 10 years old this August and has been using BuddyPress for the last 5 years. According to my boss, “BuddyPress has helped a lot to increase our user base.”
Our platform is community-driven, i.e., all the recipes come from our users. The membership and number of recipes submitted have increased dramatically since we started using BuddyPress. The users feel more welcome because they have their “own space” where they can easily add their avatars, cover images, post their recipes, and share other social media links. BuddyPress has enabled users to engage more with other registered members as well as invite new users to the site. Our editorial team spends a majority of their time editing user recipe submissions.
Customized BuddyPress Features
Our notification system is quite different from the standard BuddyPress notifications. It supports push and web push notifications and works async over the message queue.
There are a lot of activities which can trigger notifications. There were and are many instances when we send notifications to tens of thousands users every day. For example, when one author with thousands of “followers” publishes a new recipe, it took a long time to send a simple notification like, “Hi there! Jane Doe published a new recipe, take a look!” Consider when we have 10 authors with many followers publishing new recipes at the same time.
In the early days, we created a custom `nyt_bp_add_notification` script which called BuddyPress’ own notification that added a function for bulk messaging. We found out that it was causing lags on our slave MySQL servers because the impact on the disk IO was dramatic. Our solution was a new custom script, `nyt_bp_add_bulk_notification`, which inserts data directly to database (as a bulk SQL query). By the way, we highly recommend Percona’s PMM for catching performance hogs.
We decided to replace the built-in cover image feature and create our own Facebook-inspired UI which was more user-friendly. The feedback has been quite positive from our members.
Features of our new cover image UI:
- A user can directly upload a cover image by clicking on an icon on top of the cover image area.
- The full-size image is saved behind the scenes.
- Quick image resizing after the image upload has completed.
- A user can change image position via drag-drop.
- The full path and image coordinates are recorded as meta.
The Messaging component is active but not fully open for the end users. We will make this available for everyone when we’ve completed our mobile app integration. This is how we are setting this up for our site:
- All messages have to be between two people, we canceled group messaging.
- When someone you are not following sends a message, that message is marked as “pending”. You also “block” that person.
- Fluent messaging: all conversations between two people use the same thread.
Messaging, reimagined: We made some necessary changes a bit in a hacky way on the messaging component. Changing messaging behavior was not easy and there are some edge cases we have to monitor and address.
Limit notifications: Only allow 200 notifications per user, WordPress’ cron cleans up on a daily basis.
API Endpoints: We had to be careful on managing API endpoints, addressing the mobile apps a bit differently than web, especially when you do caching inside the device.
Long-running process: MQ workers are long-running PHP scripts and they caused memory problems on production after a while. We fixed this issue with stop_the_insanity.
In the Works
Following are some of the features we have in queue:
- Upgrading BuddyPress, of course
- Elasticsearch integration over ElasticPress. (We haven’t tried it yet but Pascal already wrote some code we can start playing with.)
- User suggestion to follow a member.
- Activity improvements (currently, just acting like feed).
- PHP 7.1 upgrade with dockerizing all the things. (Still using different versions of PHP)
BuddyPress allows us to build one of the largest niche communities in the world. Fortunately for everyone, BuddyPress is being maintained by developers who are active contributors to WordPress core. Our thanks to all BuddyPress contributors, especially the BP core team.
Links: Twitter, Github, WordPress.org, Linkedin, Instagram, My Blog, and nefisyemektarifleri