Package com.twicedb.client.proxy
Class ClientProxy
java.lang.Object
com.twicedb.client.proxy.ClientProxy
A class for proxying network requests from the client to a TwiceDB server(s). Users should not
instantiate this class directly; it should be instantiated automatically by the client.
-
Constructor Summary
ConstructorsConstructorDescriptionClientProxy(String serverAddress, ClientConfig clientConfig) ClientProxy(String zkAddress, String writerAddress, String readerAddress, ClientConfig clientConfig) -
Method Summary
Modifier and TypeMethodDescriptionHealthCheckResponsecheckReader(HealthCheckRequest req) HealthCheckResponsecheckWriter(HealthCheckRequest req) protected static ByteBuffercompressBlobWithCompressor(Compressor cmprsr, ByteString bytes) read(ReadRequest req) readEvent(ReadRequest req) readLsqt()readObjects(ReadRequest req) status(ServerType serverType) voidstop()<any>subscribe(SubscribeRequest sr, Function<SubscribeResponse, Boolean> cback) protected ByteBufferuncompressBlob(ByteString bytes, int expectedUncompressedSize) protected static ByteBufferuncompressBlobWithDecompressor(Decompressor dcmprsr, ByteString bytes, int expectedUncompressedSize) write(WriteRequest req)
-
Constructor Details
-
ClientProxy
-
ClientProxy
public ClientProxy(String zkAddress, String writerAddress, String readerAddress, ClientConfig clientConfig)
-
-
Method Details
-
getRetryingServiceConfig
-
read
-
readLsqt
-
readEvent
-
uncompressBlobWithDecompressor
protected static ByteBuffer uncompressBlobWithDecompressor(Decompressor dcmprsr, ByteString bytes, int expectedUncompressedSize) -
uncompressBlob
-
readObjects
-
compressBlobWithCompressor
-
write
-
checkReader
public HealthCheckResponse checkReader(HealthCheckRequest req) -
checkWriter
public HealthCheckResponse checkWriter(HealthCheckRequest req) -
stop
public void stop() -
subscribe
-