Class WBEMConfiguration
java.lang.Object
org.sblim.cimclient.internal.util.WBEMConfiguration
Class WBEMConfigurationFile is responsible for initializing the the
configuration properties from the configuration file.
- Threading considerations:
- This class was designed as thread-safe
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns whether the client will allow emptyLOCALNAMESPACEPATH
elements in incoming CIM-XML responses.static String
Returns the full URL of the active configuration file.static String
Returns the URL of the active configuration file.getCimXmlEmbObjBuilderReturn the XML parser to use for processing operation responsesReturns the CIM-XML trace stream to be used if application does not set one of its ownstatic Exception
Returns the exception caught during configuration load, load failed.Returns the custom socket factorygetDefaultCredentialsgetDefaultPrincipalReturns the domain propertiesgetDomainProperty
(String pKey) Returns a value from the domain properties for a given namestatic WBEMConfiguration
Returns the global configurationReturns the Java class name of http authentication module to useint
Returns the number of retries the client will attempt when the connection was refused.int
Returns the threshold for the content length retry algorithmint
Returns the http pool sizeint
Returns the http timeoutReturns the http version to useReturns the WWW-Authenticate info to use on first requestboolean
Returns whether sender IP property should be added to indicationsint
Returns the backlog that is tolerated before the thread pool creates an additional handlerlong
Returns the default value to use for CIM_IndicationService DeliveryRetryAttemptslong
Returns the default value to use for CIM_IndicationService DeliveryRetryIntervalint
Returns the http header timeout for indication connection handlersint
Returns the http timeout for indication connection handlersReturns the filter to use for tracing of incoming indications at the FINE levelint
Returns the maximum allowed http timeouts before IP is blockedlong
Returns the maximal idle time that is tolerated for a connection handlerint
Returns the maximal pool size for indication connection handlersint
Returns the maximal queue size for indications awaiting deliveryint
Returns the maximal queue size for pending indication connectionsint
Returns the minimal pool size for indication connection handlersReturns the properties local to the current threadgetLocalProperty
(String pKey) Returns a value from the local properties for a given nameReturns the console log levelReturns the console log typeint
Returns the log file countReturns the log file levelReturns the log file locationint
Returns the log file size limitint
Returns the initial capacity of the hash table used to handle reliable indicationsint
Returns the socket connect timeoutint
Returns the socket idle timeoutReturns the comma-separated list of cipher suites to be disabled by client.boolean
Returns whether the client will attempt to authenticate the CIMOMgetSslClientProtocolReturns the certificate algorithm the key manager will useReturns the password of the keystore.Returns the file path of the keystore.Returns the type of the keystore.Returns the comma-separated list of cipher suites to be disabled by listener.Returns how the listener will handle to authentication of the indication sender endpoint.getSslListenerProtocolgetSslProtocolReturns the JSSE provider to use for creating ssl server socketsReturns the JSSE provider to use for creating ssl client socketsReturns the certificate algorithm the trust manager will useReturns the password of the truststore.Returns the file path of the truststore.Returns the type of the truststore.int
Returns the trace file countReturns the trace file levelReturns the trace file locationint
Returns the trace file countboolean
Returns the state of CIM-XML tracingstatic boolean
Returns if the configuration was successfully loaded from the configuration fileboolean
isDefaultAuthorizationEnabledboolean
isGlobal()
Returns whether this configuration is the global oneboolean
Returns the state of gzip encoding enablement.boolean
Returns the state of chunking enablementboolean
Returns if the content length retry feature is enabledboolean
Returns the state of MPOST enablementboolean
Returns the state of reliable indication supportstatic void
Loads the global configuration from the configuration fileboolean
performSslHandshakevoid
setCustomSocketFactory
(SocketFactory pFactory) Sets a custom socket factory.void
setDomainProperties
(Properties pDomainProperties) Sets the domain propertiesvoid
setDomainProperty
(String pKey, String pValue) Sets a property value of the domain propertiesvoid
setLocalProperties
(Properties pLocalProperties) Sets the properties local to the current threadvoid
setLocalProperty
(String pKey, String pValue) Sets a property value of the local propertiesboolean
socketConnectWithTimeoutboolean
strictEmbObjTypesboolean
synchronizedSslHandshakeboolean
Returns whether the client will synchronize the data types of all numeric keys in aCIMInstance
'sCIMObjectPath
match those of the corresponding keys within theCIMInstance
'sCIMProperty[]
.boolean
upperCaseEmbObjEntitiesboolean
Returns whether the client will attempt to verify strings passed into thejava.lang.Double
constructor or itsparseDouble
method won't hang the JVM in an infinite loop.
-
Constructor Details
-
WBEMConfiguration
Ctor.- Parameters:
pDomainProperties
- The domain specific properties of this configuration. Domain specific properties are treated as an overlay on the global properties in theSystem
class.- Throws:
NullPointerException
- If pDomainProperties isnull
-
-
Method Details
-
loadGlobalConfiguration
public static void loadGlobalConfiguration()Loads the global configuration from the configuration file -
getActiveConfigURL
Returns the URL of the active configuration file. This is the file used to initialize the global configuration.- Returns:
- The URL of the active configuration file.
-
getActiveConfigFullURL
Returns the full URL of the active configuration file. This is the file used to initialize the global configuration.- Returns:
- The full URL of the active configuration file.
-
isConfigurationLoadSuccessful
public static boolean isConfigurationLoadSuccessful()Returns if the configuration was successfully loaded from the configuration file- Returns:
true
if the configuration was successfully loaded from the configuration file,false
otherwise
-
getGlobalConfiguration
Returns the global configuration- Returns:
- The global configuration
-
getConfigurationLoadException
Returns the exception caught during configuration load, load failed.- Returns:
- The exception or
null
if none was caught.
-
isGlobal
public boolean isGlobal()Returns whether this configuration is the global one- Returns:
true
if this is the global configuration
-
getDomainProperties
Returns the domain properties- Returns:
- The domain properties.
-
setDomainProperties
Sets the domain properties- Parameters:
pDomainProperties
- The new value
-
getDomainProperty
Returns a value from the domain properties for a given name- Parameters:
pKey
- The name of the property- Returns:
- The value
-
setDomainProperty
Sets a property value of the domain properties- Parameters:
pKey
- The name of propertypValue
- The new value
-
getLocalProperties
Returns the properties local to the current thread- Returns:
- The local properties.
-
setLocalProperties
Sets the properties local to the current thread- Parameters:
pLocalProperties
- The new value
-
getLocalProperty
Returns a value from the local properties for a given name- Parameters:
pKey
- The name of the property- Returns:
- The value
-
setLocalProperty
Sets a property value of the local properties- Parameters:
pKey
- The name of propertypValue
- The new value
-
setCustomSocketFactory
Sets a custom socket factory.- Parameters:
pFactory
- The factory
-
getCustomSocketFactory
Returns the custom socket factory- Returns:
- The factory if set,
null
otherwise
-
getLogConsoleLevel
Returns the console log level- Returns:
- The console log level
-
getLogConsoleType
Returns the console log type- Returns:
- The console log type
-
getLogFileLevel
Returns the log file level- Returns:
- The log file level
-
getLogFileLocation
Returns the log file location- Returns:
- The log file location
-
getLogFileCount
public int getLogFileCount()Returns the log file count- Returns:
- The log file count
-
getLogFileSizeLimit
public int getLogFileSizeLimit()Returns the log file size limit- Returns:
- The log file size limit
-
getTraceFileLevel
Returns the trace file level- Returns:
- The trace file level
-
getTraceFileLocation
Returns the trace file location- Returns:
- The trace file location
-
getTraceFileCount
public int getTraceFileCount()Returns the trace file count- Returns:
- The trace file count
-
getTraceFileSizeLimit
public int getTraceFileSizeLimit()Returns the trace file count- Returns:
- The trace file count
-
getHttpTimeout
public int getHttpTimeout()Returns the http timeout- Returns:
- The http timeout
-
getHttpPoolSize
public int getHttpPoolSize()Returns the http pool size- Returns:
- The http pool size
-
getHttpAuthenticationModule
Returns the Java class name of http authentication module to use- Returns:
- The http authentication module's class name
-
getHttpWwwAuthenticateInfo
Returns the WWW-Authenticate info to use on first request- Returns:
- The WWW-Authenticate info
-
isHttpMPost
public boolean isHttpMPost()Returns the state of MPOST enablement- Returns:
true
if MPOST is enabled,false
otherwise
-
isHttpChunked
public boolean isHttpChunked()Returns the state of chunking enablement- Returns:
true
if chunking is enabled,false
otherwise
-
getHttpVersion
Returns the http version to use- Returns:
- The http version
-
getSslKeyStorePath
Returns the file path of the keystore.- Returns:
- The keystore file path.
-
getSslKeyStoreType
Returns the type of the keystore.- Returns:
- The keystore type.
-
getSslKeyStorePassword
Returns the password of the keystore.- Returns:
- The keystore password.
-
getSslTrustStorePath
Returns the file path of the truststore.- Returns:
- The truststore file path.
-
getSslTrustStoreType
Returns the type of the truststore.- Returns:
- The truststore type.
-
getSslTrustStorePassword
Returns the password of the truststore.- Returns:
- The truststore password.
-
getSslSocketProvider
Returns the JSSE provider to use for creating ssl client sockets- Returns:
- The JSSE provider for client sockets
-
getSslServerSocketProvider
Returns the JSSE provider to use for creating ssl server sockets- Returns:
- The JSSE provider for server sockets
-
getSslProtocol
getSslProtocol- Returns:
- The SSL protocol for SSLContext.getInstance()
-
getSslClientProtocol
getSslClientProtocol- Returns:
- The SSL protocol for SSLContext.getInstance() for client
-
getSslListenerProtocol
getSslListenerProtocol- Returns:
- The SSL protocol for SSLContext.getInstance() for listener
-
getSslKeyManagerAlgorithm
Returns the certificate algorithm the key manager will use- Returns:
- The key mangers algorithm
-
getSslTrustManagerAlgorithm
Returns the certificate algorithm the trust manager will use- Returns:
- The trust mangers algorithm
-
getSslClientPeerVerification
public boolean getSslClientPeerVerification()Returns whether the client will attempt to authenticate the CIMOM- Returns:
true
if the client will attempt to authenticate the CIMOM by verifying the server certificatefalse
otherwise
-
getSslListenerPeerVerification
Returns how the listener will handle to authentication of the indication sender endpoint.- Returns:
- The listener peer verification mode
-
getSslClientCipherSuitesToDisable
Returns the comma-separated list of cipher suites to be disabled by client.- Returns:
- The list of cipher suites
-
getSslListenerCipherSuitesToDisable
Returns the comma-separated list of cipher suites to be disabled by listener.- Returns:
- The list of cipher suites
-
getHttpConnectRetriesCount
public int getHttpConnectRetriesCount()Returns the number of retries the client will attempt when the connection was refused.- Returns:
- The number of retries
-
isHttpContentLengthRetryEnabled
public boolean isHttpContentLengthRetryEnabled()Returns if the content length retry feature is enabled- Returns:
true
if content length retry is enabled,false
otherwise
-
getHttpContentLengthThreshold
public int getHttpContentLengthThreshold()Returns the threshold for the content length retry algorithm- Returns:
- The threshold
-
getCimXmlParser
Return the XML parser to use for processing operation responses- Returns:
- The XML parser
-
getCimXmlEmbObjBuilder
getCimXmlEmbObjBuilder- Returns:
- configuration property for the embedded object builder
-
strictEmbObjTypes
public boolean strictEmbObjTypes()strictEmbObjTypes- Returns:
- true if EmbeddedObject exactly means Embedded Class
-
upperCaseEmbObjEntities
public boolean upperCaseEmbObjEntities()upperCaseEmbObjEntities- Returns:
- true if "EMBEDDEDOBJECT" entity, false if "EmbeddedObject"
-
performSslHandshake
public boolean performSslHandshake()performSslHandshake- Returns:
- true if SSL handshakes should take place
-
synchronizedSslHandshake
public boolean synchronizedSslHandshake()synchronizedSslHandshake- Returns:
- true if SSL handshakes should be synchronized
-
socketConnectWithTimeout
public boolean socketConnectWithTimeout()socketConnectWithTimeout- Returns:
- true if socket connections should be attempted with a timeout
-
getSocketConnectTimeout
public int getSocketConnectTimeout()Returns the socket connect timeout- Returns:
- The socket connect timeout
-
getSocketIdleTimeout
public int getSocketIdleTimeout()Returns the socket idle timeout- Returns:
- The socket idle timeout
-
isDefaultAuthorizationEnabled
public boolean isDefaultAuthorizationEnabled()isDefaultAuthorizationEnabled- Returns:
- true if default authorization is enabled
-
getDefaultPrincipal
getDefaultPrincipal- Returns:
- default value of Principal
-
getDefaultCredentials
getDefaultCredentials- Returns:
- default value of Credentials
-
isCimXmlTracingEnabled
public boolean isCimXmlTracingEnabled()Returns the state of CIM-XML tracing- Returns:
true
if tracing is enabled,false
otherwise
-
getCimXmlTraceStream
Returns the CIM-XML trace stream to be used if application does not set one of its own- Returns:
- The trace stream
-
getListenerBacklog
public int getListenerBacklog()Returns the backlog that is tolerated before the thread pool creates an additional handler- Returns:
- The backlog
-
getListenerHttpTimeout
public int getListenerHttpTimeout()Returns the http timeout for indication connection handlers- Returns:
- The timeout
-
getListenerHttpHeaderTimeout
public int getListenerHttpHeaderTimeout()Returns the http header timeout for indication connection handlers- Returns:
- The timeout
-
getListenerMaxAllowedTimeouts
public int getListenerMaxAllowedTimeouts()Returns the maximum allowed http timeouts before IP is blocked- Returns:
- The maximum allowed timeouts
-
getListenerMaxPoolSize
public int getListenerMaxPoolSize()Returns the maximal pool size for indication connection handlers- Returns:
- The maximal pool size
-
getListenerMinPoolSize
public int getListenerMinPoolSize()Returns the minimal pool size for indication connection handlers- Returns:
- The minimal pool size
-
getListenerMaxQueueSize
public int getListenerMaxQueueSize()Returns the maximal queue size for pending indication connections- Returns:
- The maximal queue size
-
getListenerMaxIdle
public long getListenerMaxIdle()Returns the maximal idle time that is tolerated for a connection handler- Returns:
- The maximal idle time
-
getListenerMaxQueuedEvents
public int getListenerMaxQueuedEvents()Returns the maximal queue size for indications awaiting delivery- Returns:
- The maximal queue size
-
isReliableIndicationEnabled
public boolean isReliableIndicationEnabled()Returns the state of reliable indication support- Returns:
true
if reliable indication support is enabled,false
otherwise
-
getListenerDeliveryRetryAttempts
public long getListenerDeliveryRetryAttempts()Returns the default value to use for CIM_IndicationService DeliveryRetryAttempts- Returns:
- The default value
-
getListenerDeliveryRetryInterval
public long getListenerDeliveryRetryInterval()Returns the default value to use for CIM_IndicationService DeliveryRetryInterval- Returns:
- The default value
-
getReliableIndicationHashtableCapacity
public int getReliableIndicationHashtableCapacity()Returns the initial capacity of the hash table used to handle reliable indications- Returns:
- The default value
-
getListenerIndicationTraceFilter
Returns the filter to use for tracing of incoming indications at the FINE level- Returns:
- The indication trace filter
-
getListenerAddSenderIPAddress
public boolean getListenerAddSenderIPAddress()Returns whether sender IP property should be added to indications- Returns:
true
if sender IP property should be added to indications,false
otherwise
-
verifyJavaLangDoubleStrings
public boolean verifyJavaLangDoubleStrings()Returns whether the client will attempt to verify strings passed into thejava.lang.Double
constructor or itsparseDouble
method won't hang the JVM in an infinite loop.- Returns:
true
if the client will attempt to verify strings passed toDouble
,false
otherwise
-
synchronizeNumericKeyDataTypes
public boolean synchronizeNumericKeyDataTypes()Returns whether the client will synchronize the data types of all numeric keys in aCIMInstance
'sCIMObjectPath
match those of the corresponding keys within theCIMInstance
'sCIMProperty[]
.- Returns:
true
if the client will synchronizeCIMInstance
numeric key data types,false
otherwise
-
isGzipEncodingEnabled
public boolean isGzipEncodingEnabled()Returns the state of gzip encoding enablement.- Returns:
true
if gzip encoding is enabled,false
otherwise
-
allowEmptyLocalNameSpacePath
public boolean allowEmptyLocalNameSpacePath()Returns whether the client will allow emptyLOCALNAMESPACEPATH
elements in incoming CIM-XML responses.- Returns:
true
if CIM-XML parser should allow emptyLOCALNAMESPACEPATH
elements in incoming responses,false
otherwise
-