public interface NetworkInterfaceManagementMBean
Modifier and Type | Field and Description |
---|---|
static String |
SIS_MANAGEMENT_TYPE |
Modifier and Type | Method and Description |
---|---|
ObjectName |
addDefaultRoute(String interfaceName)
Add a default route to the SIS.
|
ObjectName |
addRoute(String rule,
String interfaceName,
int position)
Add a new network route in the SIS.
|
ObjectName |
createNetworkInterfaceDefinition(String name,
Map<String,String> properties)
Create a new network interface definition in the SIS.
|
void |
disableNetworkInterface(String name)
Disable the network interface on this SIS instance.
|
void |
enableNetworkInterface(String name)
Enable the network interface on this SIS instance.
|
ObjectName |
getDefaultRoute()
Get the JMX Object Name for the default network route.
|
String[] |
getEnabledNetworkInterfaces()
Get the interfaces that are currently enabled on this SIS instance.
|
ObjectName |
getNetworkInterfaceDefinition(String name)
Get the JMX Object Name for a network interface definition.
|
String[] |
getNetworkInterfaceDefinitions()
Get the names of all network interfaces currently configured in the SIS.
|
ObjectName |
getRoute(int position)
Get the JMX Object Name for a network route.
|
TabularData |
getRoutes()
Get information about network routes in the SIS.
|
CompositeData |
getSupportedNetworkInterfaceProperties()
Get the network interface properties that are supported by this SIS instance.
|
void |
removeDefaultRoute()
Remove a default route from the SIS.
|
void |
removeNetworkInterfaceDefinition(String name)
Remove a network interface definition from the SIS.
|
void |
removeRoute(int position)
Remove an existing network route from the SIS.
|
static final String SIS_MANAGEMENT_TYPE
ObjectName createNetworkInterfaceDefinition(String name, Map<String,String> properties) throws NullPointerException, InvalidArgumentException, AlreadyDeployedException, InvalidConfigurationException, ManagementException
name
- a unique name for the interface.properties
- a map of property names and values.NetworkInterfaceDefinitionMBean
used to manage the network interface definition.NullPointerException
- if any argument is null
.InvalidArgumentException
- if unable to validate the interface properties.AlreadyDeployedException
- if an interface with the same name is already defined.InvalidConfigurationException
- if the SIS instance determines that the network
interface configuration is not valid.ManagementException
- if the interface could not be created due to a system-level failure.ObjectName getNetworkInterfaceDefinition(String name) throws NullPointerException, UnrecognizedComponentException, ManagementException
name
- the network interface name.NetworkInterfaceDefinitionMBean
used to manage the network interface definition.NullPointerException
- if name
is null
.UnrecognizedComponentException
- if the interface name is not known.ManagementException
- if the Object Name for the interface could not be obtained due to a system-level failure.void removeNetworkInterfaceDefinition(String name) throws NullPointerException, UnrecognizedComponentException, InvalidStateException, ManagementException
name
- the network interface name.NullPointerException
- if name
is null
.UnrecognizedComponentException
- if the interface name is not known.InvalidStateException
- if the interface cannot be removed because it is enabled on a SIS instance.ManagementException
- if the interface could not be removed due to a system-level failure.String[] getNetworkInterfaceDefinitions() throws ManagementException
ManagementException
- if the operation could not be completed due to a system-level failure.void enableNetworkInterface(String name) throws NullPointerException, UnrecognizedComponentException, InvalidStateException, ManagementException
When this method is called, the SIS will verify the interface's properties, and throw InvalidConfigurationException
if any properties are not valid.
The SIS does not necessarily begin using the interface immediately - it may be necessary to reactivate the SIS before it can use the interface. See the SIS implementation's documentation for more information.
name
- the network interface name.NullPointerException
- if name
is null
.UnrecognizedComponentException
- if the interface name is not known.InvalidStateException
- if the interface is already enabled on this SIS instance; or if it is enabled
on another SIS instance; or the SIS cannot enable the interface in its current state.ManagementException
- if the operation could not be completed due to a system-level failure.void disableNetworkInterface(String name) throws NullPointerException, UnrecognizedComponentException, InvalidStateException, ManagementException
name
- the network interface name.NullPointerException
- if name
is null
.UnrecognizedComponentException
- if the interface name is not known.InvalidStateException
- if the SIS cannot disable the interface in its current state.ManagementException
- if the operation could not be completed due to a system-level failure.String[] getEnabledNetworkInterfaces() throws ManagementException
ManagementException
- if the operation could not be completed due to a system-level failure.CompositeData getSupportedNetworkInterfaceProperties() throws ManagementException
This method returns a CompositeData type where each key is a supported property
name, and the corresponding value is a String
description of that property.
ManagementException
ObjectName addRoute(String rule, String interfaceName, int position) throws NullPointerException, InvalidArgumentException, UnrecognizedComponentException, AlreadyDeployedException, InvalidStateException, ManagementException
Rules are of the format "<type> [<value>]".
rule
- the rule to match for this route to be selected.interfaceName
- the name of the network interface to be used if this route is selected.position
- the list position to insert the route. A value less than or equal to zero
inserts the new route at the beginning of the list. A value greater than or equal to
the current number of routes adds the new route to the end of the list.NetworkRouteMBean
used to manage the network route.NullPointerException
- if rule
, or interfaceName
is null
.InvalidArgumentException
- if the rule is invalid.UnrecognizedComponentException
- if the interface name is not known.AlreadyDeployedException
- if an identical route already exists in the routing table.InvalidStateException
- if the specified network interface is not enabled on this SIS instance.ManagementException
- if the operation could not be completed due to a system-level failure.ObjectName getRoute(int position) throws UnrecognizedComponentException, ManagementException
position
- the route list position to get.NetworkRouteMBean
used to manage the network route.UnrecognizedComponentException
- if a route does not exist in the specified position.ManagementException
- if the Object Name for the route could not be obtained due to a system-level failure.void removeRoute(int position) throws InvalidArgumentException, ManagementException
position
- the route list position to remove.InvalidArgumentException
- if an invalid position is specified.ManagementException
- if the operation could not be completed due to a system-level failure.ObjectName addDefaultRoute(String interfaceName) throws NullPointerException, UnrecognizedComponentException, AlreadyDeployedException, InvalidStateException, ManagementException
interfaceName
- the name of the network interface to be used for the default route.NullPointerException
- if either argument is null
.UnrecognizedComponentException
- if the interface name is not known.AlreadyDeployedException
- if a default route has already been specified for the network
interface type.InvalidStateException
- if the specified network interface is not enabled on this SIS instance.ManagementException
- if the operation could not be completed due to a system-level failure.ObjectName getDefaultRoute() throws UnrecognizedComponentException, ManagementException
NetworkRouteMBean
used to manage the network route.UnrecognizedComponentException
- if a default route does not exist.ManagementException
- if the Object Name for the route could not be obtained due to a system-level failure.void removeDefaultRoute() throws InvalidStateException, ManagementException
InvalidStateException
- if a default route has not been specified for the network
interface type.ManagementException
- if the operation could not be completed due to a system-level failure.TabularData getRoutes() throws ManagementException
This method returns TabularData with the following fields:
Field | Open Type | Description |
---|---|---|
position | Integer | The list position of the route. |
rule | String | The route rule. |
interface | String | The name of the network interface selected by this route. |
TabularData
object as described above.ManagementException
- if the operation could not be completed due to a system-level failure.