Interface ClientServerConfiguration

  • All Known Implementing Classes:
    Config4Impl

    public interface ClientServerConfiguration
    Client/Server configuration interface.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void batchMessages​(boolean flag)
      Configures to batch messages between client and server.
      MessageSender getMessageSender()
      returns the MessageSender for this Configuration context.
      void maxBatchQueueSize​(int maxSize)
      Configures the maximum memory buffer size for batched message.
      void prefetchDepth​(int prefetchDepth)
      Sets the depth to which prefetched objects are activated.
      void prefetchIDCount​(int prefetchIDCount)
      Sets the number of IDs to be pre-allocated in the database for new objects created on the client.
      void prefetchObjectCount​(int prefetchObjectCount)
      Sets the number of objects to be prefetched for an ObjectSet.
      void prefetchSlotCacheSize​(int slotCacheSize)
      Sets the slot cache size to the given value.
      void setMessageRecipient​(MessageRecipient messageRecipient)
      sets the MessageRecipient to receive Client Server messages.
      void singleThreadedClient​(boolean flag)
      configures the client messaging system to be single threaded or multithreaded.
      void timeoutClientSocket​(int milliseconds)
      configures the time a client waits for a message response from the server.
      void timeoutServerSocket​(int milliseconds)
      configures the timeout of the serverside socket.
    • Method Detail

      • prefetchIDCount

        void prefetchIDCount​(int prefetchIDCount)
        Sets the number of IDs to be pre-allocated in the database for new objects created on the client. This setting should be used on the client side. In embedded mode this setting has no effect.
        Parameters:
        prefetchIDCount - The number of IDs to be prefetched
      • prefetchObjectCount

        void prefetchObjectCount​(int prefetchObjectCount)
        Sets the number of objects to be prefetched for an ObjectSet. This setting should be used on the server side.
        Parameters:
        prefetchObjectCount - The number of objects to be prefetched
      • prefetchDepth

        void prefetchDepth​(int prefetchDepth)
        Sets the depth to which prefetched objects are activated. This setting should be used on the client side.
        Parameters:
        prefetchDepth -
      • prefetchSlotCacheSize

        void prefetchSlotCacheSize​(int slotCacheSize)
        Sets the slot cache size to the given value.
        Parameters:
        slotCacheSize -
      • setMessageRecipient

        void setMessageRecipient​(MessageRecipient messageRecipient)
        sets the MessageRecipient to receive Client Server messages.

        This setting should be used on the server side.

        Parameters:
        messageRecipient - the MessageRecipient to be used
      • getMessageSender

        MessageSender getMessageSender()
        returns the MessageSender for this Configuration context. This setting should be used on the client side.
        Returns:
        MessageSender
      • timeoutClientSocket

        void timeoutClientSocket​(int milliseconds)
        configures the time a client waits for a message response from the server.

        Default value: 600000ms (10 minutes)

        It is recommended to use the same values for timeoutClientSocket(int) and timeoutServerSocket(int).
        This setting can be used on both client and server.

        Parameters:
        milliseconds - time in milliseconds
      • timeoutServerSocket

        void timeoutServerSocket​(int milliseconds)
        configures the timeout of the serverside socket.

        The serverside handler waits for messages to arrive from the client. If no more messages arrive for the duration configured in this setting, the client will be disconnected.
        Clients send PING messages to the server at an interval of Math.min(timeoutClientSocket(), timeoutServerSocket()) / 2 and the server will respond to keep connections alive.
        Decrease this setting if you want clients to disconnect faster.
        Increase this setting if you have a large number of clients and long running queries and you are getting disconnected clients that you would like to wait even longer for a response from the server.
        Default value: 600000ms (10 minutes)

        It is recommended to use the same values for timeoutClientSocket(int) and timeoutServerSocket(int).
        This setting can be used on both client and server.

        Parameters:
        milliseconds - time in milliseconds
      • singleThreadedClient

        void singleThreadedClient​(boolean flag)
        configures the client messaging system to be single threaded or multithreaded.

        Recommended settings:
        - true for low resource systems.
        - false for best asynchronous performance and fast GUI response.

        Default value:
        - .NET Compactframework: true
        - all other platforms: false

        This setting can be used on both client and server.

        Parameters:
        flag - the desired setting
      • batchMessages

        void batchMessages​(boolean flag)
        Configures to batch messages between client and server. By default, batch mode is enabled.

        This setting can be used on both client and server.

        Parameters:
        flag - false, to turn message batching off.
      • maxBatchQueueSize

        void maxBatchQueueSize​(int maxSize)
        Configures the maximum memory buffer size for batched message. If the size of batched messages is greater than maxSize, batched messages will be sent to server.

        This setting can be used on both client and server.

        Parameters:
        maxSize -