Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.runtime.config
Class NodeConfiguration

java.lang.Object
  extended by org.nuxeo.runtime.config.NodeConfiguration
All Implemented Interfaces:
Serializable, Cloneable

public class NodeConfiguration
extends Object
implements Serializable, Cloneable

Author:
Bogdan Stefanescu
See Also:
Serialized Form

Field Summary
static String AUTODETECT_PEERS
           
static String CLIENT_JNDI_PREFIX
           
static String IS_STREAMING_SERVER
           
static String NODE_ID
           
static String PEERS
           
static String PRODUCT_NAME
           
static String PRODUCT_VERSION
           
static String SERVER_ENABLED
           
static String SERVER_HOST
           
static String SERVER_LOCATOR
           
static String SERVER_PORT
           
static String SERVER_TYPE
           
static String STREAMING_LOCATOR
           
 
Constructor Summary
NodeConfiguration()
           
 
Method Summary
 NodeConfiguration clone()
           
 Properties getClientEnvironment()
           
static NodeConfiguration getConfiguration()
           
 String getHost()
           
 InvokerLocator getLocator()
           
 String getNodeId()
           
 int getPort()
           
 String getProductName()
           
 String getProductVersion()
           
 String getServerType()
           
 String getStreamingLocator()
           
 boolean isAutoDetectingPeers()
           
 boolean isServer()
           
 boolean isServerNode()
           
 boolean isStreamingServer()
           
 void normalize(InvokerLocator locator)
          Normalize hosts specifications from several config properties like the invoker, streaming server, jndi client env.
static void setConfiguration(NodeConfiguration cfg)
          Gives the possibility to override the current configuration.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NODE_ID

public static final String NODE_ID
See Also:
Constant Field Values

SERVER_ENABLED

public static final String SERVER_ENABLED
See Also:
Constant Field Values

SERVER_TYPE

public static final String SERVER_TYPE
See Also:
Constant Field Values

SERVER_LOCATOR

public static final String SERVER_LOCATOR
See Also:
Constant Field Values

SERVER_HOST

public static final String SERVER_HOST
See Also:
Constant Field Values

SERVER_PORT

public static final String SERVER_PORT
See Also:
Constant Field Values

PEERS

public static final String PEERS
See Also:
Constant Field Values

AUTODETECT_PEERS

public static final String AUTODETECT_PEERS
See Also:
Constant Field Values

CLIENT_JNDI_PREFIX

public static final String CLIENT_JNDI_PREFIX
See Also:
Constant Field Values

PRODUCT_NAME

public static final String PRODUCT_NAME
See Also:
Constant Field Values

PRODUCT_VERSION

public static final String PRODUCT_VERSION
See Also:
Constant Field Values

IS_STREAMING_SERVER

public static final String IS_STREAMING_SERVER
See Also:
Constant Field Values

STREAMING_LOCATOR

public static final String STREAMING_LOCATOR
See Also:
Constant Field Values
Constructor Detail

NodeConfiguration

public NodeConfiguration()
                  throws MalformedURLException
Throws:
MalformedURLException
Method Detail

getConfiguration

public static NodeConfiguration getConfiguration()

setConfiguration

public static void setConfiguration(NodeConfiguration cfg)
Gives the possibility to override the current configuration. This is useful for clients using auto configuration like Apogee.

Parameters:
cfg - the configuration to use as the current node configuration

isServerNode

public boolean isServerNode()

getNodeId

public String getNodeId()

isServer

public boolean isServer()

getServerType

public String getServerType()

getLocator

public InvokerLocator getLocator()

getHost

public String getHost()

getPort

public int getPort()

getProductName

public String getProductName()

getProductVersion

public String getProductVersion()

getStreamingLocator

public String getStreamingLocator()

isStreamingServer

public boolean isStreamingServer()

isAutoDetectingPeers

public boolean isAutoDetectingPeers()

getClientEnvironment

public Properties getClientEnvironment()

normalize

public void normalize(InvokerLocator locator)
               throws MalformedURLException
Normalize hosts specifications from several config properties like the invoker, streaming server, jndi client env. given a final host as used by the client at connection time.

Should be called by clients using the locator of the remote server after downoalding the configuration from the server.

Parameters:
locator -
Throws:
MalformedURLException

clone

public NodeConfiguration clone()
                        throws CloneNotSupportedException
Overrides:
clone in class Object
Throws:
CloneNotSupportedException

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.