Running the StreamBase Proxy Server

The StreamBase sbproxy server runs separately from the sbd server. You can use it for two purposes, described in these topics:

To run a StreamBase client and server with the proxy server, follow these general steps:

  1. Start the sbd server.

  2. Start the proxy server by using the sbproxy command, as described in sbproxy.

  3. Start the client application.

Notes

  • If you are using sbproxy to connect to older clients, each instance of a proxy server supports only one version. For example, if you need to run clients for both Version 3.5 and 3.7, you must run two different proxy servers.

  • If you are using sbproxy to provide security, use the -f option to point to the sbd server configuration file where you have defined the security element.

  • To stop the sbproxy server, kill its process.

  • JVM tuning options can be supplied to the proxy server by setting the STREAMBASE_JVM_ARGS environment variable. See Using STREAMBASE_JVM_ARGS for sbproxy Performance.

Using STREAMBASE_JVM_ARGS for sbproxy Performance

The proxy server will use any JVM parameters that you have previously set using the STREAMBASE_JVM_ARGS environment variable. The default settings are generally set to maximize the number of clients and throughput, with a penalty of increased latency. In general, settings that you adjust to decrease latency will reduce the maximum number of clients and throughput. This section lists some of the possible parameters that you can use if you want to adjust performance while running sbproxy.

-Dcom.streambase.sb.proxy.use-acceptor-thread-pool=true

Use a thread pool for socket acceptor. Using a thread pool should increase overall throughput but will increase latency. If false, will spawn a thread for each request. Default is true.

-Dcom.streambase.sb.proxy.acceptor-processing-threads=n

Number of threads dedicated to the Socket Acceptor, if acceptor threads are enabled. Default is the number of processors on the system.

-Dcom.streambase.sb.proxy.max-threads=-1

Approximate maximum number of concurrent threads that will be spawned for each thread type (IOService and Filters). Default is no maximum.

-Dcom.streambase.sb.proxy.use-request-thread-pool=true

Use a thread pool for requests. Using this should increase overall throughput but will increase latency. Default is true.

-Dcom.streambase.sb.proxy.use-response-thread-pool=true

Use a thread pool for responses. Default is true. Use should increase overall throughput but will increase latency.

-Dcom.streambase.sb.proxy.max-buffer-size=XXX (default is 10 megs)

Maximum buffer size that the proxy will hold until it stalls the client or server during reads. Default is 10 Mb.

-Dcom.streambase.sb.proxy.socket-receive-buffer-size=-1

Size of the buffer that the proxy server reads from the socket. By default the setting is the system default.

Related Topics