The Hub Server runs as an implementation within the CORBA
ORB, managing incoming Node connections, and receiving commands
from leaves
Methods
|
|
|
|
__init__
|
__init__ (
self,
hub,
orb,
log,
debug,
verbose,
password,
)
|
|
checkIfAcceptingMsgs
|
checkIfAcceptingMsgs ( self, node_id )
|
|
connect
|
connect (
self,
node_ref,
username,
password,
hostname,
starttime,
platform,
version,
protocol,
)
(for messages FROM node TO hub)
Exceptions
|
|
Collaboratory_CORBA.AlreadyConnected, "User: %s@%s rejected (already logged in)\n" %( username, hostname )
Collaboratory_CORBA.BadPassword, "User: %s@%s rejected (bad password!)\n" %( username, hostname )
Collaboratory_CORBA.DoNotDisturb, "Not accepting new participants!"
Collaboratory_CORBA.InvalidProtocol, "Invalid protocol version: Hub %d, Node %d" %( Common.COLLABORATORY_PROTOCOL_VERSION, protocol )
|
|
|
disconnect
|
disconnect ( self, id )
disconnect() gets called when a user is disconnected (network goes down or they click "disconnect")
|
|
get_state
|
get_state ( self )
|
|
list_users
|
list_users ( self )
|
|
query_state
|
query_state ( self )
|
|
receive_messages_from_node
|
receive_messages_from_node (
self,
node_id,
messages,
)
Receive a command FROM the node and send it to the other leaves
|
|
request_ids
|
request_ids ( self, num_ids )
|
|
send_messages_to_nodes
|
send_messages_to_nodes (
self,
node_id,
messages,
)
|
|
updateNodeState
|
updateNodeState ( self, id )
|
|