equilibrium-mgmt_conn.h File Reference

Relating to managing the connections. More...

Go to the source code of this file.

Functions

status_t init_server (evContext ctx)
void close_connections (void)
void mspic_offline (const char *name)
void process_notifications (void)
void notify_application_update (const char *svc_set_name, const char *app_name, in_addr_t address, uint16_t port, uint16_t session_timeout, uint16_t connection_interval, uint16_t connection_timeout, uint8_t timeouts_allowed, uint16_t down_retry_interval)
void notify_server_update (const char *svc_set_name, const char *app_name, in_addr_t address)
void notify_server_delete (const char *svc_set_name, const char *app_name, in_addr_t address)
void notify_application_delete (const char *svc_set_name, const char *app_name)
void notify_serviceset_delete (const char *svc_set_name, uint16_t svc_set_id)
void notify_delete_all_servers (const char *svc_set_name, const char *app_name)
void notify_delete_all_applications (const char *svc_set_name, uint16_t svc_set_id)
void notify_delete_all (void)


Detailed Description

Relating to managing the connections.

These functions and types will manage the connections.

Definition in file equilibrium-mgmt_conn.h.


Function Documentation

void close_connections ( void   ) 

Close existing connections and shutdown server

Definition at line 490 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, data_info, data_session, EQUILIBRIUM_PORT_NUM, notification_msg_s::message, mgmt_server, MSG_DELETE_ALL, and notification_msg_s::svc_set_name.

Referenced by equilibrium_init(), and equilibrium_shutdown().

status_t init_server ( evContext  ctx  ) 

Initialize the server socket connection

Parameters:
[in] ctx Newly created event context
Returns:
SUCCESS if successful; otherwise EFAIL with an error message.

Definition at line 452 of file equilibrium-mgmt_conn.c.

References data_info, data_session, eq_ctx, EQUILIBRIUM_MGMT_SERVER_MAX_CONN, EQUILIBRIUM_PORT_NUM, LOG, mgmt_server, receive_message(), and timer_id.

Referenced by equilibrium_init().

void mspic_offline ( const char *  name  ) 

Notification about an MS-PIC interface going down

Parameters:
[in] name name of interface that has gone down

Definition at line 534 of file equilibrium-mgmt_conn.c.

References data_info, and data_session.

Referenced by ifd_down_async_handler().

void notify_application_delete ( const char *  svc_set_name,
const char *  app_name 
)

Enqueue a message to go to the data component about an application deletion

Parameters:
[in] svc_set_name Service set name
[in] app_name Application name

Definition at line 746 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, update_app_info_s::app_name, server_info_s::app_name, del_app_info_s::app_name, del_app_info_s::app_name_len, notification_msg_s::message, notification_msg_s::message_len, MSG_CONF_APPLICATION, MSG_CONF_SERVER, MSG_DELETE_ALL_SERVERS, MSG_DELETE_APP, MSG_DELETE_SERVER, and notification_msg_s::svc_set_name.

Referenced by delete_application().

void notify_application_update ( const char *  svc_set_name,
const char *  app_name,
in_addr_t  address,
uint16_t  port,
uint16_t  session_timeout,
uint16_t  connection_interval,
uint16_t  connection_timeout,
uint8_t  timeouts_allowed,
uint16_t  down_retry_interval 
)

Enqueue a message to go to the data component about an application update

Parameters:
[in] svc_set_name Service set name
[in] app_name Application name
[in] address Application address
[in] port Application port
[in] session_timeout Application session timeout
[in] connection_interval Application server monitoring connection interval
[in] connection_timeout Application server monitoring connection timeout
[in] timeouts_allowed Application server monitoring connection timeouts allowed
[in] down_retry_interval Application server monitoring, down servers' retry connection interval

Definition at line 604 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, update_app_info_s::app_addr, update_app_info_s::app_name, update_app_info_s::app_name_len, update_app_info_s::app_port, update_app_info_s::connection_interval, update_app_info_s::connection_timeout, update_app_info_s::down_retry_interval, notification_msg_s::message, notification_msg_s::message_len, MSG_CONF_APPLICATION, update_app_info_s::session_timeout, notification_msg_s::svc_set_name, and update_app_info_s::timeouts_allowed.

Referenced by TAILQ_HEAD(), and update_application().

void notify_delete_all ( void   ) 

Enqueue a message to go to the data component about a deletion of all config

Definition at line 965 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, notification_msg_s::message, MSG_DELETE_ALL, and notification_msg_s::svc_set_name.

Referenced by delete_all_service_sets(), and TAILQ_HEAD().

void notify_delete_all_applications ( const char *  svc_set_name,
uint16_t  svc_set_id 
)

Enqueue a message to go to the data component about a deletion of all apps

Parameters:
[in] svc_set_name Service set name
[in] svc_set_id Service set ID (We need it now for deletions since it won't be available later)

Definition at line 937 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, notification_msg_s::message, notification_msg_s::message_len, MSG_DELETE_SS, del_svcset_info_s::svc_set_id, and notification_msg_s::svc_set_name.

Referenced by delete_all_applications().

void notify_delete_all_servers ( const char *  svc_set_name,
const char *  app_name 
)

Enqueue a message to go to the data component about a deletion of all servers

Parameters:
[in] svc_set_name Service set name
[in] app_name Application name

Definition at line 897 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, del_app_info_s::app_name, del_app_info_s::app_name_len, notification_msg_s::message, notification_msg_s::message_len, MSG_DELETE_ALL_SERVERS, and notification_msg_s::svc_set_name.

Referenced by delete_all_servers().

void notify_server_delete ( const char *  svc_set_name,
const char *  app_name,
in_addr_t  address 
)

Enqueue a message to go to the data component about a server deletion

Parameters:
[in] svc_set_name Service set name
[in] app_name Application name
[in] address Application server address

Definition at line 705 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, server_info_s::app_name, server_info_s::app_name_len, notification_msg_s::message, notification_msg_s::message_len, MSG_DELETE_SERVER, server_info_s::server_addr, and notification_msg_s::svc_set_name.

Referenced by delete_server().

void notify_server_update ( const char *  svc_set_name,
const char *  app_name,
in_addr_t  address 
)

Enqueue a message to go to the data component about a server update

Parameters:
[in] svc_set_name Service set name
[in] app_name Application name
[in] address Application server address

Definition at line 661 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, server_info_s::app_name, server_info_s::app_name_len, notification_msg_s::message, notification_msg_s::message_len, MSG_CONF_SERVER, server_info_s::server_addr, and notification_msg_s::svc_set_name.

Referenced by TAILQ_HEAD(), and update_server().

void notify_serviceset_delete ( const char *  svc_set_name,
uint16_t  svc_set_id 
)

Enqueue a message to go to the data component about a service set deletion

Parameters:
[in] svc_set_name Service set name
[in] svc_set_id Service set ID (We need it now for deletions since it won't be available later)

Definition at line 845 of file equilibrium-mgmt_conn.c.

References notification_msg_s::action, notification_msg_s::message, notification_msg_s::message_len, MSG_DELETE_SS, del_svcset_info_s::svc_set_id, and notification_msg_s::svc_set_name.

Referenced by delete_service_set().

void process_notifications ( void   ) 

Try to process all notification requests that have been buffered. This should be called when a configuration load is complete.

Definition at line 561 of file equilibrium-mgmt_conn.c.

References eq_ctx, LOG, process_notifications_messages(), RETRY_INTERVAL, and timer_id.

Referenced by equilibrium_config_read(), and TAILQ_HEAD().


2007-2009 Juniper Networks, Inc. All rights reserved. The information contained herein is confidential information of Juniper Networks, Inc., and may not be used, disclosed, distributed, modified, or copied without the prior written consent of Juniper Networks, Inc. in an express license. This information is subject to change by Juniper Networks, Inc. Juniper Networks, the Juniper Networks logo, and JUNOS are registered trademarks of Juniper Networks, Inc. in the United States and other countries. All other trademarks, service marks, registered trademarks, or registered service marks are the property of their respective owners.
Generated on Sun May 30 20:26:57 2010 for SDK Your Net Corporation Equilibrium Load Balancer Example: equilibrium-mgmt 1.0 by Doxygen 1.5.1