Diffusion .NET Classic API - Core and Common  5.9.4
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
PushTechnology.DiffusionCore.PropertyHandlers.APIProperties Class Reference

The Diffusion system properties class. More...

Static Public Member Functions

static void SetSingleThreadedMode ()
 Helper method to configure the internal threadpool to use a single thread. More...
 
static void SetMultiThreadedMode ()
 Helper method to configure the internal threadpool to use multiple threads. More...
 
static void SetMaximumMessageDispatchThreads (int threads)
 Set the upper limit of threads in the internal task scheduler. More...
 
static int GetMaximumMessageDispatchThreads ()
 Get the upper limit of threads to be used by the internal task scheduler. More...
 
static int GetMessageLengthSize ()
 Returns the system wide Message Length Size value. More...
 
static int GetMaximumMessageSize ()
 Returns the maximum message size. This is the guideline maximum message size which should be set to a value that is capable of holding the largest message that will be handled (including headers). More...
 
static int GetDefaultLoadMessageCapacity ()
 Returns the default capacity for topic load messages. More...
 
static int GetDefaultDeltaMessageCapacity ()
 Returns the default capacity for delta messages. More...
 
static void SetDefaultLoadMessageCapacity (int capacity)
 Sets the default topic load message capacity. More...
 
static void SetDefaultDeltaMessageCapacity (int capacity)
 Sets the default delta message capacity. More...
 
static int GetConnectionTimeout ()
 Returns the connection timeout. More...
 
static void SetConnectionTimeout (int timeout)
 Sets the connection timeout. More...
 
static void SetMaximumMessageSize (int size)
 Sets the maximum message size. More...
 

Static Public Attributes

static int defaultMaximumMessageSize = 4096
 Default maximum message size. This is used if no explicit maximum message size is set using SetMaximumMessageSize( int ). More...
 
static int defaultConnectionTimeout = 5000
 Default connection timeout. This is used as the default timeout when making an outbound connection. More...
 

Properties

static bool FastWrites [get, set]
 Determines whether to use the experimental 'fast writes' algorithms. More...
 
static int TCPReceiveBufferSize [get, set]
 Get/set the TCP 'receive' buffer size. More...
 
static int SSLReceiveBufferSize [get, set]
 Get/set the SSL 'receive' buffer size. More...
 
static
LimitedConcurrencyLevelTaskScheduler 
TaskScheduler [get, set]
 Provides access to the internal task scheduler. More...
 
static bool MultiThreadedInboundMessageDispatch [get, set]
 Enables or disables multithreaded inbound message dispatch. By default, setting to true will configure the limited concurrency task scheduler to use 25 threads for message dispatch, and setting to false will configure it to use a single thread. More...
 

Detailed Description

The Diffusion system properties class.

Member Function Documentation

static int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.GetConnectionTimeout ( )
static

Returns the connection timeout.

This is the time allowed for establishing a connection.

If a size has not been explicitly set then the value will be read from diffusion.properties, if available, otherwise DEFAULT_CONNECTION_TIMEOUT will be assumed.

Returns
static int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.GetDefaultDeltaMessageCapacity ( )
static

Returns the default capacity for delta messages.

Returns
static int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.GetDefaultLoadMessageCapacity ( )
static

Returns the default capacity for topic load messages.

Returns
static int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.GetMaximumMessageDispatchThreads ( )
static

Get the upper limit of threads to be used by the internal task scheduler.

Returns
static int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.GetMaximumMessageSize ( )
static

Returns the maximum message size. This is the guideline maximum message size which should be set to a value that is capable of holding the largest message that will be handled (including headers).

If a size has not been explicitly set then the default value will be read from diffusion.properties, if available, otherwise DEFAULT_MAXIMUM_MESSAGE_SIZE will be assumed.

Returns
The maximum message size.
static int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.GetMessageLengthSize ( )
static

Returns the system wide Message Length Size value.

Diffusion allows a variable number of bytes to be assigned to the message length header within a Message. Typically this is 4 but can be set to 2 or even 1 in order to save space within Messages.

In a Server environment this is set via a value in the diffusion.properties file. In a non Server environment then the size used must be the same as any Server that will be connected to. The default is 4 but if the Server value is different then SetMessageLengthSize( int ) must be called before any other API calls.

Returns
static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetConnectionTimeout ( int  timeout)
static

Sets the connection timeout.

Parameters
timeout
static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetDefaultDeltaMessageCapacity ( int  capacity)
static

Sets the default delta message capacity.

Parameters
capacity
static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetDefaultLoadMessageCapacity ( int  capacity)
static

Sets the default topic load message capacity.

Parameters
capacity
static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetMaximumMessageDispatchThreads ( int  threads)
static

Set the upper limit of threads in the internal task scheduler.

Parameters
threads
static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetMaximumMessageSize ( int  size)
static

Sets the maximum message size.

This value is used as a guideline maximum message size used in various places and should be set to the size of the largest message you would expect to deal with.

If this is not explicitly set then the default will be assumed.

Parameters
size
static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetMultiThreadedMode ( )
static

Helper method to configure the internal threadpool to use multiple threads.

static void PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SetSingleThreadedMode ( )
static

Helper method to configure the internal threadpool to use a single thread.

Member Data Documentation

int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.defaultConnectionTimeout = 5000
static

Default connection timeout. This is used as the default timeout when making an outbound connection.

int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.defaultMaximumMessageSize = 4096
static

Default maximum message size. This is used if no explicit maximum message size is set using SetMaximumMessageSize( int ).

Property Documentation

bool PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.FastWrites
staticgetset

Determines whether to use the experimental 'fast writes' algorithms.

bool PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.MultiThreadedInboundMessageDispatch
staticgetset

Enables or disables multithreaded inbound message dispatch. By default, setting to true will configure the limited concurrency task scheduler to use 25 threads for message dispatch, and setting to false will configure it to use a single thread.

Convenience methods for setting these modes are available with

See Also
APIProperties.SetSingleThreadedMode, APIProperties.SetMultiThreadedMode

and .

It is also possible to explicitly set the number of threads to use with

See Also
APIProperties.SetMaximumMessageDispatchThreads

.

int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.SSLReceiveBufferSize
staticgetset

Get/set the SSL 'receive' buffer size.

LimitedConcurrencyLevelTaskScheduler PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.TaskScheduler
staticgetset

Provides access to the internal task scheduler.

int PushTechnology.DiffusionCore.PropertyHandlers.APIProperties.TCPReceiveBufferSize
staticgetset

Get/set the TCP 'receive' buffer size.