com.wowza.wms.server
Interface IServer

All Known Implementing Classes:
Server

public interface IServer

IServer: public interface to Server object.


Method Summary
 void addServerListener(IServerNotify serverListener)
          Add server listener
 java.util.List getAdminInterfaceObjectList()
          Get the list of objects exposed through JMX interface
 com.wowza.util.RandomIdGenerator getClientIdGenerator()
          Get the client id generator for the server
 HostPort getCommandInterfaceHostPort()
          Get the definition of the command interface
 ConnectionCounter getConnectionCounter()
          Get the server connection counter.
 com.wowza.wms.client.ConnectionCounterSimple getConnectionCounter(int counterIndex)
          Get the server connection counter for a specific technology (see IVHost.COUNTER_*)
 int getCoreHandlerPoolSize()
          Get the handler core thread pool size.
 int getCoreTransportPoolSize()
          Get the transport core thread pool size.
 String getDateStarted()
          Get the date and time the server was started.
 java.util.Properties getDynamicLogProperties()
          Get the dynamic log properties defined at the server level in conf/log4j.properties
 ThreadPool getHandlerThreadPool()
          Get the server handler thread pool.
 IOPerformanceCounter getIoPerformanceCounter()
          Get the server performance counter.
 IOPerformanceCounter getIoPerformanceCounter(int counterIndex)
          Get the server performance counter for a specific technology (see IVHost.COUNTER_*)
 WMSProperties getProperties()
          Get server level properties collection
 ThreadPool getThreadPool()
          Get the server handler thread pool.
 String getTimeRunning()
          Get a formatted String of how long the server has been running.
 double getTimeRunningSeconds()
          Get time running in seconds
 ThreadPool getTransportThreadPool()
          Get the server transport thread pool.
 com.wowza.wms.transport.udp.UDPPortManager getUDPPortManager()
          Get the UDP port manager which manages the allocation of incoming UDP port binding to be sure there are not port conflicts
 com.wowza.wms.transport.udp.UDPPortSharingManager getUDPPortSharingManager()
          Get the UDP port sharing manager.
 String[] getUserAgents()
          Get a pipe "|" delimited list of user agents that the server recognizes as RTMPT client.
 String getVersion()
          Get server version number.
 VHostList getVHostList()
          Returns the interface to the VHostList for the server
 boolean isDynamicLogContextLoaded(String logContext)
          Returns true of the given dynamic log context is already loaded.
 boolean isSuspended()
          Is the server current suspended
 String readConfig(String sName)
          Method to read xml config file..
 void reloadVHostConfig()
          Reload the VHosts.xml file.
 void removeServerListener(IServerNotify serverListener)
          Remove server listener
 void setCommandInterfaceHostPort(HostPort commandInterfaceHostPort)
          Set the definition for the command interface.
 void setCoreHandlerPoolSize(int corePoolSize)
          Set the handler core thread pool size.
 void setCoreTransportPoolSize(int corePoolSize)
          Set the transport core thread pool size.
 void setDynamicLogProperties(java.util.Properties dynamicLogProperties)
          Set the dynamic log properties set at the server level
 void setUserAgents(String[] userAgents)
          Set a pipe "|" delimited list of user agents that the server recognizes as RTMPT client.
 void startCommandInterface()
          Start the command interface as defined in Server.xml.
 void startVHost(String vhostName)
          Start a vHost by name.
 void startVHosts()
          Start all vHosts
 void stopAdminAgent()
          Stop the JMX interface
 void stopCommandInterface()
          Stop the command interface as defined in Server.xml.
 void stopVHost(String vhostName)
          Stop a vHost by name.
 void stopVHosts()
          Stop all vHosts
 void suspendAllVHosts()
          Suspend all virtual hosts (Calls IVHost.suspendAllHostPorts for each vhost)
 void suspendServer()
          Suspend all virtual hosts and the command interface
 void unbindAllVHosts()
          Unbind all virtual hosts (Calls IVHost.unbindAllHostPorts for each vhost)
 boolean writeConfig(String sName, String data)
          Method to write xml config file..
 

Method Detail

addServerListener

void addServerListener(IServerNotify serverListener)
Add server listener

Parameters:
serverListener - server listener

getAdminInterfaceObjectList

java.util.List getAdminInterfaceObjectList()
Get the list of objects exposed through JMX interface

Returns:
list of objects exposed through JMX interface

getClientIdGenerator

com.wowza.util.RandomIdGenerator getClientIdGenerator()
Get the client id generator for the server

Returns:
client id generator for the server

getCommandInterfaceHostPort

HostPort getCommandInterfaceHostPort()
Get the definition of the command interface

Returns:
host port definition of command interface

getConnectionCounter

ConnectionCounter getConnectionCounter()
Get the server connection counter.

Returns:
connection counter

getConnectionCounter

com.wowza.wms.client.ConnectionCounterSimple getConnectionCounter(int counterIndex)
Get the server connection counter for a specific technology (see IVHost.COUNTER_*)

Parameters:
counterIndex - counter index (see IVHost.COUNTER_*)
Returns:
connection counter

getCoreHandlerPoolSize

int getCoreHandlerPoolSize()
Get the handler core thread pool size.

Returns:
default core thread pool size

getCoreTransportPoolSize

int getCoreTransportPoolSize()
Get the transport core thread pool size.

Returns:
default core thread pool size

getDateStarted

String getDateStarted()
Get the date and time the server was started.

Returns:
date and time the server was started

getDynamicLogProperties

java.util.Properties getDynamicLogProperties()
Get the dynamic log properties defined at the server level in conf/log4j.properties

Returns:
dynamic log properties defined at the server level

getHandlerThreadPool

ThreadPool getHandlerThreadPool()
Get the server handler thread pool. This thread pool is used to process the incoming events.

Returns:
server handler thread pool

getIoPerformanceCounter

IOPerformanceCounter getIoPerformanceCounter()
Get the server performance counter.

Returns:
io performance counter

getIoPerformanceCounter

IOPerformanceCounter getIoPerformanceCounter(int counterIndex)
Get the server performance counter for a specific technology (see IVHost.COUNTER_*)

Parameters:
counterIndex - counter index (see IVHost.COUNTER_*)
Returns:
io performance counter

getProperties

WMSProperties getProperties()
Get server level properties collection

Returns:
server level properties collection

getThreadPool

ThreadPool getThreadPool()
Get the server handler thread pool. Same as getHandlerThreadPool.

Returns:
server handler thread pool

getTimeRunning

String getTimeRunning()
Get a formatted String of how long the server has been running.

Returns:
formatted String of how long the server has been running

getTimeRunningSeconds

double getTimeRunningSeconds()
Get time running in seconds

Returns:
time running in seconds

getTransportThreadPool

ThreadPool getTransportThreadPool()
Get the server transport thread pool. This thread pool is used to read/write data from the transports sockets.

Returns:
server transport thread pool

getUDPPortManager

com.wowza.wms.transport.udp.UDPPortManager getUDPPortManager()
Get the UDP port manager which manages the allocation of incoming UDP port binding to be sure there are not port conflicts

Returns:
UDP port manager

getUDPPortSharingManager

com.wowza.wms.transport.udp.UDPPortSharingManager getUDPPortSharingManager()
Get the UDP port sharing manager.

Returns:
UDP port sharing manager

getUserAgents

String[] getUserAgents()
Get a pipe "|" delimited list of user agents that the server recognizes as RTMPT client.

Returns:
pipe "|" delimited list of user agents that the server recognizes as RTMPT client

getVersion

String getVersion()
Get server version number.

Returns:
server version number

getVHostList

VHostList getVHostList()
Returns the interface to the VHostList for the server

Returns:
vhostList

isDynamicLogContextLoaded

boolean isDynamicLogContextLoaded(String logContext)
Returns true of the given dynamic log context is already loaded. If not loaded it will return false and add it to the a Set of loaded log context. Log context is [VHost].[Application].[AppInstance]


isSuspended

boolean isSuspended()
Is the server current suspended


readConfig

String readConfig(String sName)
Method to read xml config file..


reloadVHostConfig

void reloadVHostConfig()
Reload the VHosts.xml file. This method can be invoked through the JMX interface to manage vHosts while the server is running.


removeServerListener

void removeServerListener(IServerNotify serverListener)
Remove server listener

Parameters:
serverListener - server listener

setCommandInterfaceHostPort

void setCommandInterfaceHostPort(HostPort commandInterfaceHostPort)
Set the definition for the command interface.

Parameters:
commandInterfaceHostPort - host port definition of command interface

setCoreHandlerPoolSize

void setCoreHandlerPoolSize(int corePoolSize)
Set the handler core thread pool size.

Parameters:
corePoolSize - core thread pool size

setCoreTransportPoolSize

void setCoreTransportPoolSize(int corePoolSize)
Set the transport core thread pool size.

Parameters:
corePoolSize - core thread pool size

setDynamicLogProperties

void setDynamicLogProperties(java.util.Properties dynamicLogProperties)
Set the dynamic log properties set at the server level

Parameters:
dynamicLogProperties - dynamic log properties defined at the server level

setUserAgents

void setUserAgents(String[] userAgents)
Set a pipe "|" delimited list of user agents that the server recognizes as RTMPT client.

Parameters:
userAgents - pipe "|" delimited list of user agents that the server recognizes as RTMPT client

startCommandInterface

void startCommandInterface()
Start the command interface as defined in Server.xml. The command interface is used by shutdown.sh script to stop the server. It is also used by ant task to stop and start the server on build events.


startVHost

void startVHost(String vhostName)
Start a vHost by name.

Parameters:
vhostName - vHost name

startVHosts

void startVHosts()
Start all vHosts


stopAdminAgent

void stopAdminAgent()
Stop the JMX interface


stopCommandInterface

void stopCommandInterface()
Stop the command interface as defined in Server.xml. The command interface is used by shutdown.sh script to stop the server. It is also used by ant task to stop and start the server on build events.


stopVHost

void stopVHost(String vhostName)
Stop a vHost by name.

Parameters:
vhostName - vHost name

stopVHosts

void stopVHosts()
Stop all vHosts


suspendAllVHosts

void suspendAllVHosts()
Suspend all virtual hosts (Calls IVHost.suspendAllHostPorts for each vhost)


suspendServer

void suspendServer()
Suspend all virtual hosts and the command interface


unbindAllVHosts

void unbindAllVHosts()
Unbind all virtual hosts (Calls IVHost.unbindAllHostPorts for each vhost)


writeConfig

boolean writeConfig(String sName,
                    String data)
Method to write xml config file..