Class JChannelFactory
- All Implemented Interfaces:
ChannelFactory
Channel
interface.
See JChannel for a discussion of channel properties.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDeprecated.Constructs aJChannelFactoryinstance that contains no protocol stack configuration.JChannelFactory(File properties) Deprecated.Constructs aJChannelFactoryinstance that utilizes the specified file for protocl stack configuration.JChannelFactory(String properties) Deprecated.Constructs aJChannelinstance with the protocol stack configuration based upon the specified properties parameter.JChannelFactory(URL properties) Deprecated.Constructs aJChannelFactoryinstance that utilizes the specified file for protocl stack configuration.JChannelFactory(Element properties) Deprecated.Constructs aJChannelFactoryinstance that utilizes the specified file for protocl stack configuration. -
Method Summary
Modifier and TypeMethodDescriptionvoidDeprecated.Removes all configurationsvoidcreate()Deprecated.Deprecated.Creates aJChannelimplementation of theChannelinterface using the protocol stack configuration information specfied during construction of an instance of this factory.createChannel(Object properties) Deprecated.JChannel's conversion to type-specific construction, and the subsequent deprecation of itsJChannel(Object)constructor, necessitate the deprecation of this factory method as well.createChannel(String stack_name) Deprecated.createMultiplexerChannel(String stack_name, String id) Deprecated.Use a shared transport instead of the multiplexercreateMultiplexerChannel(String stack_name, String id, boolean register_for_state_transfer, String substate_id) Deprecated.Use a shared transport instead of the multiplexervoiddestroy()Deprecated.Deprecated.Deprecated.Deprecated.Returns the stack configuration as a string (to be fed into new JChannel()).Deprecated.Deprecated.Use a shared transport instead of the multiplexerDeprecated.booleanhasMuxChannel(String stack_name, String id) Deprecated.Use a shared transport instead of the multiplexerbooleanDeprecated.booleanDeprecated.booleanremoveConfig(String stack_name) Deprecated.voidDeprecated.voidsetExposeChannels(boolean expose_channels) Deprecated.voidsetExposeProtocols(boolean expose_protocols) Deprecated.voidsetMultiplexerConfig(File file) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(File file, boolean replace) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(Object properties) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(Object properties, boolean replace) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(String properties) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(String properties, boolean replace) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(URL url) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(URL url, boolean replace) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(Element properties) Deprecated.Use a shared transport instead of the multiplexervoidsetMultiplexerConfig(Element properties, boolean replace) Deprecated.Use a shared transport instead of the multiplexervoidsetServer(MBeanServer server) Deprecated.voidstart()Deprecated.voidstop()Deprecated.
-
Constructor Details
-
JChannelFactory
public JChannelFactory()Deprecated.Constructs aJChannelFactoryinstance that contains no protocol stack configuration. -
JChannelFactory
Deprecated.Constructs aJChannelFactoryinstance that utilizes the specified file for protocl stack configuration.- Parameters:
properties- a file containing a JGroups XML protocol stack configuration.- Throws:
ChannelException- if problems occur during the interpretation of the protocol stack configuration.
-
JChannelFactory
Deprecated.Constructs aJChannelFactoryinstance that utilizes the specified file for protocl stack configuration.- Parameters:
properties- a XML element containing a JGroups XML protocol stack configuration.- Throws:
ChannelException- if problems occur during the interpretation of the protocol stack configuration.
-
JChannelFactory
Deprecated.Constructs aJChannelFactoryinstance that utilizes the specified file for protocl stack configuration.- Parameters:
properties- a URL pointing to a JGroups XML protocol stack configuration.- Throws:
ChannelException- if problems occur during the interpretation of the protocol stack configuration.
-
JChannelFactory
Deprecated.Constructs aJChannelinstance with the protocol stack configuration based upon the specified properties parameter.- Parameters:
properties- an old style property string, a string representing a system resource containing a JGroups XML configuration, a string representing a URL pointing to a JGroups XML XML configuration, or a string representing a file name that contains a JGroups XML configuration.- Throws:
ChannelException- if problems occur during the interpretation of the protocol stack configuration.
-
-
Method Details
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexerDescription copied from interface:ChannelFactoryInitializes the factory.- Specified by:
setMultiplexerConfigin interfaceChannelFactory- Parameters:
properties-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Parameters:
properties-replace-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexerDescription copied from interface:ChannelFactoryInitializes the factory from a file. Example: conf/stacks.xml- Specified by:
setMultiplexerConfigin interfaceChannelFactory- Parameters:
file-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Parameters:
file-replace-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Specified by:
setMultiplexerConfigin interfaceChannelFactory- Parameters:
properties-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Parameters:
properties-replace-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Specified by:
setMultiplexerConfigin interfaceChannelFactory- Parameters:
url-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Parameters:
url-replace-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Specified by:
setMultiplexerConfigin interfaceChannelFactory- Parameters:
properties-- Throws:
Exception
-
setMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Parameters:
properties-replace-- Throws:
Exception
-
getConfig
Deprecated.Returns the stack configuration as a string (to be fed into new JChannel()). Throws an exception if the stack_name is not found. One of the setMultiplexerConfig() methods had to be called beforehand- Returns:
- The protocol stack config as a plain string
- Throws:
Exception
-
getMultiplexerConfig
Deprecated.Use a shared transport instead of the multiplexer- Returns:
- Returns all configurations
-
clearConfigurations
public void clearConfigurations()Deprecated.Removes all configurations -
removeConfig
Deprecated. -
getServer
Deprecated. -
setServer
Deprecated. -
getDomain
Deprecated. -
setDomain
Deprecated. -
isExposeChannels
public boolean isExposeChannels()Deprecated. -
setExposeChannels
public void setExposeChannels(boolean expose_channels) Deprecated. -
isExposeProtocols
public boolean isExposeProtocols()Deprecated. -
setExposeProtocols
public void setExposeProtocols(boolean expose_protocols) Deprecated. -
createChannel
Deprecated.JChannel's conversion to type-specific construction, and the subsequent deprecation of itsJChannel(Object)constructor, necessitate the deprecation of this factory method as well. Type-specific protocol stack configuration should be specfied during construction of an instance of this factory.Creates aJChannelimplementation of theChannelinterface.- Specified by:
createChannelin interfaceChannelFactory- Parameters:
properties- the protocol stack configuration information; anullvalue means use the default protocol stack configuration.- Throws:
ChannelException- if the creation of the channel failed.
-
createChannel
Deprecated.Creates aJChannelimplementation of theChannelinterface using the protocol stack configuration information specfied during construction of an instance of this factory.- Specified by:
createChannelin interfaceChannelFactory- Throws:
ChannelException- if the creation of the channel failed.
-
createChannel
Deprecated.- Specified by:
createChannelin interfaceChannelFactory- Throws:
Exception
-
createMultiplexerChannel
Deprecated.Use a shared transport instead of the multiplexerDescription copied from interface:ChannelFactoryCreates an implementation of the Channel using a given stack name and registering it under a given identity.Channel has to be created with a unique application id per stack name.
Provided stack name has to be one of the stacks defined in a property file that was passed to setMultiplexerConfig (e.g conf/stacks.xml). If clients attempt to create a Channel for an undefined stack name or they attempt to register a duplicate Channel per stack an Exception will be thrown.
- Specified by:
createMultiplexerChannelin interfaceChannelFactory- Parameters:
stack_name-id-- Returns:
- Throws:
Exception- See Also:
-
createMultiplexerChannel
public Channel createMultiplexerChannel(String stack_name, String id, boolean register_for_state_transfer, String substate_id) throws Exception Deprecated.Use a shared transport instead of the multiplexerDescription copied from interface:ChannelFactoryCreates an implementation of the Channel using a given stack name and registering it under a given identity.Channel has to be created with a unique application id per stack name.
Provided stack name has to be one of the stacks defined in a property file that was passed to setMultiplexerConfig (e.g conf/stacks.xml). If clients attempt to create a Channel for an undefined stack name or they attempt to register a duplicate Channel per stack an Exception will be thrown.
Rather than having each multiplexed channel do a separate state transfer clients can bundle state transfers for all channels created with the same ChannelFactory. First of all, clients have to create Channels with register_for_state_transfer set to true. After the last Channel that was created with register_for_state_transfer set to true connects and initiates state transfer the actual state transfer for all such channels from this ChannelFactory is executed.
Using bundled state transfers is especially useful with the FLUSH protocol in a stack. Recall that each state transfer triggers a flush and thus instead of doing a separate flush for each Channel created with this ChannelFactory we execute only one flush for all state transfers.
However, be aware of the implication of asynchronous nature of bundled state transfer with the respect of channel connect. Recall that each Channel after it returns from successful getState method can assume that state is available. In case of bundled state transfer, state will be set only after the last Channel registered for the bundled state transfer connects and executes getState.
- Specified by:
createMultiplexerChannelin interfaceChannelFactory- Parameters:
stack_name-id-register_for_state_transfer-substate_id-- Returns:
- Throws:
Exception- See Also:
-
hasMuxChannel
Deprecated.Use a shared transport instead of the multiplexerReturns true if this factory has already registered MuxChannel with given stack_name and an id, false otherwise.- Parameters:
stack_name- name of the stack usedid- service id- Returns:
- true if such MuxChannel exists, false otherwise
-
create
Deprecated.- Throws:
Exception
-
start
Deprecated.- Throws:
Exception
-
stop
public void stop()Deprecated. -
destroy
public void destroy()Deprecated. -
dumpConfiguration
Deprecated. -
dumpChannels
Deprecated.
-