Thousands of supporters thronged the stadiums to watch the T20 matches, perform Mexican waves, create a rippling electrifying atmosphere and shout out jingles to support their teams. But how many of us put on our thinking hats to ponder one point\u2014how do so many people get entry into stadiums to watch the riveting encounters?The BCCI (Board of Cricketing Control of India) had appointed Bookmyshow.com as their ticketing agency. We spoke to Viraj Patel, VP - technology, BookMyShow on how they went about controlling traffic on their app and site while selling tickets online.\u201cWe could foresee the demand and supply difference when it came to selling World Cup T20 tickets and we wanted to provide customers a seamless ticketing experience,\u201d says Patel.With more and more consumers transacting online in India, BookMyShow decided to sell tickets via a lucky draw system. \u00a0\u00a0It works on a randomized algorithm to pick up registrants randomly from the registration database. The parameters set for selection are the match and the category chosen\u2014naturally, users who have already won are eliminated. The lucky draw engine then starts picking up users registered for higher price value tickets and then moves to the lowest."We simulated about 5 million registrations to test our lucky draw system aggressively." \u2014Viraj Patel, VP - technology, BookMyShowThrough the lucky draw system, the company wanted to address the needs of two sets of customers\u2014those who actually want to make a transaction and buy tickets and those who only wanted information about the match schedule, the stands available and the ticket prices for a particular match. This model helped in dividing traffic coming from both sets of customers, ensuring that there was no overloading of servers.\u201cA platform such as ours faces a lot of load during any major activity. To ensure the app or site doesn\u2019t crash, we pre-empted the high load during World T20 and deployed a lucky draw system,\u201d says Patel.\u00a0Though there were few hurdles while implementing the project, some of the key challenges were handling millions of requests for lucky draw registration, restricting fake registration and eliminating repetition of users for the same match. The most crucial task was churning the registrations database and shortlisting winners within seconds. \u00a0However, to overcome the issue, \u201cwe included caching technologies and queuing system in our tech stack for the registration process, which helped us in handling millions of registrations,\u201d says Patel. OTP was made mandatory while registering and this eliminated fake registrations.At the same time, Patel says, \u201cwe also simulated equivalent registrations of about 5 million registrations in our database to test our lucky draw system aggressively.\u201dWith this, BookMyShow was able to sell tickets for all big world cup matches without technical glitches.What was the role of Patel in this project? He explains, \u201cMy major focus was on security and scalability. We knew that World T20 is an international event; not only will it attract a lot of customers but also face threats from hackers who want to break the system.\u201d To counter them, they hired White Hat hackers to hack into their systems to expose vulnerabilities.Highlighting his role in the project, he says, \u201cI had to define the complete architecture for the project. It was 100 percent in-house development, so the IT team at BookMyShow played a vital role in the development and testing of the lucky draw system.\u201dThrowing some light on the plans for the future, Patel said that, to give a fair chance to all users, they would like to use the lucky draw system for big events in the future.