public abstract class VstCommunication<R,C extends VstConnection> extends Object implements Closeable
Modifier and Type | Field and Description |
---|---|
protected Integer |
chunksize |
protected static String |
ENCRYPTION_JWT |
protected static String |
ENCRYPTION_PLAIN |
protected HostHandler |
hostHandler |
protected String |
jwt |
protected static AtomicLong |
mId |
protected String |
password |
protected String |
user |
protected ArangoSerialization |
util |
Modifier | Constructor and Description |
---|---|
protected |
VstCommunication(Integer timeout,
String user,
String password,
String jwt,
Boolean useSsl,
SSLContext sslContext,
ArangoSerialization util,
Integer chunksize,
HostHandler hostHandler) |
Modifier and Type | Method and Description |
---|---|
protected abstract void |
authenticate(C connection) |
protected Collection<Chunk> |
buildChunks(Message message) |
protected void |
checkError(Response response) |
void |
close() |
protected C |
connect(HostHandle hostHandle,
AccessType accessType) |
protected Message |
createMessage(Request request) |
protected Response |
createResponse(Message message) |
protected abstract R |
execute(Request request,
C connection) |
protected abstract R |
execute(Request request,
C connection,
int attemptCount) |
R |
execute(Request request,
HostHandle hostHandle) |
protected R |
execute(Request request,
HostHandle hostHandle,
int attemptCount) |
void |
setJwt(String jwt) |
protected static final String ENCRYPTION_PLAIN
protected static final String ENCRYPTION_JWT
protected static final AtomicLong mId
protected final ArangoSerialization util
protected final String user
protected final String password
protected volatile String jwt
protected final Integer chunksize
protected final HostHandler hostHandler
protected VstCommunication(Integer timeout, String user, String password, String jwt, Boolean useSsl, SSLContext sslContext, ArangoSerialization util, Integer chunksize, HostHandler hostHandler)
protected C connect(HostHandle hostHandle, AccessType accessType)
protected abstract void authenticate(C connection)
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
public R execute(Request request, HostHandle hostHandle) throws ArangoDBException
ArangoDBException
protected R execute(Request request, HostHandle hostHandle, int attemptCount) throws ArangoDBException
ArangoDBException
protected abstract R execute(Request request, C connection) throws ArangoDBException
ArangoDBException
protected abstract R execute(Request request, C connection, int attemptCount) throws ArangoDBException
ArangoDBException
protected void checkError(Response response) throws ArangoDBException
ArangoDBException
protected Response createResponse(Message message) throws com.arangodb.velocypack.exception.VPackParserException
com.arangodb.velocypack.exception.VPackParserException
protected final Message createMessage(Request request) throws com.arangodb.velocypack.exception.VPackParserException
com.arangodb.velocypack.exception.VPackParserException
protected Collection<Chunk> buildChunks(Message message)
public void setJwt(String jwt)
Copyright © 2016–2022 ArangoDB GmbH. All rights reserved.