SDK
SDK Java v3.x
2

This SDK is deprecated. We recommend to use the Kuzzle SDK-JVM.
A migration guide is available here

Constructor #

Use this constructor to create a new instance of the SDK. Each instance represents a different connection to a Kuzzle server with specific options.

Arguments #

Copied to clipboard!
public Kuzzle(
  AbstractProtocol networkProtocol,
  KuzzleOptions options
) throws IllegalArgumentException

Argument Type Description
networkProtocol
AbstractProtocol
Protocol used by the SDK instance
options
KuzzleOptions
Class which contains options

networkProtocol #

The protocol used to connect to the Kuzzle instance. It can be one of the following available protocols:

options #

The options used to connect to the Kuzzle instance. KuzzleOptions

Return #

The Kuzzle SDK instance.

Throws #

Can throw an IllegalArgumentException

Usage #

Copied to clipboard!
KuzzleOptions options = new KuzzleOptions();
options.setMaxQueueSize(42)
  .setMaxRequestDelay(1)
  .setMinTokenDuration(24)
  .setRefreshedTokenDuration(40)
  .setQueueFilter(stringObjectConcurrentHashMap -> true);
Kuzzle kuzzle = new Kuzzle(new WebSocket("kuzzle"), options);