blob: 088e39ddff342d2faf21a1883e36e3963fe9b7b8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
// -*- C++ -*-
//=======================================================================
/**
* @file LB_Pull_Handler.h
*
* @author Ossama Othman <ossama@uci.edu>
*/
//=======================================================================
#ifndef TAO_LB_PULL_HANDLER_H
#define TAO_LB_PULL_HANDLER_H
#include /**/ "ace/pre.h"
#include "ace/config-all.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
#include "orbsvcs/LoadBalancing/LB_MonitorMap.h"
#include "ace/Event_Handler.h"
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
/// Forward declarations.
class TAO_LB_LoadManager;
/**
* @class TAO_LB_Pull_Handler
*
* @brief Event handler used when the "pull" monitoring style is
* configured.
*
* An event handler designed to pull loads from all load monitors
* registered with the load balancer.
*/
class TAO_LB_Pull_Handler : public ACE_Event_Handler
{
public:
/// Constructor
TAO_LB_Pull_Handler ();
/// Receive the timeout event.
virtual int handle_timeout (const ACE_Time_Value ¤t_time,
const void *arg);
/// Initialize this event handler.
void initialize (TAO_LB_MonitorMap * monitor_map,
TAO_LB_LoadManager * load_manager);
private:
/// The table that contains all load monitors registered with the
/// load balancer.
TAO_LB_MonitorMap * monitor_map_;
/// Pointer to the LoadManager servant.
TAO_LB_LoadManager * load_manager_;
};
TAO_END_VERSIONED_NAMESPACE_DECL
#include /**/ "ace/post.h"
#endif /* TAO_LB_PULL_HANDLER_H */
|