Page Speed Optimization Libraries  1.13.35.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
net_instaweb::WorkBoundExpensiveOperationController Class Reference

#include "work_bound_expensive_operation_controller.h"

Inheritance diagram for net_instaweb::WorkBoundExpensiveOperationController:
net_instaweb::ExpensiveOperationController

Public Member Functions

 WorkBoundExpensiveOperationController (int max_expensive_operations, Statistics *stats)
 
virtual void ScheduleExpensiveOperation (Function *callback)
 ExpensiveOperationController interface.
 
virtual void NotifyExpensiveOperationComplete ()
 

Static Public Member Functions

static void InitStats (Statistics *stats)
 

Static Public Attributes

static const char kCurrentExpensiveOperations []
 

Detailed Description

Implements ExpensiveOperationController by using a statistic to limit multiple simultaneous expensive jobs. Named after now removed WorkBound class. This uses Statistics to communicate between multiple worker processes so does not have have the cross-process constraints of QueuedExpensiveOperationController. However, this implementation does not queue requests, instead observing the count of in-progress operations and canceling the request if that number is too great.

Member Function Documentation

virtual void net_instaweb::WorkBoundExpensiveOperationController::NotifyExpensiveOperationComplete ( )
virtual

Inform controller that the operation has been completed. Should only be called if Run() was invoked on callback above.

Implements net_instaweb::ExpensiveOperationController.


The documentation for this class was generated from the following file: