Книга: Apache Solr Search Patterns
Назад: Summary
Дальше: Architecture of an ad distribution system

Chapter 7. Using Solr in an Advertising System

In this chapter, we will discuss in depth the problems faced during the implementation of Solr in an advertising system. An advertising system generates ads related to the content a user is currently viewing on his or her browser. These contextual ads need to be displayed quickly and need to be relevant for the user so that the user is prompted to click on them. We will look at Solr as a platform to provide solutions to the issues related to this aspect. We will delve into performance optimizations and then proceed with making Solr work with Redis. The topics that will be covered in this chapter are:

  • Ad system functionalities
  • Ad distribution system architecture
  • Ad distribution system requirements
  • Performance improvements
  • Merging Solr with Redis

Ad system functionalities

An ad system is based on the concept of provision of contextual ads (or documents in Solr terms) that are related to either the searched keyword or the document being viewed. Ads can also be generated or searched on the basis of the user's profile information and browsing history. The positioning and placement of an ad must match with the space available on the web page. On the basis of these functionalities, advertisements can be broadly divided into the following categories:

  • Ads based on keywords searched—referred to as a listing ad
  • Ads based on the placement and positioning available on the web page
  • Ads based on the user's browsing history and his or her profile—also known as user-targeted ads

To understand how an ad system works, we need to understand the functionalities it provides. On the back end or the admin side, the ad system should provide the following functionalities:

  • The definition of ad placement or the position where the ad would be able to fit on a web page, in terms of not only the size of the ad but also its visibility, say the top of the page or bottom right corner of the page.
  • Sales interface: This is an interface where all sales are recorded with respect to the client and payment or billing information.
  • Creative management: This is an interface to manage the creatives (images, flash files, or any content related to the ad) required to create an ad. It should also contain an approval mechanism for finalized creatives.
  • Reporting: This is a very broad topic and includes interfaces for reporting both the performance of the ad and the billing or usage statistics. It should contain and track statistics for CPM / CPC / CPA of the ads. For people who are new to the ad system, CPM stands for Cost Per Mile (1 mile = 1000 impressions). CPM is generally used for premium ads by premium publishers as ad publishers get paid for every impression. CPC stands for Cost Per Click, where the publisher gets paid only when the user clicks on the ad. CPA stands for Cost Per Aquision where the publisher gets paid only if the ad resulted in a sale.
  • Merchant tool: This is used by merchants to upload their requirements and track reports related to their ads as well as to check their billing information.
  • Campaign management: This is required to define a campaign. A campaign in an ad system generally refers to the ad or ads to be shown for a certain duration or with a capping of CPM, CPC, or CPA.
  • Budget: This can be used to place a cap on the bill generated with respect to a client or an inventory.
  • Bidding: This is generally used to compete for the visibility and placement of an ad. There are various algorithms available to calculate the value of an ad. Merchants can also use the merchant tool to increase the CPM, CPC, or CPA of an ad to increase its visibility.
  • Targeting media: This defines the keywords and URLs or category of websites where the ad would be displayed. For example, we can say that a particular ad should be displayed only on e-commerce websites.

In addition to the ad management system, we need an ad distribution system, which would display the ad based on the placement of ad, keyword matching to define the context of the ad. In addition, the ad distribution system needs to take care of the behavioral and demographic information related to the user.

The advertising system should also be capable of identifying the type of device on which the ad is to be displayed. It could be a laptop, mobile, or tablet. We could also build big-data analytics into the advertising system in order to identify behavioral patterns. The system should be able to connect to other affiliate networks.

Назад: Summary
Дальше: Architecture of an ad distribution system

Solr
Testing
dosare
121